User Tools

Site Tools


wiki:network_troubleshooting

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
wiki:network_troubleshooting [2023/05/09 14:55] – created antisawiki:network_troubleshooting [2025/12/17 12:20] (current) – add ip tags, network unreachable and service not known examples antisa
Line 1: Line 1:
-{{tag>network troubleshooting}}+{{tag>network troubleshooting ipv4 ipv6}}
  
 ====== network troubleshooting ====== ====== network troubleshooting ======
Line 11: Line 11:
   ip addr del 2a01:xxxx:xxxx:xxxx::2/64 dev enp35s0   ip addr del 2a01:xxxx:xxxx:xxxx::2/64 dev enp35s0
  
-====== Tested on ====== +===== Wired ethernet turns off and on constantly ===== 
-  +dmesg log:
  
-====== See also ======+<code> 
 +~$ sudo dmesg -H -w 
 +...
  
-====== References ======+[pro15 19:12] RTL8226B_RTL8221B 2.5Gbps PHY r8169-0-2a00:00: Downshift occurred from negotiated speed 100Mbps to actual speed 10Mbps, check cabling! 
 +[  +0,000012] r8169 0000:2a:00.0 enp42s0: Link is Up - 10Mbps/Full (downshifted) - flow control off 
 +[  +2,048824] r8169 0000:2a:00.0 enp42s0: Link is Down 
 +[  +8,959020] RTL8226B_RTL8221B 2.5Gbps PHY r8169-0-2a00:00: Downshift occurred from negotiated speed 100Mbps to actual speed 10Mbps, check cabling! 
 +[  +0,000014] r8169 0000:2a:00.0 enp42s0: Link is Up - 10Mbps/Full (downshifted) - flow control off 
 +[  +0,163394] r8169 0000:2a:00.0 enp42s0: Link is Down 
 +[  +1,240247] audit: type=1107 audit(1702663934.240:136): pid=1078 uid=103 auid=4294967295 ses=4294967295 subj=unconfined msg='apparmor="DENIED" operation="dbus_method_call"  bus="system" path="/org/freedesktop/timedate1" interface="org.freedesktop.DBus.Properties" member="GetAll" mask="send" name=":1.113" pid=2106 label="snap.firefox.firefox" peer_pid=5540 peer_label="unconfined" 
 +               exe="/usr/bin/dbus-daemon" sauid=103 hostname=? addr=? terminal=?'
  
 +[  +7,588296] RTL8226B_RTL8221B 2.5Gbps PHY r8169-0-2a00:00: Downshift occurred from negotiated speed 100Mbps to actual speed 10Mbps, check cabling!
 +[  +0,000013] r8169 0000:2a:00.0 enp42s0: Link is Up - 10Mbps/Full (downshifted) - flow control off
 +
 +
 +
 +
 +[  +1,259109] r8169 0000:2a:00.0 enp42s0: Link is Down
 +[  +8,866622] RTL8226B_RTL8221B 2.5Gbps PHY r8169-0-2a00:00: Downshift occurred from negotiated speed 100Mbps to actual speed 10Mbps, check cabling!
 +[  +0,000013] r8169 0000:2a:00.0 enp42s0: Link is Up - 10Mbps/Full (downshifted) - flow control off
 +[  +0,047328] r8169 0000:2a:00.0 enp42s0: Link is Down
 +[  +8,784982] RTL8226B_RTL8221B 2.5Gbps PHY r8169-0-2a00:00: Downshift occurred from negotiated speed 100Mbps to actual speed 10Mbps, check cabling!
 +[  +0,000012] r8169 0000:2a:00.0 enp42s0: Link is Up - 10Mbps/Full (downshifted) - flow control off
 +[  +0,214446] r8169 0000:2a:00.0 enp42s0: Link is Down
 +[ +11,364429] r8169 0000:04:00.0 enp4s0: Link is Up - 100Mbps/Full - flow control off
 +[  +0,000016] IPv6: ADDRCONF(NETDEV_CHANGE): enp4s0: link becomes ready
 +[  +0,500115] r8169 0000:04:00.0 enp4s0: Link is Down
 +...
 +</code>
 +
 +Check the cabling. Plug/unplug the cables from the router and other devices. After this the problem was resolved.
 +
 +===== ping: google.com: Name or service not known =====
 +
 +Check your ''/etc/resolv.conf'' if your distro is using that. On Ubuntu systemd-resolvd manages that file, so check systemd-resolvd service.
 +
 +If that seems fine, then it might a symptom of the below problem.
 +
 +===== connect: Network is unreachable =====
 +Happens when pinging an IP address.
 +
 +Most likely an issue with a missing route.
 +Check with ''ip r'' and add the route.
 +
 +Here's an example of missing route on a VM server with assigned IPs to the //eth0// interface already.
 +
 +<code>
 +# ip a
 +1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
 +    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
 +    inet 127.0.0.1/8 scope host lo
 +       valid_lft forever preferred_lft forever
 +    inet6 ::1/128 scope host
 +       valid_lft forever preferred_lft forever
 +2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
 +    link/ether 02:00:00:12:14:7c brd ff:ff:ff:ff:ff:ff
 +    inet 198.50.177.218/32 brd 198.50.177.218 scope global eth0
 +       valid_lft forever preferred_lft forever
 +    inet6 2607:5300:203:1735:198:50:177:218/64 scope global
 +       valid_lft forever preferred_lft forever
 +    inet6 fe80::ff:fe12:147c/64 scope link
 +       valid_lft forever preferred_lft forever
 +...
 +
 +# ip r
 +10.0.1.0/24 dev tun1 proto kernel scope link src 10.0.1.79
 +169.254.0.0/16 dev eth0 scope link metric 1002
 +172.17.0.0/16 dev docker0 proto kernel scope link src 172.17.0.1
 +...
 +
 +
 +# ip -6 r
 +unreachable ::/96 dev lo metric 1024 error -113 pref medium
 +unreachable ::ffff:0.0.0.0/96 dev lo metric 1024 error -113 pref medium
 +...
 +default via 2607:5300:203:1735:: dev eth0 metric 1 pref medium
 +default via 2607:5300:203:1735:: dev eth0 metric 1024 pref medium
 +...
 +[root@xor1 NetworkManager]# ip r
 +
 +</code>
 +
 +In above output ipv4 is missing a default route, and ipv6 is ok.
 +
 +To fix this case you would run:
 +
 +<code>
 +# ip route add 66.70.179.0/24 dev eth0 src 198.50.177.218
 +# ip route add default via 66.70.179.53
 +# ping 8.8.8.8
 +PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
 +64 bytes from 8.8.8.8: icmp_seq=1 ttl=113 time=1.31 ms
 +...
 +</code>
 +
 +You have to know the gateway IP, 66.70.179.53 above, then add a direct route to that because any gateway must be reachable directly on connected interfaces. This gateway IP is actually a bridge ''br0'' interface on the VM host and that's serving as the interface for all of the VMs there.
 +
 +====== See also ======
 +  * [[wiki:ubuntu_troubleshooting|Ubuntu troubleshooting]]
 +  * [[add_additional_ip_address_interface|Add additional ip address on interface]]
 +====== References ======
 +  * https://superuser.com/questions/1219289/im-unable-to-create-a-static-ip-route-error-says-rtnetlink-answers-network-i
  
wiki/network_troubleshooting.1683644155.txt.gz · Last modified: by antisa

Except where otherwise noted, content on this wiki is licensed under the following license: CC0 1.0 Universal
CC0 1.0 Universal Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki