Check network connectivity
Using the ping command
Ping is one of the most commonly used and known commands. Administration utility is used to test whether a particular host is reachable across an Internet Protocol (IP) network and to measure the round-trip time for packets sent from the local host to a destination host, including the local host's own interfaces.
Ping uses Internet Control Message Protocol (ICMP) protocol for echo response and echo request. Ping sends ICMP echo request packets to the target host and waits for an ICMP response. Ping output displays the minimum, average and maximum times used for a ping packet to find a specified system and return.
From PC:
Windows:
Unix-like:
Press Ctrl-C to stop ping process.
From MikroTik:
Press Ctrl-C to stop ping process.
Using the traceroute command
Traceroute displays the list of the routers that the packet travels through to get to a remote host. The traceroute or tracepath tool is available on practically all Unix-like operating systems and tracert on Microsoft Windows operating systems.
Traceroute operation is based on TTL value and ICMP “Time Exceeded” message. Remember that TTL value in IP header is used to avoid routing loops. Each hop decrements TTL value by 1. If the TTL reaches zero, the packet is discarded and ICMP Time Exceeded message is sent back to the sender when this occurs.
Initially, by traceroute, the TTL value is set to 1 when the next router finds a packet with TTL = 1 it sets TTL value to zero, and responds with an ICMP "time exceeded" message to the source. This message lets the source know that the packet traverses that particular router as a hop. Next time TTL value is incremented by 1 and so on. Typically, each router in the path towards the destination decrements the TTL field by one unit TTL reaches zero.
Using this command you can see how packets travel through the network and where it may fail or slow down. Using this information you can determine the computer, router, switch or another network device that possibly causes network issues or failures.
From Personal computer:
Windows:
Unix-like:
Traceroute and tracepath is similar, only tracepath does not require superuser privileges.
From MikroTik:
0 Comments