wlp2s0 с wpa_supplicant под NixOS
У меня есть система NixOS (nixos https://nixos.org/channels/nixos-18.03). С помощью wpa_supplicant
, Я не могу подключить беспроводную карту к домашней сети (WPA2).
Используется новая схема Systemd Predictable Network Interface Names (wlp2s0
заменяет wlan0
).
А) В соответствии с Руководством NixOS / 11.6 "Беспроводные сети" я установил sid и фразу-пароль WPA.
$ wpa_passphrase ESSID PSK > /etc/wpa_supplicant.conf
$ systemctl restart wpa_supplicant.service
wpa_supplicant
модуль может быть активным
$ systemctl status wpa_supplicant
● wpa_supplicant.service - WPA Supplicant
Loaded: loaded (/nix/store/fw6xw11p5nprhbchdgapj54js84zk97l-unit-wpa_supplicant.service/wpa_supplicant.service; enabled; vendor preset: enabled)
Active: active (running) since Sat 2019-03-09 14:40:43 EST; 1min 11s ago
Main PID: 800 (wpa_supplicant)
Tasks: 1 (limit: 4915)
CGroup: /system.slice/wpa_supplicant.service
└─800 wpa_supplicant -s -u -Dnl80211,wext -c /etc/wpa_supplicant.conf -iwlp2s0
Mar 09 14:40:43 nixos systemd[1]: Started WPA Supplicant.
Mar 09 14:40:48 nixos wpa_supplicant[800]: Successfully initialized wpa_supplicant
Или загружен, но неактивен.
$ systemctl status wpa_supplicant
● wpa_supplicant.service - WPA Supplicant
Loaded: loaded (/nix/store/fw6xw11p5nprhbchdgapj54js84zk97l-unit-wpa_supplicant.service/wpa_supplicant.service; enabled; vendor preset: enabled)
Active: inactive (dead) since Sat 2019-03-09 12:04:11 EST; 2h 30min ago
Process: 2017 ExecStart=/nix/store/77cvdnjyb1djvirr61591ipgnm6nx9mx-unit-script/bin/wpa_supplicant-start (code=exited, status=0/SUCCESS)
Main PID: 2017 (code=exited, status=0/SUCCESS)
Mar 09 11:59:03 nixos systemd[1]: Started WPA Supplicant.
Mar 09 11:59:03 nixos wpa_supplicant[2017]: Successfully initialized wpa_supplicant
Mar 09 12:04:11 nixos wpa_supplicant[2017]: nl80211: Failed to open /proc/sys/net/ipv4/conf/p2p-dev-wlp2s0/drop_unicast_in_l2_multicast: No such file or directo>
Mar 09 12:04:11 nixos wpa_supplicant[2017]: nl80211: Failed to set IPv4 unicast in multicast filter
Mar 09 12:04:11 nixos wpa_supplicant[2017]: nl80211: Failed to open /proc/sys/net/ipv4/conf/p2p-dev-wlp2s0/drop_unicast_in_l2_multicast: No such file or directo>
Mar 09 12:04:11 nixos wpa_supplicant[2017]: nl80211: Failed to set IPv4 unicast in multicast filter
Mar 09 12:04:11 nixos wpa_supplicant[2017]: nl80211: deinit ifname=p2p-dev-wlp2s0 disabled_11b_rates=0
Mar 09 12:04:11 nixos wpa_supplicant[2017]: p2p-dev-wlp2s0: CTRL-EVENT-TERMINATING
Mar 09 12:04:11 nixos wpa_supplicant[2017]: nl80211: deinit ifname=wlp2s0 disabled_11b_rates=0
Mar 09 12:04:11 nixos wpa_supplicant[2017]: wlp2s0: CTRL-EVENT-TERMINATING
В любом случае, я все еще не могу пинговать веб-адрес.
$ iwconfig
lo no wireless extensions.
wlp2s0 IEEE 802.11 ESSID:off/any
Mode:Managed Access Point: Not-Associated Tx-Power=0 dBm
Retry short limit:7 RTS thr:off Fragment thr:off
Encryption key:off
Power Management:on
enp0s20f0u2 no wireless extensions.
enp0s31f6 no wireless extensions.
Б) Я также поиграл с ручной настройкой SSID и парольной фразы. Но не игра в кости.
$ iwlist wlp2s0 scan
$ iwconfig wlp2s0 essid <mysid> key s:<mypassphrase>
C) Я покопался в интернете и нашел людей с похожими проблемами. Но эти решения не работают для меня (сбой, сброс, wlp2s0, повторное связывание с wpa_supplicant).
$ ip link set dev wlp2s0 down
$ ip addr flush dev wlp2s0
$ ip link set dev wlp2s0 up
$ wpa_supplicant -B -i wlp2s0 -c /etc/wpa_supplicant.conf
Successfully initialized wpa_supplicant
nl80211: Could not set interface 'p2p-dev-wlp2s0' UP
nl80211: deinit ifname=p2p-dev-wlp2s0 disabled_11b_rates=0
p2p-dev-wlp2s0: Failed to initialize driver interface
P2P: Failed to enable P2P Device interface