这种情况每天都会发生几次。WiFi 停止工作、断开连接、要求输入密码并且不接受正确的密码。它也无法连接到开放的 WiFi,尽管它可以看到它。
唯一有效的方法是从 USB 中物理移除网卡并将其重新放回。
如何诊断并纠正这个问题?
我的系统是kubuntu 16.04。
当 WiFi 断线时(Atheros 是设备),lsusb 的结果如下:
Bus 003 Device 005: ID 1058:0748 Western Digital Technologies, Inc. My Passport (WDBKXH, WDBY8L)
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 033: ID 0cf3:1006 Atheros Communications, Inc. TP-Link TL-WN322G v3 / TL-WN422G v2 802.11g [Atheros AR9271]
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 003: ID 04f9:0027 Brother Industries, Ltd HL-2030 Laser Printer
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 009 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 008 Device 012: ID 045e:00db Microsoft Corp. Natural Ergonomic Keyboard 4000 V1.0
Bus 008 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
dmesg 的结果(ath9k 和 wlan0 是罪魁祸首):
[749216.052827] smpboot: CPU 3 is now offline
[749216.063545] Broke affinity for irq 17
[749216.063551] Broke affinity for irq 19
[749216.063567] Broke affinity for irq 24
[749216.063570] Broke affinity for irq 26
[749216.064605] smpboot: CPU 4 is now offline
[749216.078758] Broke affinity for irq 1
[749216.078765] Broke affinity for irq 9
[749216.078768] Broke affinity for irq 12
[749216.078771] Broke affinity for irq 14
[749216.078777] Broke affinity for irq 17
[749216.078780] Broke affinity for irq 18
[749216.078783] Broke affinity for irq 19
[749216.078799] Broke affinity for irq 24
[749216.078803] Broke affinity for irq 26
[749216.079841] smpboot: CPU 5 is now offline
[749216.091770] ACPI: Low-level resume complete
[749216.091796] PM: Restoring platform NVS memory
[749216.091813] PCI-DMA: Resuming GART IOMMU
[749216.091813] PCI-DMA: Restoring GART aperture settings
[749216.091819] LVT offset 0 assigned for vector 0x400
[749216.098039] microcode: CPU0: new patch_level=0x0600084f
[749216.098091] Enabling non-boot CPUs ...
[749216.115914] x86: Booting SMP configuration:
[749216.115915] smpboot: Booting Node 0 Processor 1 APIC 0x1
[749216.118885] cache: parent cpu1 should not be sleeping
[749216.119052] CPU1 is up
[749216.140000] smpboot: Booting Node 0 Processor 2 APIC 0x2
[749216.142882] cache: parent cpu2 should not be sleeping
[749216.148271] microcode: CPU2: new patch_level=0x0600084f
[749216.148312] CPU2 is up
[749216.168015] smpboot: Booting Node 0 Processor 3 APIC 0x3
[749216.170934] cache: parent cpu3 should not be sleeping
[749216.171106] CPU3 is up
[749216.188062] smpboot: Booting Node 0 Processor 4 APIC 0x4
[749216.190998] cache: parent cpu4 should not be sleeping
[749216.196399] microcode: CPU4: new patch_level=0x0600084f
[749216.196443] CPU4 is up
[749216.216089] smpboot: Booting Node 0 Processor 5 APIC 0x5
[749216.219055] cache: parent cpu5 should not be sleeping
[749216.219225] CPU5 is up
[749216.226852] ACPI: Waking up from system sleep state S3
[749216.227251] ahci 0000:00:11.0: set SATA to AHCI mode
[749216.227288] ohci-pci 0000:00:12.0: System wakeup disabled by ACPI
[749216.227307] ohci-pci 0000:00:13.0: System wakeup disabled by ACPI
[749216.227403] ohci-pci 0000:00:14.5: System wakeup disabled by ACPI
[749216.227443] ohci-pci 0000:00:16.0: System wakeup disabled by ACPI
[749216.239896] ehci-pci 0000:00:16.2: System wakeup disabled by ACPI
[749216.239899] ehci-pci 0000:00:12.2: System wakeup disabled by ACPI
[749216.240005] pcieport 0000:00:04.0: System wakeup disabled by ACPI
[749216.240025] ehci-pci 0000:00:13.2: System wakeup disabled by ACPI
[749216.240132] PM: noirq resume of devices complete after 13.040 msecs
[749216.240638] PM: early resume of devices complete after 0.491 msecs
[749216.240763] rtc_cmos 00:02: System wakeup disabled by ACPI
[749216.240875] usb usb8: root hub lost power or was reset
[749216.240876] usb usb9: root hub lost power or was reset
[749216.240878] pcieport 0000:00:09.0: System wakeup disabled by ACPI
[749216.250500] [drm] probing gen 2 caps for device 1002:5a16 = 31cd02/0
[749216.250502] [drm] PCIE gen 2 link speeds already enabled
[749216.254068] [drm] PCIE GART of 2048M enabled (table at 0x00000000002E8000).
[749216.254165] radeon 0000:01:00.0: WB enabled
[749216.254166] radeon 0000:01:00.0: fence driver on ring 0 use gpu addr 0x0000000040000c00 and cpu addr 0xffff8800cf728c00
[749216.254168] radeon 0000:01:00.0: fence driver on ring 1 use gpu addr 0x0000000040000c04 and cpu addr 0xffff8800cf728c04
[749216.254169] radeon 0000:01:00.0: fence driver on ring 2 use gpu addr 0x0000000040000c08 and cpu addr 0xffff8800cf728c08
[749216.254170] radeon 0000:01:00.0: fence driver on ring 3 use gpu addr 0x0000000040000c0c and cpu addr 0xffff8800cf728c0c
[749216.254171] radeon 0000:01:00.0: fence driver on ring 4 use gpu addr 0x0000000040000c10 and cpu addr 0xffff8800cf728c10
[749216.254656] radeon 0000:01:00.0: fence driver on ring 5 use gpu addr 0x0000000000075a18 and cpu addr 0xffffc90001835a18
[749216.259852] sd 0:0:0:0: [sda] Starting disk
[749216.259878] sd 1:0:0:0: [sdb] Starting disk
[749216.274626] radeon 0000:01:00.0: fence driver on ring 6 use gpu addr 0x0000000040000c18 and cpu addr 0xffff8800cf728c18
[749216.274627] radeon 0000:01:00.0: fence driver on ring 7 use gpu addr 0x0000000040000c1c and cpu addr 0xffff8800cf728c1c
[749216.428086] ata5.00: ACPI cmd ef/03:08:00:00:00:a0 (SET FEATURES) filtered out
[749216.428088] ata5.00: ACPI cmd ef/03:22:00:00:00:a0 (SET FEATURES) filtered out
[749216.444189] ata5.00: configured for UDMA/33
[749216.575869] ata4: SATA link down (SStatus 0 SControl 300)
[749216.575913] ata3: SATA link down (SStatus 0 SControl 300)
[749216.723940] usb 8-2: reset low-speed USB device number 12 using xhci_hcd
[749216.777154] [drm] ring test on 0 succeeded in 1 usecs
[749216.777157] [drm] ring test on 1 succeeded in 1 usecs
[749216.777161] [drm] ring test on 2 succeeded in 1 usecs
[749216.777173] [drm] ring test on 3 succeeded in 9 usecs
[749216.777178] [drm] ring test on 4 succeeded in 3 usecs
[749216.778667] r8169 0000:03:00.0 eth7: link down
[749216.832445] usb 2-1: ath9k_htc: Transferred FW: ath9k_htc/htc_9271-1.4.0.fw, size: 51008
[749216.952880] [drm] ring test on 5 succeeded in 1 usecs
[749216.952897] [drm] UVD initialized successfully.
[749217.020479] usb 8-2: ep 0x81 - rounding interval to 64 microframes, ep desc says 80 microframes
[749217.020483] usb 8-2: ep 0x82 - rounding interval to 64 microframes, ep desc says 80 microframes
[749217.062064] [drm] ring test on 6 succeeded in 12 usecs
[749217.062076] [drm] ring test on 7 succeeded in 4 usecs
[749217.062077] [drm] VCE initialized successfully.
[749217.062105] [drm] ib test on ring 0 succeeded in 0 usecs
[749217.062128] [drm] ib test on ring 1 succeeded in 0 usecs
[749217.062151] [drm] ib test on ring 2 succeeded in 0 usecs
[749217.062180] [drm] ib test on ring 3 succeeded in 0 usecs
[749217.062204] [drm] ib test on ring 4 succeeded in 0 usecs
[749217.083382] ath9k_htc 2-1:1.0: ath9k_htc: HTC initialized with 33 credits
[749217.712061] [drm] ib test on ring 5 succeeded
[749218.212115] [drm] ib test on ring 6 succeeded
[749218.712162] [drm] ib test on ring 7 succeeded
[749218.963725] PM: resume of devices complete after 2722.782 msecs
[749218.964440] PM: Finishing wakeup.
[749218.964442] Restarting tasks ... done.
[749220.556312] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
[749220.562827] ata1.00: configured for UDMA/133
[749223.708652] ata2: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
[749223.708729] sd 1:0:0:0: [sdb] Start/Stop Unit failed: Result: hostbyte=DID_BAD_TARGET driverbyte=DRIVER_OK
[749223.746993] IPv6: ADDRCONF(NETDEV_UP): enp4s6: link is not ready
[749223.748788] IPv6: ADDRCONF(NETDEV_UP): eth7: link is not ready
[749223.870717] r8169 0000:03:00.0 eth7: link down
[749223.870826] IPv6: ADDRCONF(NETDEV_UP): eth7: link is not ready
[749223.872789] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[749224.032812] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[749224.077325] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[749225.168521] wlan0: authenticate with e8:94:f6:ca:dd:04
[749225.316786] wlan0: send auth to e8:94:f6:ca:dd:04 (try 1/3)
[749225.318975] wlan0: authenticated
[749225.320845] wlan0: associate with e8:94:f6:ca:dd:04 (try 1/3)
[749225.324848] wlan0: RX AssocResp from e8:94:f6:ca:dd:04 (capab=0x431 status=0 aid=2)
[749225.332465] wlan0: associated
[749225.332523] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
[749453.178896] sd 1:0:0:0: [sdb] tag#5 FAILED Result: hostbyte=DID_BAD_TARGET driverbyte=DRIVER_OK
[749453.178905] sd 1:0:0:0: [sdb] tag#5 CDB: ATA command pass through(16) 85 06 2c 00 00 00 00 00 00 00 00 00 00 00 e5 00
[749501.562825] wlan0: deauthenticating from e8:94:f6:ca:dd:04 by local choice (Reason: 3=DEAUTH_LEAVING)
[749501.641285] cfg80211: World regulatory domain updated:
[749501.641287] cfg80211: DFS Master region: unset
[749501.641289] cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
[749501.641293] cfg80211: (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
[749501.641296] cfg80211: (2457000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
[749501.641298] cfg80211: (2474000 KHz - 2494000 KHz @ 20000 KHz), (N/A, 2000 mBm), (N/A)
[749501.641300] cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
[749501.641302] cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
[749501.641304] cfg80211: (5490000 KHz - 5730000 KHz @ 160000 KHz), (N/A, 2000 mBm), (0 s)
[749501.641306] cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 2000 mBm), (N/A)
[749501.641308] cfg80211: (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm), (N/A)
[749502.735100] wlan0: authenticate with e8:94:f6:ca:dd:04
[749502.904046] wlan0: send auth to e8:94:f6:ca:dd:04 (try 1/3)
[749502.906145] wlan0: authenticated
[749502.910125] wlan0: associate with e8:94:f6:ca:dd:04 (try 1/3)
[749502.914198] wlan0: RX AssocResp from e8:94:f6:ca:dd:04 (capab=0x431 status=0 aid=2)
[749502.920385] wlan0: associated
[749512.922459] wlan0: deauthenticating from e8:94:f6:ca:dd:04 by local choice (Reason: 3=DEAUTH_LEAVING)
[749512.996216] cfg80211: World regulatory domain updated:
[749512.996220] cfg80211: DFS Master region: unset
[749512.996221] cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
[749512.996224] cfg80211: (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
[749512.996226] cfg80211: (2457000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
[749512.996227] cfg80211: (2474000 KHz - 2494000 KHz @ 20000 KHz), (N/A, 2000 mBm), (N/A)
[749512.996229] cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
[749512.996231] cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
[749512.996233] cfg80211: (5490000 KHz - 5730000 KHz @ 160000 KHz), (N/A, 2000 mBm), (0 s)
[749512.996235] cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 2000 mBm), (N/A)
[749512.996236] cfg80211: (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm), (N/A)