- Настройка WiFi в Arch Linux из командной строки
- Сканирование сети
- Настройка Wi-Fi с помощью netctl
- Простой способ – Wifi-menu
- Сложный способ
- Запуск netctl
- Другие утилиты
- Заключение
- Arch Linux
- #1 2014-08-10 05:04:35
- TP-Link WiFi setup problems
- #2 2014-08-10 05:22:51
- Re: TP-Link WiFi setup problems
- #3 2014-08-10 05:36:21
- Re: TP-Link WiFi setup problems
- #4 2014-08-10 05:49:19
- Re: TP-Link WiFi setup problems
- #5 2014-08-10 10:09:59
- Re: TP-Link WiFi setup problems
- #6 2014-08-10 19:54:12
- Re: TP-Link WiFi setup problems
- Arch Linux
- #1 2019-02-08 16:31:37
- [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #2 2019-02-08 17:35:26
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #3 2019-02-08 21:22:09
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #4 2019-02-08 21:29:50
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #5 2019-02-08 22:18:25
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #6 2019-02-08 22:23:18
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #7 2019-02-09 10:33:18
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #8 2019-02-09 10:45:13
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #9 2019-02-09 10:45:24
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #10 2019-02-09 10:51:29
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #11 2019-02-09 16:17:47
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #12 2019-02-10 21:33:02
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #13 2019-02-11 21:23:05
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
- #14 2019-09-15 08:37:51
- Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
Настройка WiFi в Arch Linux из командной строки
Оригинал: How To Setup A WiFi Network In Arch Linux Using Terminal
Автор: Mohd Sohail
Дата публикации: 26 октября 2016 года
Перевод: А. Кривошей
Дата перевода: октябрь 2017 г.
Если вы ранее не работали с дистрибутивом Arch CLI, то одной из самых сложных задач для вас может стать настройка WiFi в терминале. В этой статье проведу вас через пошаговое руководство по настройке подключения Arch Linux к вашей сети WiFi.
Существует множество программ по настройке беспроводного соединения в Linux, для настройки подключения к интернету мы могли бы использовать ip и iw , но это было бы немного сложно для новичков. Поэтому мы будем использовать netctl, это инструмент командной строки, применяемый для настройки и управления сетевыми подключениями с помощью профилей.
Примечание: для всех настроек вам будут нужны права root.
Сканирование сети
Определите имя своего сетевого интерфейса с помощью команды:
Выполните следующую команду:
Запустите поиск доступных сетей WiFi:
Примечание: здесь interface — это ваш сетевой интерфейс, который вы ранее нашли с помощью команды iwconfig.
Настройка Wi-Fi с помощью netctl
Перед настройкой соединения с помощью netctl необходимо проверить совместимость вашей сетевой карты с Linux.
Эта команда проверит, загружен ли модуль ядра — драйвер беспроводной карты. Ее вывод должен быть примерно таким:
Если ядро не загрузило дравер, вам необходимо установить его, подключившись к интернету по Ethernet (или с помощью мобильной сети). Официальный Linux Wireless Wiki: https://wireless.wiki.kernel.org/
Если ваша беспроводная карта совместима с Linux, можно приступать к настройке netctl.
netctl работает с профилями — то есть файлами, в которых содержится информация о соединении. Профиль можно создать двумя способами.
Простой способ – Wifi-menu
Если вы хотите использовать wifi-menu, у вас должен быть установлен dialog.
1. Выполните команду: wifi-menu
2. Выберите вашу сеть для настройки wifi в arch.
3. Введите правильный пароль и ждите.
Если вы не получили сообщения о неудачном подключении, вы можете проверить его работу командой:
Если он пингуется, то сеть настроена успешно. Теперь вы подключены к сети Wi-Fi в Arch Linux. Если у вас возникли какие-либо ошибки, повторите описанные выше шаги. Возможно, вы что-то пропустили.
Сложный способ
По сравнению с вышеописанным, этот метод немного сложнее. В приведенной выше команде сетевой профиль был настроен автоматически. Сейчас мы настроим профиль вручную. Но не беспокойтесь, это будет ненамного сложнее. Давайте начнем!
1. Первое, что вы должны сделать, это узнать имя вашего интерфейса, как правило, это wlan0/wlp2s0, но может быть много исключений. Чтобы узнать имя вашего интерфейса, необходимо использовать команду iwconfig.
2. Выполните команду:
В этой поддиректории вы увидите различные примеры профилей.
3. Скопируйте пример своего профиля в /etc/netctl/your_profile
4. Вы можете просмотреть содержимое профиля с помощью команды:
5. Отредактируйте следующие поля в профиле с помощью vi или nano:
1. Interface: это должен быть wlan0
2. ESSID: имя вашей сети
3. key: пароль вашей сети
Запуск netctl
1. Выполните команды:
Вы должны увидеть профиль, созданный с помощью wifi-menu, например wlan0-SSID; или, если вы использовали сложный способ, то вы должны увидеть профиль, созданный вами.
2. Запустите свой профиль с помощью команды:
3. Протестируйте подключение:
4. В конце вы должны выполнить следующую команду:
При этом будет создана и активирована служба systemd, которая будет запускаться при загрузке компьютера. Теперь вы настроили wifi в своем Arch Linux.
Другие утилиты
Вы также можете использовать для настройки беспроводного соединения и другие программы, например iw:
iw dev wlan0 link – статус
iw dev wlan0 scan – сканирование сетей
iw dev wlan0 connect your_essid – подключение к открытой сети
iw dev wlan0 connect your_essid key your_key — подключение к сети с защитой WEP, используя шестнадцатеричный ключ.
Заключение
Итак, на этом все! Я упомянул 3 способа подключения к сети WiFi в Arch Linux. Одна вещь, на которую я хочу обратить внимание: когда вы выполняете первую команду, обратите внимание на интерфейс. В следующей команде, где мы сканируем сети, используйте не interface, а имя вашего интерфейса, например wlan0 или wlp2s0 (которое вы узнали из вывода предыдущей команды). Не забудьте поделиться этой статьей со своими друзьями в социальных сетях. Спасибо!
Источник
Arch Linux
You are not logged in.
#1 2014-08-10 05:04:35
TP-Link WiFi setup problems
I have a TP-LINK TL-WN727N USB WiFi dongle, and I have trouble getting it to work.
According to [1] pointing [2], it uses the rt2800usb driver. I have added «rt2800usb» to /etc/modules-load.d/wifi.conf. After reboot, I get this:
does not show the interface, nor does
Here’s from the kernel log:
I’m afraid I’m stuck. Help?
#2 2014-08-10 05:22:51
Re: TP-Link WiFi setup problems
Registered Linux User #482438
#3 2014-08-10 05:36:21
Re: TP-Link WiFi setup problems
You think the page on wireless.kernel.org is wrong?
But let’s say it is. Installing it produces a new interface called ra0, which I can set to «up».
still doesn’t produce any output, nor does
. Nothing about firmware in kernel log either.
Last edited by jernst (2014-08-10 05:37:53)
#4 2014-08-10 05:49:19
Re: TP-Link WiFi setup problems
I don’t know that the reference page would be wrong, but I would not be surprised if a branded device shipped with a completely different chip in it.
What firmware should be loaded for that chip? Check dmesg.
Registered Linux User #482438
#5 2014-08-10 10:09:59
Re: TP-Link WiFi setup problems
A hint: *Never* look at marketing names, always at the usb-id (or pci-id for pci devices). It’s irrelevant that you have a TL-WN727N, what’s relevant is that you have a 148f:7601. So the wireless page isn’t wrong, it doesn’t list a 148f:7601 at all.
Another hint: External drivers, especially for usb devices, tend to be wext (wireless extensions) drivers and not nl80211. iw uses nl80211 exclusively, it won’t work with wext drivers. Use wireless_tools instead. wpa_supplicant works with both wext and nl80211.
#6 2014-08-10 19:54:12
Re: TP-Link WiFi setup problems
@Gusar: You are obviously correct, because I now got it to work using wpa_supplicant. But the mind boggles . what a mess! Shouldn’t all tools support all drivers, or is that a naive question?
For the record, this is what I did:
Installed dkms-mt7601u-latest from AUR. (dkms-mt7601u, which is also there, fails to build for me.) This makes the device show up as ra0 in ‘ip link’
Installed wpa_supplicant, and followed the instructions here for specifying network and authentication: https://wiki.archlinux.org/index.php/WPA_supplicant
However, I need to specify -Dext on the wpa_supplicant command-line, otherwise I get this error message: nl80211: Driver does not support authentication/association or connect commands
For permanent configuration, I ended up having to create a new systemd service file:
where I replaced all occurrences of ‘nl80211’ with ‘wext’. Thus, the correct name of the wpa_supplicant config file became /etc/wpa_supplicant/wpa_supplicant-wext-ra0.conf and I can start the service with
Still some problems when rebooting — chances are that dhcpcd@ra0 does not wait until wpa_supplicant-wext@ra0 is ready.
Update: I have attempted to update the Wiki based on the valuable comments in this thread.
Last edited by jernst (2014-08-12 04:50:38)
Источник
Arch Linux
You are not logged in.
#1 2019-02-08 16:31:37
[Solved] Wifi TP-Link TL-WN823N doesn’t work
Hi, I’m trying to use my Wlan adapter: TL-WN823N with no luck.
I’ve tried both in my laptop and in my PC.
1) The adapter seems to be detected:
$lsusb
2) The driver seems to be loaded:
$dmesg | grep usbcore
3)After $ip link:
4)Check kernel messages for the firmware:
$dmesg | grep firmware
5)Check any messages for the rtl8xxxu
$checkdmesg | grep rtl8xxxu
6)When I try$wifi-menu
The networks are recognized
I chose mine, enter password
And I get:
«CONNECTING FAILED»
I’ve both tried in a clean installation of Arch and in my laptop where I’ve not installed yet, and can’t do it because I don’t have a inner card (either for ethernet or wifi)
Last edited by manux-chacarita (2019-02-09 11:16:40)
#2 2019-02-08 17:35:26
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
The behavior is recorded for the chip.
Please do not follow random blog posts, see https://aur.archlinux.org/packages/8192eu-dkms/ and post updated outputs (because after installing 8192eu, rtl8xxxu should no longer show up)
#3 2019-02-08 21:22:09
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
Thanks for your response.
As you suggested, I’ve installed 8192eu and this are the outputs,
Please let me know if I’m missing any logs
$ dmesg | grep usbcore
$ dmesg | grep 8192eu
dmesg | grep xxxu
#4 2019-02-08 21:29:50
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
(To be sure: it still doesn’t work, does it?)
#5 2019-02-08 22:18:25
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
Hi, thank you very much Seth!
It was dead, but after blacklisting the old driver, it started working.
One more thing:
wifi-menu is still not working, I can use it through Network Manager inside my Window Manager.
Any ideas?
(Should I close this post and open a new one with the last question?)
#6 2019-02-08 22:23:18
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
From your initial post, something (probably networkmanager?) is bringing the interface up and wifi-menu will refuse to operate it.
Pick and use only one network managing service (in case of wifi-menu it’s netctl) per interface.
#7 2019-02-09 10:33:18
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
Thanks again, yes, I could connect directly after booting through the network manager cli.
Now that I have the solution for the desk pc (ethernet helped me downloading the drivers) I would like to use the same drivers in a new fresh installation on a laptop with no ethernet or wifi card, just USB and the same wlan adapter. Should I remaster the arch iso with the 8192eu drivers before installation?
#8 2019-02-09 10:45:13
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
You’ll have to get the kernel module onto that system — whether you remaster an iso or just usb-walk it over doesn’t matter.
Notice that the dkms package will attempt to build the module, what’s likely not going to work (I’ve no idea, but don’t think there’s a compiler in the iso) — so you have to bring a precompiled module . for the kernel version in the iso.
If you’re facing more issues, you’d better open a new thread on topic.
#9 2019-02-09 10:45:24
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
You can remaster it or you could build the module with the same kernel version as the ISO, put the built package on a USB drive and install it on the booted iso.
Edit: As seth said, a dkms won’t work of course. Then you’d have to copy and install dkms with all its dependencies as well.
Edit: You could use the dkms package and let it build the module after installing it on the host with the correct kernel version, and then copy it manually to the position in /usr/lib/modules. Then «rmmod» the original module and then load the new one.
Last edited by progandy (2019-02-09 10:53:57)
#10 2019-02-09 10:51:29
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
Thank you guys, as you suggested I will try out and if I have any issues in the process I’ll open a new thread.
#11 2019-02-09 16:17:47
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
Is tethering a phone by USB an option? They show up as a wired Ethernet. Just plug it it, turn on tethering, and run dhcpcd as root.
Nothing is too wonderful to be true, if it be consistent with the laws of nature — Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. — Alan Turing
—
How to Ask Questions the Smart Way
#12 2019-02-10 21:33:02
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
Is tethering a phone by USB an option?
Hi Ewaller! It’s a great option that I haven’t thought about before.
I’ve tried it in my pc with arch installed and it worked perfectly.
When I try in the laptop with the arch ISO:
2) If I run again dhcpcd:
3) ping 8.8.8.8 works fine, same thing with for example archlinux.org ip
4) But when I ping archlinux.org:
(If I am going out of the thread let me know and I’ll do a new post about this issue probably in newbies section)
Thanks!
Last edited by manux-chacarita (2019-02-10 22:22:25)
#13 2019-02-11 21:23:05
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
I was missing to add a name server in the /etc/resolv.conf :
For example:
After this I could ping any url.
Thanks again guys!
#14 2019-09-15 08:37:51
Re: [Solved] Wifi TP-Link TL-WN823N doesn’t work
Hi, thank you very much Seth!
It was dead, but after blacklisting the old driver, it started working.
One more thing:
wifi-menu is still not working, I can use it through Network Manager inside my Window Manager.
Any ideas?
(Should I close this post and open a new one with the last question?)
Hi,
I am facing the same problem. would you mind sharing how this got fixed for you?
$ lsusb
Bus 001 Device 002: ID 2357:0109 TP-Link TL WN823N RTL8192EU
This is my networkctl output:
$ networkctl
IDX LINK TYPE OPERATIONAL SETUP
1 lo loopback carrier unmanaged
2 eno1 ether no-carrier unmanaged
3 wlp0s20u2 wlan no-carrier configuring
5 enp0s20u3 ether routable unmanaged
The 3rd interface (wlp0s20u2) is my tplink tl823n.
Its always showing ‘configuring’
$ sudo dmesg | grep usbcore
[ 0.728638] usbcore: registered new interface driver usbfs
[ 0.728638] usbcore: registered new interface driver hub
[ 0.728638] usbcore: registered new device driver usb
[ 1.020327] usbcore: registered new interface driver usbserial_generic
[ 13.282545] usbcore: registered new interface driver usbhid
[ 14.036185] usbcore: registered new interface driver uvcvideo
[ 14.863032] usbcore: registered new interface driver rtl8xxxu
[ 420.318702] usbcore: registered new interface driver snd-usb-audio
[ 427.076834] usbcore: registered new interface driver cdc_ether
[ 427.089387] usbcore: registered new interface driver rndis_host
$ sudo dmesg | grep firmware
[ 0.236770] Spectre V2 : Enabling Restricted Speculation for firmware calls
[ 13.434323] usb 1-2: rtl8xxxu: Loading firmware rtlwifi/rtl8192eu_nic.bin
sending commands to master dhcpcd process
I have installed the drivers from the link above (https://aur.archlinux.org/packages/8192eu-dkms/) and it got completed without any errors.
I can see the SSIDs available and upon connecting i get an error connection to ‘BSSID’ is deactivated. i tried with wpa_supplicant and systemd.
$ cat /etc/wpa_supplicant/wpa_supplicant-wlp0s20u2.conf
ctrl_interface=/var/run/wpa_supplicant
network= <
ssid=»GNXS-43DC98″
psk=»password»
systemctl status wpa_supplicant
● wpa_supplicant.service — WPA supplicant
Loaded: loaded (/usr/lib/systemd/system/wpa_supplicant.service; disabled; vendor preset: disabled)
Active: active (running) since Sun 2019-09-15 13:24:44 IST; 34min ago
Main PID: 2560 (wpa_supplicant)
Tasks: 1 (limit: 4915)
Memory: 1.6M
CGroup: /system.slice/wpa_supplicant.service
└─2560 /usr/bin/wpa_supplicant -u
Sep 15 13:50:47 ninjabox wpa_supplicant[2560]: wlp0s20u2: CTRL-EVENT-SSID-REENABLED ssid=»GNXS-43DC98″
Sep 15 13:50:47 ninjabox wpa_supplicant[2560]: wlp0s20u2: SME: Trying to authenticate with 34:e3:80:43:dc:98 (SSID=’GNXS-43DC98′ freq=2432 MHz)
Sep 15 13:50:48 ninjabox wpa_supplicant[2560]: wlp0s20u2: CTRL-EVENT-SSID-TEMP-DISABLED ssid=»GNXS-43DC98″ auth_failures=2 duration=20 reason=CONN_FAILED
Sep 15 13:50:58 ninjabox wpa_supplicant[2560]: wlp0s20u2: CTRL-EVENT-SCAN-FAILED ret=-16
Sep 15 13:56:14 ninjabox wpa_supplicant[2560]: wlp0s20u2: SME: Trying to authenticate with 34:e3:80:43:dc:98 (SSID=’GNXS-43DC98′ freq=2432 MHz)
Sep 15 13:56:14 ninjabox wpa_supplicant[2560]: wlp0s20u2: CTRL-EVENT-SSID-TEMP-DISABLED ssid=»GNXS-43DC98″ auth_failures=1 duration=10 reason=CONN_FAILED
Sep 15 13:56:26 ninjabox wpa_supplicant[2560]: wlp0s20u2: CTRL-EVENT-SSID-REENABLED ssid=»GNXS-43DC98″
Sep 15 13:56:26 ninjabox wpa_supplicant[2560]: wlp0s20u2: SME: Trying to authenticate with 34:e3:80:43:dc:98 (SSID=’GNXS-43DC98′ freq=2432 MHz)
Sep 15 13:56:27 ninjabox wpa_supplicant[2560]: wlp0s20u2: CTRL-EVENT-SSID-TEMP-DISABLED ssid=»GNXS-43DC98″ auth_failures=2 duration=20 reason=CONN_FAILED
Sep 15 13:56:36 ninjabox wpa_supplicant[2560]: wlp0s20u2: Reject scan trigger since one is already pending
I tried blacklisting the old driver like the following.
Источник