On my desktop, the wifi connects on boot and all is well, but then randomly disconnects and is unable to reconnect.
I am uncertain the cause.
I use NetworkManager.
If anyone has any ideas or insight, please help.
Using a near identical configuration.nix, I have 2-3 other systems without this issue. Different hardware though.
Diagnostics
The following diagnostic commands are run after the wifi had disconnected.
neofetch --stdout
OS: NixOS 22.11.1777.cdead16a444 (Raccoon) x86_64
Host: ASUSTeK COMPUTER INC. ROG STRIX X670E-E GAMING WIFI
Kernel: 5.15.89
Uptime: 43 mins
Packages: 748 (nix-system)
Shell: bash 5.1.16
WM: i3
CPU: AMD Ryzen 9 7950X (32) @ 4.500GHz
Memory: 3289MiB / 127962Mi
NixOS multiuser: yes
Not using flakes.
lshw
snippet related to motherboard
version: Rev 1.xx
*-core
description: Motherboard
product: ROG STRIX X670E-E GAMING WIFI
vendor: ASUSTeK COMPUTER INC.
version: Rev 1.xx
*-firmware
description: BIOS
vendor: American Megatrends Inc.
version: 0805
date: 11/04/2022
size: 64KiB
capacity: 32MiB
capabilities: pci upgrade shadowing cdboot bootselect socketedrom edd int13floppynec int13floppytoshiba int13floppy360 int13floppy1200 int13floppy720 int13floppy2880 int5printscreen int14serial int17printer int10video acpi usb biosbootspecification uefi
I updated the bios to the latests provided for this motherboard on ASUS’ website, version 0805 as of 2022/11/15, from
lshw
snippet related to wireless
*-network DISABLED
description: Wireless interface
logical name: wlp9s0
version: 1a
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress msix cap_list ethernet physical wireless
configuration: broadcast=yes driver=iwlwifi driverversion=5.15.89 firmware=66.f1c864e0.0 ty-a0-gf-a0-66.uc ip=[ip address] latency=0 link=no multicast=yes wireless=IEEE 802.11
lspci | grep "Network\|Ethernet"
09:00.0 Network controller: Intel Corporation Wi-Fi 6 AX210/AX211/AX411 160MHz (rev 1a)
0a:00.0 Ethernet controller: Intel Corporation Ethernet Controller I225-V (rev 03)
modinfo iwlwifi
filename: /run/booted-system/kernel-modules/lib/modules/5.15.89/kernel/drivers/net/wireless/intel/iwlwifi/iwlwifi.ko.xz
license: GPL
author: Intel Corporation <linuxwifi@intel.com>
description: Intel(R) Wireless WiFi driver for Linux
< ... skipping firmware list : ~46 entries. ty-a0-gf-a0-66.ucode is included. ... >
< ... skipping aliases : ~406 entries ... >
depends: cfg80211
retpoline: Y
intree: Y
name: iwlwifi
vermagic: 5.15.89 SMP mod_unload
parm: swcrypto:using crypto in software (default 0 [hardware]) (int)
parm: 11n_disable:disable 11n functionality, bitmap: 1: full, 2: disable agg TX, 4: disable agg RX, 8 enable agg TX (uint)
parm: amsdu_size:amsdu size 0: 12K for multi Rx queue devices, 2K for AX210 devices, 4K for other devices 1:4K 2:8K 3:12K (16K buffers) 4: 2K (default 0) (int)
parm: fw_restart:restart firmware in case of error (default true) (bool)
parm: nvm_file:NVM file name (charp)
parm: uapsd_disable:disable U-APSD functionality bitmap 1: BSS 2: P2P Client (default: 3) (uint)
parm: enable_ini:Enable debug INI TLV FW debug infrastructure (default: true (bool)
parm: bt_coex_active:enable wifi/bt co-exist (default: enable) (bool)
parm: led_mode:0=system default, 1=On(RF On)/Off(RF Off), 2=blinking, 3=Off (default: 0) (int)
parm: power_save:enable WiFi power management (default: disable) (bool)
parm: power_level:default power save level (range from 1 - 5, default: 1) (int)
parm: disable_11ac:Disable VHT capabilities (default: false) (bool)
parm: remove_when_gone:Remove dev from PCIe bus if it is deemed inaccessible (default: false) (bool)
parm: disable_11ax:Disable HE capabilities (default: false) (bool)
lsmod | grep iwl
Module Size Used by
iwlmvm 409600 0
mac80211 1003520 1 iwlmvm
iwlwifi 430080 1 iwlmvm
cfg80211 1044480 3 iwlmvm,iwlwifi,mac80211
led_class 20480 3 input_leds,iwlmvm,asus_wmi
Confirming config.hardware.enableRedistributableFirmware is true
# nix repl --file '<nixpkgs/nixos>'
Welcome to Nix 2.11.1. Type :? for help.
Loading installable ''...
Added 6 variables.
nix-repl> config.hardware.enableRedistributableFirmware
true
A githib gist of the cleaned up dmesg | grep "iwl\|wlp"
: dmesg output when grepped for "iwl\|wlp" to observe issues in NixOS with iwlwifi on Asus ROG Strix mobo randomly disconnects from wifi and is unable to reconnect. Initial connection on boot is fine. · GitHub
What I have tried
I saw elsewhere that perhaps it is using older firmware, so I nix-garbage-collected to remove the older iwlwifi firmware, yesterday. Then it worked all day into evening, but has failed the next day (today) after shutdown in evening and startup in morning. Connection lasted for a bit, but then disconnected and stayed disconnected.
What I have yet to try
- Experiment with loading the module with certain params, such as those in: en:users:drivers:iwlwifi [Linux Wireless]
- examining the wifi modules, hardware, and firmware used on my working systems for comparison
- rolling back to 22.05 stable and seeing if it works.