Red Hat Enterprise Linux Diagnostics and Troubleshooting
Repair a network delay issue.
Outcomes
You should be able to successfully repair a network delay issue.
As the student user on the workstation machine, use the lab command to prepare your system for this exercise.
This command installs a custom application on your system.
[student@workstation ~]$ lab start compreview-review5
Specifications
Users on the
serverasystem report delays when connecting to theserverbsystem. Specifically, users notice a small delay before connecting via SSH. Investigate and repair the issue that is causing the delay.The systems use the following IP address scheme:
servera:172.25.250.10/24,fd37:5265:6448:6174::a/64serverb:172.25.250.11/24,fd37:5265:6448:6174::b/64
Re-create the issue.
Log in to
serveraand switch to therootuser.[student@workstation ~]$
ssh student@servera...output omitted... [student@servera ~]$sudo -i[sudo] password for student:student[root@servera ~]#Use the
sshcommand to perform a remote command on theserverbsystem as thestudentuser. Note the time that it takes to connect. When prompted, providestudentas the password.A small delay occurs before the connection is established.
[root@servera ~]#
ssh student@serverb echo hello...delay... The authenticity of host 'serverb (172.25.250.11)' can't be established. ECDSA key fingerprint is SHA256:NJAyJMx8B2AeIYHRnVLAuJ1XZwblomyOKowyfTwGrTY. Are you sure you want to continue connecting (yes/no/[fingerprint])?yesWarning: Permanently added 'serverb,172.25.250.11' (ECDSA) to the list of known hosts. student@serverb's password:studenthello
Gather information.
Use
straceto run thesshcommand to discover whether the command stalls at a specific point.The output pauses on a specific
connectsystem call.[root@servera ~]#
strace ssh student@serverb echo hello...output omitted...This system call, and the subsequent
getsocknamecall, show a failed attempt to connect to an IPv6 socket on theserverbsystem. When these attempts fail, an IPv4 socket is successfully opened.connect(5, {sa_family=AF_INET6, sin6_port=htons(22), sin6_flowinfo=htonl(0), inet_pton(AF_INET6, "fd37:5265:6448:6174::b", &sin6_addr), sin6_scope_id=0}, 28Inspect the IP addresses of the
serverbsystem.The IPv6 address on the
eth1interface is correctly configured. Because the IPv4 protocol succesfully connects, it is likely that a rule is preventing IPv6 traffic from reachingserverb.[root@servera ~]#
ssh student@serverb ip addrstudent@serverb's password:student1: 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 fq_codel state UP group default qlen 1000 link/ether 52:54:00:00:fa:0b brd ff:ff:ff:ff:ff:ff inet 172.25.250.11/24 brd 172.25.250.255 scope global noprefixroute eth0 valid_lft forever preferred_lft forever inet6 fe80::6dab:7b1:80c9:4f7f/64 scope link noprefixroute valid_lft forever preferred_lft forever 3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 8942 qdisc fq_codel state UP group default qlen 1000 link/ether 52:54:00:01:fa:0b brd ff:ff:ff:ff:ff:ff inet6 fd37:5265:6448:6174::b/64 scope global noprefixroute valid_lft forever preferred_lft forever inet6 fe80::a969:1f7e:a542:51b2/64 scope link noprefixroute valid_lft forever preferred_lft forever
Fix and then verify that the issue is resolved.
From the
workstationsystem, open a new terminal. Log in toserverband switch to therootuser.[student@workstation ~]$
ssh student@serverb...output omitted... [student@serverb ~]$sudo -i[sudo] password for student:student[root@serverb ~]#Inspect the firewall rules.
A rich rule is denying all incoming IPv6 traffic.
[root@serverb ~]#
firewall-cmd --list-allpublic (active) target: default icmp-block-inversion: no interfaces: eth0 eth1 sources: services: cockpit dhcpv6-client http ssh ports: protocols: masquerade: no forward-ports: source-ports: icmp-blocks: rich rules: rule family="ipv6" source address="0::0/0" rejectRemove the unwanted rule and reload the firewall.
[root@serverb ~]#
firewall-cmd --permanent --remove-rich-rule='rule family="ipv6" source address="0::0/0" reject'[root@serverb ~]#firewall-cmd --reloadFrom the terminal that is connected to
servera, attempt thesshcommand again. Verify that the delay no longer occurs.[root@servera ~]#
ssh student@serverb echo hello...output omitted...Close the additional terminal to
serverband return toworkstationas thestudentuser.[root@serverb ~]#
exit[student@serverb ~]$exit[student@workstation ~]$exit[root@servera ~]#
exit[student@servera ~]$exit[student@workstation ~]$