Lab 8
Lab 8
Lab 8
Topology
Addressing Table
Default
Device Interface IP Address / Prefix Gateway
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 1 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
Default
Device Interface IP Address / Prefix Gateway
Objectives
Part 1: Build and Configure the Network
Part 2: Use Ping Command for Basic Network Testing
Part 3: Use Tracert and Traceroute Commands for Basic Network Testing
Part 4: Troubleshoot the Topology
Background / Scenario
Ping and traceroute are two tools that are indispensable when testing TCP/IP network
connectivity. Ping is a network administration utility used to test the reachability of a device on
an IP network. This utility also measures the round-trip time for messages sent from the
originating host to a destination computer. The ping utility is available on Windows, Unix-like
operating systems (OS), and the Cisco Internetwork Operating System (IOS).
The traceroute utility is a network diagnostic tool for displaying the path or route and measuring
the transit delays of packets travelling an IP network. The tracert utility is available on Windows,
and a similar utility, traceroute, is available on Unix-like OS and Cisco IOS.
In this lab, the ping and traceroute commands are examined and command options are
explored to modify the command behavior. Cisco devices and PCs are used in this lab for
command exploration. The necessary Cisco device configurations are provided in this lab.
Note: The routers used with CCNA hands-on labs are Cisco 4221 with Cisco IOS XE Release
16.9.4 (universalk9 image). The switches used in the labs are Cisco Catalyst 2960s with Cisco
IOS Release 15.2(2) (lanbasek9 image). Other routers, switches, and Cisco IOS versions can be
used. Depending on the model and Cisco IOS version, the commands available and the output
produced might vary from what is shown in the labs. Refer to the Router Interface Summary
Table at the end of the lab for the correct interface identifiers.
Note: Make sure that the routers and switches have been erased and have no startup
configurations. If you are unsure, contact your instructor.
The default bias template used by the Switch Database Manager (SDM) does not provide IPv6
address capabilities. Verify that SDM is using either the dual-ipv4-and-ipv6 template or the
lanbase-routing template. The new template will be used after reboot even if the
configuration is not saved.
S1# show sdm prefer
Use the following commands to assign the dual-ipv4-and-ipv6 template as the default SDM
template.
S1# configure terminal
S1(config)# sdm prefer dual-ipv4-and-ipv6 default
S1(config)# end
S1# reload
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 2 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
Required Resources
2 Routers (Cisco 4221 with Cisco IOS XE Release 16.9.4 universal image or comparable)
1 Switch (Cisco 2960 with Cisco IOS Release 15.2(2) lanbasek9 image or comparable)
2 PCs (Windows with terminal emulation program, such as Tera Term)
Console cables to configure the Cisco IOS devices via the console ports
Ethernet and serial cables as shown in the topology
Instructions
Part 1: Build and Configure the Network
In Part 1, you will set up the network in the topology and configure the PCs and Cisco devices.
The initial configurations for the routers and switches are provided for your reference. In this
topology, static routing is used to route packets between networks.
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 3 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
Step 2: Erase the configurations on the routers and switches, and reload the devices.
Step 4: Configure the R1 and ISP routers and S1 switch using the initial configurations
provided below.
At the switch or router global configuration mode prompt, copy and paste the configuration for
each device. Save the configuration to startup-config.
Initial configurations for the R1 router:
Open configuration window
hostname R1
no ip domain lookup
ipv6 unicast-routing
interface g0/0/0
ip address 64.100.0.2 255.255.255.252
ipv6 address 2001:db8:acad::2/64
ipv6 address fe80::2 link-local
ip nat outside
no shutdown
interface g0/0/1
ip add 192.168.1.1 255.255.255.0
ipv6 address 2001:db8:acad:1::1/64
ipv6 address fe80::1 link-local
ip nat inside
no shutdown
ip route 0.0.0.0 0.0.0.0 64.100.0.1
ipv6 route 0::/0 2001:db8:acad::1
access-list 1 permit 192.168.1.0 0.0.0.255
ip nat inside source list 1 interface g0/0/0 overload
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 4 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 5 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 6 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 7 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 8 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 9 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 10 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
b. From PC-A, ping the addresses listed in the following table and record the average round trip
time and IPv4 Time to Live (TTL) or IPv6 Hop Limit. Optional: Use WireShark to see the IPv6
Hop Limit value.
TTL / Hop
Destination Average Round Trip Time (ms) Limit
192.168.1.10 6 128
2001:db8:acad:1::10 0 128
2001:db8:acad:1::2(S1) 0 255
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 11 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
e. The above steps can be repeated for IPv6 address to obtain ICMP error message.
Question:
What ICMP error messages did you receive?
Request timed out.
f. Enable the GigabitEthernet 0/0/1 interface on the ISP router (using the no shutdown
command) before moving onto the next step. After about 30 seconds, the ping should be
successful again.
Close command prompt
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 12 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
Step 3: Test network connectivity from the R1 network using Cisco devices.
The ping command is also available on Cisco devices. In this step, the ping command is
examined using the R1 router and the S1 switch.
a. Ping External on the external network using the IP address of 209.165.200.226 from the R1
router.
R1# ping 209.165.200.226
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 209.165.200.226, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/1/1 ms
The exclamation point (!) indicates that the ping was successful from the R1 router to
External. The round trip takes an average of 1 ms with no packet loss, as indicated by a
100% success rate.
b. Because a local host table was configured on the R1 router, you can ping Externalv4 on the
external network using the hostname configured from the R1 router.
Note: The hostname is not case-sensitive. You can substitute the hostname for the IP
address if desired on R1 in this lab.
R1# ping externalv4
Question:
What is the IP address used?
209.165.200.226
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 13 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
c. There are more options available for the ping command. At the CLI, type ping and press
Enter. Use ipv6 as the protocol. Input 2001:DB8:ACAD:200::226 or external for the
Target IPv6 address. Press Enter to accept the default value for other options.
R1# ping
Protocol [ip]: ipv6
Target IPv6 address: 2001:db8:acad:200::226
Repeat count [5]:
Datagram size [100]:
Timeout in seconds [2]:
Extended commands? [no]:
Sweep range of sizes? [no]:
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001:DB8:ACAD:200::226, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/1/1 ms
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 14 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
d. You can use an extended ping to observe when there is a network issue. Start the ping
command to 209.165.200.226 with a repeat a count of 50000. Then, disconnect the cable
between the ISP router and EXTERNAL or shut down the GigabitEthernet 0/0/1 interface on
the ISP router.
Reconnect the Ethernet cable or enable the GigabitEthernet 0/0/1 interface on the ISP router
after the exclamation points (!) have replaced by the letter U and periods (.). After about 30
seconds, the ping should be successful again. Press Ctrl+Shift+6 to stop the ping
command if desired.
R1# ping
Protocol [ip]:
Target IP address: 209.165.200.226
Repeat count [5]: 10000
Datagram size [100]:
Timeout in seconds [2]:
Extended commands [n]:
Sweep range of sizes [n]:
Sending 500, 100-byte ICMP Echos to 209.165.200.226, timeout is 2 seconds:
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
<output omitted>
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!.U.U.U.U.U.
U.U................!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
<output omitted>
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!
Success rate is 99 percent (9970/10000), round-trip min/avg/max = 1/1/10 ms
The letter U in the results indicates that a destination is unreachable. An error protocol data
unit (PDU) was received by the R1 router. Each period (.) in the output indicates that the
ping timed out while waiting for a reply from External. In this example, 1% of the packets
were lost during the simulated network outage.
Note: You can also use the following commands for the same results:
R1# ping 209.165.200.226 repeat 10000
or
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 15 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
The tracert results indicates the path from PC-A to EXTERNAL is from PC-A to R1 to ISP to
EXTERNAL. The path to EXTERNAL traveled through two router hops to the final destination
of EXTERNAL.
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 16 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 17 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 18 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
Step 1: Copy and paste the following configuration into the ISP router.
Open configuration window
hostname ISP
interface g0/0/0
ip address 64.100.0.1 255.255.255.252
ipv6 address 2001:db8:acad::1/64
no shutdown
interface g0/0/1
ip address 192.168.8.1 255.255.255.0
no ipv6 address 2001:db8:acad:200::225/64
ipv6 address 2001:db8:acad:201::225/64
no shutdown
end
Close configuration window
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 19 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
Step 2: From the R1 network, use ping and tracert or traceroute commands to
troubleshoot and correct the problem on the ISP network.
a. Use the ping and tracert commands from PC-A.
You can use the tracert command to determine end-to-end network connectivity. This
tracert result indicates that PC-A can reach its default gateway of 192.168.1.1, but PC-A
does not have network connectivity with External.
Open command prompt
One way to locate the network issue is to ping each hop in the network to EXTERNAL. First
determine if PC-A can reach the ISP router g0/0/0 interface with an IP address of 64.100.0.1.
b. PC-A can reach the ISP router. Based on the successful ping results from PC-A to the ISP
router, the network connectivity issue is with 209.165.200.224/24 network. Ping the default
gateway to External, which is the GigabitEthernet 0/0/1 interface of the ISP router.
PC-A cannot reach the GigabitEthernet 0/0/1 interface of the ISP router, as displayed by the
results from the ping command.
The tracert and ping results conclude that PC-A can reach the R1 and ISP routers, but not
the External or default gateway for External.
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 20 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
c. Use the show commands to examine the running configurations for the ISP router.
Open configuration window
The outputs of the show run and show ip interface brief commands indicate that the
GigabitEthernet 0/0/1 interface is up/up, but was configured with an incorrect IP address.
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 21 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 22 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 23 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
f. Now repeat the process for IPv6 connectivity. Note: If you find an incorrect IPv6 address,
you will need to remove it because it is not replaced by a new ipv6 address command.
Reflection Questions
1. What could prevent ping or traceroute responses from reaching the originating device beside
network connectivity issues?
Firewall on the PCs, access list commands, routing issues, interface is down, network
delay
2. If you ping a non-existent address on the remote network, such as 209.165.200.227, what is the
message displayed by the ping command? What does this mean? If you ping a valid host
address and receive this response, what should you check?
Request timed out or periods (.). This means that there was no response in the
default time period. Some of the items you may check: router is down, destination
host is down, return route to your device and latency of the response is not more
than the default time period
3. If you ping an address that does not exist in any network in your topology, such as 192.168.5.3,
from a Windows-based PC, what is the message displayed by the ping command? What does
this message indicate?
Destination host unreachable. This message indicates that there is no route to the
destination as the network is not listed by the routing table.
4. What is the IPv4 TTL value set on the Windows host? What is the IPv4 TTL value set on a Cisco
device?
Windows sets the TTL value to 128 and the Cisco device will set the TTL value to 255.
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 24 of 25 www.netacad.com
Lab - Use Ping and Traceroute to Test Network Connectivity
5. What is the IPv6 Hop Limit value set on the Windows host? What is the IPv6 Hop Limit value set
on a Cisco device?
Windows sets the TTL value to 128, which is the same as IPv4 TTL value and the
Cisco device will set the TTL value to 64.
Fast Ethernet 0/0 Fast Ethernet 0/1 Serial 0/0/0 Serial 0/0/1
1800 (F0/0) (F0/1) (S0/0/0) (S0/0/1)
Gigabit Ethernet Gigabit Ethernet Serial 0/0/0 Serial 0/0/1
1900 0/0 (G0/0) 0/1 (G0/1) (S0/0/0) (S0/0/1)
Fast Ethernet 0/0 Fast Ethernet 0/1 Serial 0/1/0 Serial 0/1/1
2801 (F0/0) (F0/1) (S0/1/0) (S0/1/1)
Fast Ethernet 0/0 Fast Ethernet 0/1 Serial 0/0/0 Serial 0/0/1
2811 (F0/0) (F0/1) (S0/0/0) (S0/0/1)
Gigabit Ethernet Gigabit Ethernet Serial 0/0/0 Serial 0/0/1
2900 0/0 (G0/0) 0/1 (G0/1) (S0/0/0) (S0/0/1)
Gigabit Ethernet Gigabit Ethernet Serial 0/1/0 Serial 0/1/1
4221 0/0/0 (G0/0/0) 0/0/1 (G0/0/1) (S0/1/0) (S0/1/1)
Gigabit Ethernet Gigabit Ethernet Serial 0/1/0 Serial 0/1/1
4300 0/0/0 (G0/0/0) 0/0/1 (G0/0/1) (S0/1/0) (S0/1/1)
Note: To find out how the router is configured, look at the interfaces to identify the type of router
and how many interfaces the router has. There is no way to effectively list all the combinations of
configurations for each router class. This table includes identifiers for the possible combinations of
Ethernet and Serial interfaces in the device. The table does not include any other type of interface,
even though a specific router may contain one. An example of this might be an ISDN BRI interface.
The string in parenthesis is the legal abbreviation that can be used in Cisco IOS commands to
represent the interface.
End of document
2013 - 2024 Cisco and/or its affiliates. All rights reserved. Cisco Public Page 25 of 25 www.netacad.com