User Tools

Site Tools


watchdogs:ping

Linux - Ping, trace route and TCP dump diagnostic utilities

Ping

Used to determine if you can reach a server

A Successful Ping :

ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8): 56 data bytes
64 bytes from 8.8.8.8: icmp_seq=0 ttl=57 time=12.892 ms
64 bytes from 8.8.8.8: icmp_seq=1 ttl=57 time=12.521 ms

An unsuccessful ping

ping 8.8.8.9
PING 8.8.8.9 (8.8.8.9): 56 data bytes
Request timeout for icmp_seq 0
Request timeout for icmp_seq 1

Can be entered in CMD or Linux Terminal ping <URL OR IP Address>

Trace Route

traceroute used to track route packets take to network host

Successful Traceroute

traceroute google.ie
traceroute to google.ie (216.58.194.195), 64 hops max, 52 byte packets
 1  10.5.5.1 (10.5.5.1)  1.181 ms  0.952 ms  0.903 ms
 2  d-clon-asr1k.magnet.ie (85.91.0.121)  11.605 ms  14.259 ms  14.413 ms
 3  d-clon-core1a.magnet.ie (85.91.0.116)  12.046 ms  15.637 ms  13.594 ms
 4  d-rte-core1a.magnet.ie (85.91.3.2)  12.648 ms  12.918 ms  10.985 ms
 5  85.91.3.181 (85.91.3.181)  14.005 ms  16.541 ms  14.225 ms
 6  74.125.50.253 (74.125.50.253)  12.336 ms  11.716 ms  12.230 ms
 7  209.85.252.198 (209.85.252.198)  11.406 ms  12.064 ms  12.008 ms
 8  216.239.42.241 (216.239.42.241)  21.312 ms  21.681 ms  21.833 ms
 9  108.170.236.33 (108.170.236.33)  98.285 ms
    216.239.42.223 (216.239.42.223)  98.982 ms  96.635 ms
10  209.85.253.248 (209.85.253.248)  111.174 ms  116.713 ms  115.174 ms
11  72.14.232.70 (72.14.232.70)  120.937 ms  119.599 ms  119.836 ms
12  209.85.251.139 (209.85.251.139)  130.766 ms  134.095 ms  130.749 ms
13  216.239.49.34 (216.239.49.34)  156.740 ms  156.260 ms  155.978 ms
14  209.85.249.62 (209.85.249.62)  156.036 ms
    209.85.246.39 (209.85.246.39)  156.995 ms  157.330 ms
15  108.170.242.225 (108.170.242.225)  159.291 ms
    108.170.243.1 (108.170.243.1)  158.126 ms  154.873 ms
16  108.170.237.105 (108.170.237.105)  155.194 ms  155.200 ms  155.623 ms
17  sfo03s01-in-f3.1e100.net (216.58.194.195)  160.806 ms  164.841 ms  170.866 ms

Unsuccessful Traceroute

traceroute 8.8.8.9
traceroute to 8.8.8.9 (8.8.8.9), 64 hops max, 52 byte packets
 1  10.5.5.1 (10.5.5.1)  1.075 ms  0.797 ms  0.782 ms
 2  d-clon-asr1k.magnet.ie (85.91.0.121)  17.426 ms  19.110 ms  17.468 ms
 3  d-clon-core1a.magnet.ie (85.91.0.116)  14.062 ms  15.015 ms  15.636 ms
 4  d-rte-core1a.magnet.ie (85.91.3.2)  17.509 ms  16.887 ms  13.270 ms
 5  85.91.3.181 (85.91.3.181)  13.070 ms  17.265 ms  74.194 ms
 6  74.125.50.253 (74.125.50.253)  11.457 ms  12.806 ms  13.088 ms
 7  209.85.252.196 (209.85.252.196)  17.259 ms  14.733 ms
    209.85.252.198 (209.85.252.198)  18.304 ms
 8  72.14.236.7 (72.14.236.7)  26.750 ms
    216.239.50.243 (216.239.50.243)  29.860 ms
    209.85.248.57 (209.85.248.57)  24.639 ms
 9  209.85.244.47 (209.85.244.47)  30.573 ms
    209.85.246.231 (209.85.246.231)  47.177 ms
    209.85.253.108 (209.85.253.108)  28.237 ms
10  108.170.237.131 (108.170.237.131)  26.928 ms
    108.170.232.7 (108.170.232.7)  28.285 ms
    72.14.238.201 (72.14.238.201)  29.297 ms
11  * * *
12  * * *

Note recurring * * * means that it cannot reach the server

Can be entered in Linux Terminal

traceroute <IP or URL>

TCP Dump

A lot can be done with TCP Dump such as monitoring traffic on a specific ethernet port or wifi. A specific port on that device such as port 8080 can be monitored or the traffic from a certain ip address can be monitored.

The data from tcpdump can be sent to a file but please visit http://www.tecmint.com/12-tcpdump-commands-a-network-sniffer-tool/

For a list of commonly used tcpdump commands.

Note as TCP may be listening on reserved ports you may need to run it as sudo

watchdogs/ping.txt · Last modified: 2021/06/25 10:09 by 127.0.0.1