网络连接不断重启

网络连接不断重启

我的网络连接不稳定。几乎每分钟都会重启一次。

我连接了有线网络,我的 Ubuntu 机器在几秒内重置了互联网连接。当我查看系统日志时,我看到了以下日志:

我的系统日志输出:

May 28 05:17:12 main systemd-networkd[354]: enp4s0: Lost carrier
May 28 05:17:12 main kernel: [  821.785302] r8169 0000:04:00.0 enp4s0: link down
May 28 05:17:12 main systemd-timesyncd[677]: No network connectivity, watching for changes.
May 28 05:17:12 main avahi-daemon[761]: Withdrawing address record for 192.168.2.222 on enp4s0.
May 28 05:17:12 main avahi-daemon[761]: Leaving mDNS multicast group on interface enp4s0.IPv4 with address 192.168.2.222.
May 28 05:17:12 main avahi-daemon[761]: Interface enp4s0.IPv4 no longer relevant for mDNS.
May 28 05:17:12 main avahi-daemon[761]: Withdrawing address record for fdb3:fcc5:db9:0:d63d:7eff:fe35:b0e7 on enp4s0.
May 28 05:17:12 main avahi-daemon[761]: Leaving mDNS multicast group on interface enp4s0.IPv6 with address fdb3:fcc5:db9:0:d63d:7eff:fe35:b0e7.
May 28 05:17:12 main avahi-daemon[761]: Joining mDNS multicast group on interface enp4s0.IPv6 with address fe80::d63d:7eff:fe35:b0e7.
May 28 05:17:12 main avahi-daemon[761]: Registering new address record for fe80::d63d:7eff:fe35:b0e7 on enp4s0.*.
May 28 05:17:12 main /usr/lib/gdm3/gdm-x-session[1318]: [2239:2296:0528/081712.809053:ERROR:connection_factory_impl.cc(416)] Failed to connect to MCS endpoint with error -106
May 28 05:17:15 main systemd-networkd[354]: enp4s0: Gained carrier
May 28 05:17:15 main kernel: [  824.777361] r8169 0000:04:00.0 enp4s0: link up
May 28 05:17:15 main NetworkManager[750]: <info>  [1527484635.2960] device (enp4s0): carrier: link connected
May 28 05:17:15 main avahi-daemon[761]: Joining mDNS multicast group on interface enp4s0.IPv4 with address 192.168.2.222.
May 28 05:17:15 main avahi-daemon[761]: New relevant interface enp4s0.IPv4 for mDNS.
May 28 05:17:15 main avahi-daemon[761]: Registering new address record for 192.168.2.222 on enp4s0.IPv4.
May 28 05:17:15 main systemd-networkd[354]: enp4s0: Configured
May 28 05:17:16 main avahi-daemon[761]: Leaving mDNS multicast group on interface enp4s0.IPv6 with address fe80::d63d:7eff:fe35:b0e7.
May 28 05:17:16 main avahi-daemon[761]: Joining mDNS multicast group on interface enp4s0.IPv6 with address fdb3:fcc5:db9:0:d63d:7eff:fe35:b0e7.
May 28 05:17:16 main avahi-daemon[761]: Registering new address record for fdb3:fcc5:db9:0:d63d:7eff:fe35:b0e7 on enp4s0.*.
May 28 05:17:16 main avahi-daemon[761]: Withdrawing address record for fe80::d63d:7eff:fe35:b0e7 on enp4s0.
May 28 05:17:36 main kernel: [  845.721238] r8169 0000:04:00.0 enp4s0: link down
May 28 05:17:36 main systemd-networkd[354]: enp4s0: Lost carrier
May 28 05:17:36 main avahi-daemon[761]: Withdrawing address record for 192.168.2.222 on enp4s0.
May 28 05:17:36 main avahi-daemon[761]: Leaving mDNS multicast group on interface enp4s0.IPv4 with address 192.168.2.222.
May 28 05:17:36 main avahi-daemon[761]: Interface enp4s0.IPv4 no longer relevant for mDNS.
May 28 05:17:36 main systemd-timesyncd[677]: No network connectivity, watching for changes.
May 28 05:17:36 main avahi-daemon[761]: Withdrawing address record for fdb3:fcc5:db9:0:d63d:7eff:fe35:b0e7 on enp4s0.
May 28 05:17:36 main avahi-daemon[761]: Leaving mDNS multicast group on interface enp4s0.IPv6 with address fdb3:fcc5:db9:0:d63d:7eff:fe35:b0e7.
May 28 05:17:36 main avahi-daemon[761]: Joining mDNS multicast group on interface enp4s0.IPv6 with address fe80::d63d:7eff:fe35:b0e7.
May 28 05:17:36 main avahi-daemon[761]: Registering new address record for fe80::d63d:7eff:fe35:b0e7 on enp4s0.*.
May 28 05:17:38 main /usr/lib/gdm3/gdm-x-session[1318]: [2239:2296:0528/081738.242003:ERROR:connection_factory_impl.cc(416)] Failed to connect to MCS endpoint with error -106
May 28 05:17:39 main systemd-networkd[354]: enp4s0: Gained carrier
May 28 05:17:39 main NetworkManager[750]: <info>  [1527484659.2009] device (enp4s0): carrier: link connected
May 28 05:17:39 main kernel: [  848.685225] r8169 0000:04:00.0 enp4s0: link up
May 28 05:17:39 main avahi-daemon[761]: Joining mDNS multicast group on interface enp4s0.IPv4 with address 192.168.2.222.
May 28 05:17:39 main avahi-daemon[761]: New relevant interface enp4s0.IPv4 for mDNS.
May 28 05:17:39 main avahi-daemon[761]: Registering new address record for 192.168.2.222 on enp4s0.IPv4.
May 28 05:17:39 main systemd-networkd[354]: enp4s0: Configured
May 28 05:17:41 main avahi-daemon[761]: Leaving mDNS multicast group on interface enp4s0.IPv6 with address fe80::d63d:7eff:fe35:b0e7.
May 28 05:17:41 main avahi-daemon[761]: Joining mDNS multicast group on interface enp4s0.IPv6 with address fdb3:fcc5:db9:0:d63d:7eff:fe35:b0e7.
May 28 05:17:41 main avahi-daemon[761]: Registering new address record for fdb3:fcc5:db9:0:d63d:7eff:fe35:b0e7 on enp4s0.*.
May 28 05:17:41 main avahi-daemon[761]: Withdrawing address record for fe80::d63d:7eff:fe35:b0e7 on enp4s0.

我的 Inxi 输出:

System:    Host: main.u3g Kernel: 4.15.0-22-generic x86_64 bits: 64 gcc: 7.3.0 Desktop: i3 4.14.1
           Distro: Ubuntu 18.04 LTS
Machine:   Device: desktop System: MSI product: MS-7693 v: 2.0 serial: N/A
           Mobo: MSI model: 970A-G46 (MS-7693) v: 2.0 serial: N/A
           BIOS: American Megatrends v: V2.8 date: 01/08/2016
Battery    hidpp__0: charge: N/A condition: NA/NA Wh model: Logitech Wireless Keyboard K360 status: Discharging
CPU:       8 core AMD FX-8320 Eight-Core (-MCP-) arch: Bulldozer rev.0 cache: 16384 KB
           flags: (lm nx sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm) bmips: 56003
           clock speeds: max: 3500 MHz 1: 1399 MHz 2: 1396 MHz 3: 1580 MHz 4: 1627 MHz 5: 1398 MHz 6: 1397 MHz
           7: 1470 MHz 8: 1403 MHz
Graphics:  Card: Advanced Micro Devices [AMD/ATI] Pitcairn PRO [Radeon HD 7850 / R7 265 / R9 270 1024SP]
           bus-ID: 01:00.0
           Display Server: x11 (X.Org 1.19.6 ) driver: amdgpu
           Resolution: [email protected], [email protected], [email protected]
           OpenGL: renderer: AMD Radeon HD 7800 Series version: 4.6.13527 18.20.2.15 Direct Render: Yes
Audio:     Card-1 Advanced Micro Devices [AMD/ATI] SBx00 Azalia (Intel HDA)
           driver: snd_hda_intel bus-ID: 00:14.2
           Card-2 Advanced Micro Devices [AMD/ATI] Cape Verde/Pitcairn HDMI Audio [Radeon HD 7700/7800 Series]
           driver: snd_hda_intel bus-ID: 01:00.1
           Sound: Advanced Linux Sound Architecture v: k4.15.0-22-generic
Network:   Card: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller
           driver: r8169 v: 2.3LK-NAPI port: d000 bus-ID: 04:00.0
           IF: enp4s0 state: up speed: 100 Mbps duplex: full mac: <filter>
Drives:    HDD Total Size: 1861.4GB (5.0% used)
           ID-1: /dev/sda model: WDC_WD5001AALS size: 500.1GB
           ID-2: /dev/sdb model: WDC_WD10EZEX size: 1000.2GB
           ID-3: /dev/sdc model: KINGSTON_SHFS37A size: 240.1GB
           ID-4: /dev/sdd model: INTEL_SSDSC2CT12 size: 120.0GB
           ID-5: USB /dev/sde model: Cruzer_Micro size: 1.0GB
Partition: ID-1: / size: 59G used: 7.1G (13%) fs: ext4 dev: /dev/sdc1
           ID-2: /home size: 161G used: 30G (20%) fs: ext4 dev: /dev/sdc2
           ID-3: swap-1 size: 34.36GB used: 0.00GB (0%) fs: swap dev: /dev/sdb2
RAID:      No RAID devices: /proc/mdstat, md_mod kernel module present
Sensors:   System Temperatures: cpu: 19.9C mobo: N/A gpu: 67.0
           Fan Speeds (in rpm): cpu: N/A
Info:      Processes: 263 Uptime: 15 min Memory: 1905.0/15990.7MB Init: systemd runlevel: 5 Gcc sys: 7.3.0
           Client: Shell (zsh 5.4.2) inxi: 2.3.56

我相信我的问题源于这一行:

May 29 07:18:49 main /usr/lib/gdm3/gdm-x-session[1326]: [1857:1878:0529/071849.958728:ERROR:connection_factory_impl.cc(416)] Failed to connect to MCS endpoint with error -106

当我搜索此错误时,我主要发现 Google Chrome 错误,但却找不到有用的修复方法。

有人能帮我解决这个问题吗?

编辑:

新的日志行:

May 29 07:43:27 main avahi-daemon[763]: Joining mDNS multicast group on interface enp4s0.IPv4 with address 192.168.2.222.
May 29 07:43:27 main avahi-daemon[763]: New relevant interface enp4s0.IPv4 for mDNS.
May 29 07:43:27 main avahi-daemon[763]: Registering new address record for 192.168.2.222 on enp4s0.IPv4.
May 29 07:43:27 main systemd-networkd[356]: enp4s0: Configured
May 29 07:43:29 main systemd-resolved[679]: Using degraded feature set (UDP) for DNS server 8.8.8.8.
May 29 07:43:30 main avahi-daemon[763]: Leaving mDNS multicast group on interface enp4s0.IPv6 with address fe80::d63d:7eff:fe35:b0e7.
May 29 07:43:30 main avahi-daemon[763]: Joining mDNS multicast group on interface enp4s0.IPv6 with address fdb3:fcc5:db9:0:d63d:7eff:fe35:b0e7.
May 29 07:43:30 main avahi-daemon[763]: Registering new address record for fdb3:fcc5:db9:0:d63d:7eff:fe35:b0e7 on enp4s0.*.
May 29 07:43:30 main avahi-daemon[763]: Withdrawing address record for fe80::d63d:7eff:fe35:b0e7 on enp4s0.
May 29 07:43:30 main /usr/lib/gdm3/gdm-x-session[1309]: [2285:2299:0529/074330.157836:ERROR:connection_factory_impl.cc(416)] Failed to connect to MCS endpoint with error -21
May 29 07:43:30 main systemd-resolved[679]: Using degraded feature set (UDP) for DNS server 8.8.4.4.
May 29 07:43:32 main systemd-resolved[679]: Using degraded feature set (TCP) for DNS server 8.8.8.8.
May 29 07:43:34 main systemd-resolved[679]: Using degraded feature set (TCP) for DNS server 8.8.4.4.
May 29 07:43:49 main systemd-resolved[679]: Using degraded feature set (UDP) for DNS server 8.8.4.4.
May 29 07:43:50 main systemd-resolved[679]: Using degraded feature set (UDP) for DNS server 8.8.8.8.
May 29 07:43:52 main /usr/lib/gdm3/gdm-x-session[1309]: [2285:2299:0529/074352.174931:ERROR:connection_factory_impl.cc(416)] Failed to connect to MCS endpoint with error -105
May 29 07:43:55 main systemd-resolved[679]: Using degraded feature set (TCP) for DNS server 8.8.4.4.

修改 2:我的以太网芯片坏了。我尝试使用新的以太网卡,可以完美连接。

答案1

确保调制解调器中的 tcp 客户端服务器是否正常工作

使用网络命令,然后根据需要设置 ip 地址,或者可以使用谷歌的互联网帮助,输入“我的 ip 地址”并获取它,并根据您的宽带连接在相关时间内使用系统进行验证。

相关内容