Computer Networks/Ping/Host

The command to ping a host is ping <host>, where <host> is the host name or IP address of the host you want to ping. These activities will show you how to use the ping command to ping a host.

Preparation

edit

To prepare for this activity:

  1. Start Windows.
  2. Log in if necessary.

Activity 1 - Ping Loopback Address

edit

To test whether or not TCP/IP is functioning on the local host, first ping the loopback address 127.0.0.1:

  1. Open a command prompt.
  2. Type ping 127.0.0.1 and press Enter.
  3. Observe the results. You should see replies indicating success.

Activity 2 - Ping Localhost

edit

To test host name cache resolution, ping the name localhost. This is an alias for the loopback address:

  1. Type ping localhost and press Enter.
  2. Observe the results. You should see replies indicating success.

Activity 3 - Ping the Host IPv4 Address

edit

To test the local host IPv4 address:

  1. Use ipconfig to display the host IP address. Note the IPv4 Address displayed.
  2. Type ping <IPv4 Address> where <IPv4 Address> is the IPv4 address displayed above. For example, if the IPv4 address was 192.168.1.101, you would type ping 192.168.1.101. Then press Enter.
  3. Observe the results. You should see replies indicating success.

Activity 4 - Ping the Host Name

edit

To test the local host name:

  1. Use ipconfig /all to display the host name. Note the Host Name displayed.
  2. Type ping <hostname> where <hostname> is the Host Name IPv4 address displayed above. For example, if the host name was host1, you would type ping host1. Then press Enter.
  3. Observe the results. You should see replies indicating success.

Activity 5 - Ping the Default Gateway

edit

To test local network connectivity:

  1. Use ipconfig to display the default gateway address. Note the Default Gateway displayed.
  2. Type ping <default gateway address> where <default gateway address> is the default gateway address displayed above. For example, if the default gateway address was 192.168.1.1, you would type ping 192.168.1.1. Then press Enter.
  3. Observe the results. If you see replies indicating success, you have local network connectivity.

Activity 6 - Ping an Internet Host by IPv4 Address

edit

8.8.8.8 is the IPv4 address of one of Google's public DNS servers. To test Internet connectivity:

  1. Type ping 8.8.8.8 and press Enter.
  2. Observe the results. If you see replies indicating success, you have Internet connectivity.

Activity 7 - Ping an Internet Host by Name

edit

google-public-dns-a.google.com is the host name of one of Google's public DNS servers. To test Internet connectivity with host name resolution:

  1. Type ping google-public-dns-a.google.com and press Enter.
  2. Observe the results. If you see replies indicating success, you have Internet connectivity and host name resolution.

Activity 8 - Ping an Internet Host by IPv6 Address

edit

2001:4860:4860::8888 is the IPv6 address of one of Google's public DNS servers. To test IPv6 Internet connectivity:

  1. Type ping 2001:4860:4860::8888 and press Enter.
  2. Observe the results. If you see replies indicating success, you have IPv6 Internet connectivity.

Activity 9 - Ping an Internet Host by IPv6 Name

edit

ipv6.google.com is the IPv6-only host name of Google's web servers. To test Internet connectivity with IPv6 host name resolution:

  1. Type ping ipv6.google.com and press Enter.
  2. Observe the results. If you see replies indicating success, you have Internet connectivity and IPv6 host name resolution.
  3. Close the command prompt to complete this activity.

Readings

edit

References

edit

See also

edit