我已经双启动 Linux 大约三个星期了,这个问题使我无法完全切换,因为我大约每小时都要重新启动计算机。在 Linux 上,我遇到网络随机断开的情况。启动进入 Windows 时,我没有遇到该问题,因此这可能是软件问题。
当我断开连接时,系统会尝试重新连接,但这永远不会起作用。重新启动后,问题就会消失,直到再次发生,通常是启动后 15 分钟到 2 小时。
问题发生时,我禁用了有线连接并连接到 Wi-Fi。一切正常,但当我重新启用有线连接时,即使 Wi-Fi 仍然连接,它也停止工作。
我也尝试过:
- 重新启动 NetworkManager 服务
- 设置固定 IPv4
- 禁用和启用有线网络
- 拔下并重新插入网络电缆
一切都没有成功。重启可以暂时解决问题
系统
OS: NixOS 23.05.3701.e9b4b56e5a20 (Stoat) x86_64
Motherboard: ASUSTeK COMPUTER INC. ROG STRIX B650E-E GAMING WIFI
Kernel: 6.1.54
CPU: AMD Ryzen 9 7950X
lspci
07:00.0 Ethernet controller: Intel Corporation Ethernet Controller I225-V (rev 03)
08:00.0 Network controller: MEDIATEK Corp. MT7922 802.11ax PCI Express Wireless Network Adapter
发生这种情况时网络管理器启动时的日志
Okt 16 16:19:13 nixos systemd[1]: Starting Network Manager...
Okt 16 16:19:13 nixos systemd[1]: Started Network Manager.
Okt 16 16:36:01 nixos systemd[1]: Stopping Network Manager...
Okt 16 16:36:01 nixos systemd[1]: NetworkManager.service: Deactivated successfully.
Okt 16 16:36:01 nixos systemd[1]: Stopped Network Manager.
Okt 16 16:36:01 nixos systemd[1]: NetworkManager.service: Consumed 196ms CPU time, received 8.6K IP traffic, sent 144B IP traffic.
来自另一个损坏的启动的 NetworkManager 日志
Okt 13 23:29:58 nixos systemd[1]: Starting Network Manager...
Okt 13 23:29:58 nixos systemd[1]: Started Network Manager.
Okt 13 21:59:47 nixos NetworkManager[1671]: <warn> [1697227187.1589] device (eno1): Activation: failed for connection 'Wired connection 1'
Okt 13 22:00:32 nixos NetworkManager[1671]: <warn> [1697227232.1589] device (eno1): Activation: failed for connection 'Wired connection 1'
Okt 13 22:01:17 nixos NetworkManager[1671]: <warn> [1697227277.1583] device (eno1): Activation: failed for connection 'Wired connection 1'
Okt 13 22:02:02 nixos NetworkManager[1671]: <warn> [1697227322.1592] device (eno1): Activation: failed for connection 'Wired connection 1'
Okt 13 22:06:00 nixos NetworkManager[1671]: <warn> [1697227560.1590] device (eno1): Activation: failed for connection 'Wired connection 1'
Okt 13 22:06:58 nixos NetworkManager[1671]: <warn> [1697227618.1576] device (eno1): Activation: failed for connection 'Wired connection 1'
Okt 13 22:07:16 nixos NetworkManager[1671]: <warn> [1697227636.1919] ndisc[0x13b38e0,"eno1"]: solicit: failure sending router solicitation: Cannot assign requested address (99)
Okt 13 22:07:28 nixos systemd[1]: Stopping Network Manager...
Okt 13 22:07:28 nixos systemd[1]: NetworkManager.service: Deactivated successfully.
Okt 13 22:07:28 nixos systemd[1]: Stopped Network Manager.
Okt 13 22:07:28 nixos systemd[1]: NetworkManager.service: Consumed 592ms CPU time, received 4.3K IP traffic, sent 1.3K IP traffic.
ip a / 工作时
2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether a0:36:bc:ba:a5:dd brd ff:ff:ff:ff:ff:ff
altname enp7s0
inet 192.168.10.59/24 brd 192.168.10.255 scope global noprefixroute eno1
valid_lft forever preferred_lft forever
inet6 2001:9e8:242b:c200:d7a:ee39:3768:342a/64 scope global temporary dynamic
valid_lft 7193sec preferred_lft 3593sec
inet6 2001:9e8:242b:c200:d1dc:fab3:1015:82ee/64 scope global dynamic mngtmpaddr noprefixroute
valid_lft 7193sec preferred_lft 3593sec
inet6 fe80::6a74:a49d:4dbd:72c0/64 scope link noprefixroute
valid_lft forever preferred_lft forever
ip a / 断线时
2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether a0:36:bc:ba:a5:dd brd ff:ff:ff:ff:ff:ff
altname enp7s0
inet 192.168.10.59/24 brd 192.168.10.255 scope global noprefixroute eno1
valid_lft forever preferred_lft forever
inet6 fe80::6a74:a49d:4dbd:72c0/64 scope link noprefixroute
valid_lft forever preferred_lft forever
lshw -C 网络/工作时
*-network
description: Ethernet interface
physical id: 0
bus info: pci@0000:07:00.0
logical name: eno1
version: 03
serial: a0:36:bc:ba:a5:dd
size: 1Gbit/s
capacity: 1Gbit/s
width: 32 bits
clock: 33MHz
capabilities: bus_master cap_list ethernet physical tp 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation
configuration: autonegotiation=on broadcast=yes driver=igc driverversion=6.1.54 duplex=full firmware=1082:8770 ip=192.168.10.59 latency=0 link=yes multicast=yes port=twisted pair speed=1Gbit/s
resources: irq:24 memory:fb400000-fb4fffff memory:fb500000-fb503fff
*-network DISABLED
description: Wireless interface
physical id: 0
bus info: pci@0000:08:00.0
logical name: wlp8s0
version: 00
serial: 86:8c:02:55:26:28
width: 64 bits
clock: 33MHz
capabilities: bus_master cap_list ethernet physical wireless
configuration: broadcast=yes driver=mt7921e driverversion=6.1.54 firmware=____000000-20230627143946 latency=0 link=no multicast=yes wireless=IEEE 802.11
resources: irq:170 memory:fb200000-fb2fffff memory:fb300000-fb307fff
lshw -C 网络/断线时
*-network
description: Ethernet interface
physical id: 0
bus info: pci@0000:07:00.0
logical name: eno1
version: 03
serial: a0:36:bc:ba:a5:dd
width: 32 bits
clock: 33MHz
capabilities: cap_list ethernet physical
configuration: broadcast=yes driver=igc ip=192.168.10.59 latency=0 multicast=yes
resources: irq:24 memory:fb400000-fb4fffff memory:fb500000-fb503fff
*-network DISABLED
description: Wireless interface
physical id: 0
bus info: pci@0000:08:00.0
logical name: wlp8s0
version: 00
serial: 32:93:9c:fa:3b:9b
width: 64 bits
clock: 33MHz
capabilities: bus_master cap_list ethernet physical wireless
configuration: broadcast=yes driver=mt7921e driverversion=6.1.54 firmware=____000000-20230627143946 latency=0 link=no multicast=yes wireless=IEEE 802.11
resources: irq:170 memory:fb200000-fb2fffff memory:fb300000-fb307fff