Network Troubleshooting Tools
  • 05 Nov 2023
  • 8 Minutes to read
  • Dark
    Light

Network Troubleshooting Tools

  • Dark
    Light

Article Summary

Network troubleshooting is the act of discovering and correcting problems with connectivity, performance, security, and other aspects of networks.  This article introduces network troubleshooting tools used for different purposes. These tools are;

1. TELNET

TELNET is a protocol to provide communication over the Internet or a LAN using a virtual terminal connection.If you need to check a specific address and port, you can use the TELNET tool.

Installation:

➤ TELNET is most likely installed by default on Tegsoft images. If it is not, you can install using the command below:

yum -y install telnet


Usage:

➤ Enter the command below:

telnet <DESTINATION HOST OR IP> <PORT>

Example: telnet google.com 443


Outputs Examples:

➤ If TELNET successfully connects, a message displays similar to the following:

[root@server ~]# telnet google.com 443
Trying 142.250.185.142...
Connected to google.com.

➤ If TELNET fails to connect,a message displays similar to the following:

[root@server ~]# telnet google.com 10043
Trying 142.250.186.110...
telnet: connect to address 142.250.186.110: Connection timed out


➤ To exit the TELNET session, type Ctrl + ] for Windows, type Control + ü for MAC on your keyboard.
➤ This changes the command prompt to show as telnet>.
➤ Back in the terminal, type in the word 'quit' to end the session.
➤ If TELNET session successfully ends, a message displays similar to the following:

[root@server ~]# telnet google.com 443
Trying 216.58.212.174...
Connected to google.com.
Escape character is '^]'.
^]
telnet> quit
Connection closed.
[root@server ~]# 
For more information about telnet or access detailed manual page, open terminal and type the "man telnet" command.

2. TRACEROUTE

Traceroute, also called tracepath or tracert, is a network tool used to determine the path packets take from one IP address to another. If you need to check the trace of an IP Address, you can use the Traceroute tool.

Installation: 

➤ Traceroute is most likely installed by default on Tegsoft images. If it is not, you can install using the command below:

yum -y install traceroute


Usage:

➤ Enter the command below:

traceroute <DESTINATION_IP>

Example: traceroute 8.8.8.8


Outputs Examples:

➤ If Traceroute successfully connects, a message displays similar to the following:

[root@server ~]# traceroute 8.8.8.8
traceroute to 8.8.8.8 (8.8.8.8), 30 hops max, 60 byte packets
 1 *** HIDDEN FOR SECURITY***
 2 *** HIDDEN FOR SECURITY***
 3 *** HIDDEN FOR SECURITY***
 4 *** HIDDEN FOR SECURITY***
 5 *** HIDDEN FOR SECURITY***
 6  ipv4.de-cix.fra.de.as15169.google.com (80.81.193.108)  1.418 ms  1.432 ms nixcz.net.google.com (91.210.16.211)  8.173 ms
 7  108.170.251.129 (108.170.251.129)  1.476 ms 108.170.245.49 (108.170.245.49)  8.307 ms 108.170.251.193 (108.170.251.193)  1.875 ms
 8  142.250.236.57 (142.250.236.57)  1.565 ms 209.85.246.117 (209.85.246.117)  7.968 ms 142.251.224.129 (142.251.224.129)  8.267 ms
 9  dns.google (8.8.8.8)  1.509 ms  8.202 ms  8.303 ms

In this output, last row displays entered destination IP. This means that the server has successfully accessed the Destination IP.

➤ If Traceroute fails to connect,a message displays similar to the following:

[root@server ~]# traceroute 45.95.*HIDDEN*.*HIDDEN*
traceroute to 45.95.*HIDDEN*.*HIDDEN* (45.95.*HIDDEN*.*HIDDEN*), 30 hops max, 60 byte packets
1 ***HIDDEN FOR SECURITY***
2 ***HIDDEN FOR SECURITY***
3 ***HIDDEN FOR SECURITY***
4 ***HIDDEN FOR SECURITY***
5 ***HIDDEN FOR SECURITY***
6 ***HIDDEN FOR SECURITY***
7 ***HIDDEN FOR SECURITY***
8 ***HIDDEN FOR SECURITY***
9 ***HIDDEN FOR SECURITY***
10 ***HIDDEN FOR SECURITY***
11 ***HIDDEN FOR SECURITY***
12 ***HIDDEN FOR SECURITY***
13  * * *
14  * * *
15  * * *
16  * * *
17  * * *
18  * * *
19  * * *
20  * * *
21  * * *
22  * * *
23  * * *
24  * * *
25  * * *
26  * * *
27  * * *
28  * * *
29  * * *
30  * * *

In this output, after the 13th row it stops hopping to the next address. This is an example of blocked or unavailable destination point. 

For more information about traceroute or access detailed manual page, open terminal and type the "man traceroute" command.

3. OPENSSL

OpenSSL is an open-source command line tool that is commonly used to generate private keys, create CSRs, install your SSL/TLS certificate, and identify certificate information. If you need to check the SSL connection, you can use the OpenSSL tool.

Installation:

➤ OpenSSL is most likely installed by default on Tegsoft images. If it is not, you can install using the command below:

yum -y install openssl


Usage:

➤ Enter the command below:

openssl s_client -connect <DESTINATION HOST OR IP ADRESS>:<PORT>

Example: openssl s_client -connect google.com:443


Outputs Examples:

➤ If OpenSSL successfully connects, a message displays similar to the following:

[root@server ~]# openssl s_client -connect google.com:443
CONNECTED(00000003)
depth=3 C = BE, O = GlobalSign nv-sa, OU = Root CA, CN = GlobalSign Root CA
verify return:1
depth=2 C = US, O = Google Trust Services LLC, CN = GTS Root R1
verify return:1
depth=1 C = US, O = Google Trust Services LLC, CN = GTS CA 1C3
verify return:1
depth=0 CN = *.google.com
verify return:1
---
Certificate chain
 0 s:/CN=*.google.com
   i:/C=US/O=Google Trust Services LLC/CN=GTS CA 1C3
 1 s:/C=US/O=Google Trust Services LLC/CN=GTS CA 1C3
   i:/C=US/O=Google Trust Services LLC/CN=GTS Root R1
 2 s:/C=US/O=Google Trust Services LLC/CN=GTS Root R1
   i:/C=BE/O=GlobalSign nv-sa/OU=Root CA/CN=GlobalSign Root CA
---
Server certificate
AND SO MANY OTHER INFORMATIONS
AND SO MANY OTHER INFORMATIONS
AND SO MANY OTHER INFORMATIONS
AND SO MANY OTHER INFORMATIONS

This output contains information about SSL Connection, Handshake and Remote Server's Certificate detail.

➤ If SSL fails to connect, a different output than the above successful output is obtained. This indicates that the destination has SSL or network problems.

For more information about OpenSSL or access detailed manual page, open terminal and type the "man openssl" command.

4. MTR

A dynamic alternative to the traceroute program is MTR. Combining the functionality of ping and traceroute, MTR allows you to constantly poll a remote server and see how the latency and performance changes over time.

Installation: 

➤ MTR is not installed by default on Tegsoft images. You can install using the command below:

yum -y install mtr 


Usage:

➤ Enter the command below:

mtr <HOST OR IP ADRESS>

Example: mtr google.com

Outputs Examples:

➤ If MTR successfully connects, a message displays similar to the following:

➤ It is observed in this output whether the package goes to the destination and how much latency or drop is in each hop.

Frequently Used Commands:

➤  -c COUNT    Use this option to set the number of pings sent to determine both the machines on the network and the reliability of those machines. Each cycle lasts one second.

  -n    Use this option to force MTR to display numeric IP numbers and not try to resolve the host names.

  -i SECONDS    Use this option to specify the positive number of seconds between ICMP ECHO requests. The default value for this parameter is one second.

 An example of using the above commands together and message screen are given below.
  mtr -c 20 -i 5 -n google.com  

MTR has various flags which can be useful to troubleshoot network problems and live screen which updates itself with every packet sent.

For more information about MTR or access detailed manual page, open terminal and type the "man mtr" command.

5. PING

The Ping tool is used to test whether a particular host is reachable across an IP network. A Ping measures the time it takes for packets to be sent from the local host to a destination computer and back. The Ping tool measures and records the round-trip time of the packet and any losses along the way.

Installation:

➤ Ping is most likely installed by default on Tegsoft images and many Linux distributions. If it is not, you can install using the command below:

yum -y install iputils


Usage:

➤ Enter the command below:

ping <HOST OR IP ADRESS>

Example: ping google.com

Outputs Examples:

➤ If Ping successfully connects, a message displays similar to the following:

[root@server ~]# ping google.com
PING google.com (142.250.185.110) 56(84) bytes of data.
64 bytes from fra16s49-in-f14.1e100.net (142.250.185.110): icmp_seq=1 ttl=118 time=8.98 ms
64 bytes from fra16s49-in-f14.1e100.net (142.250.185.110): icmp_seq=2 ttl=118 time=8.19 ms
64 bytes from fra16s49-in-f14.1e100.net (142.250.185.110): icmp_seq=3 ttl=118 time=8.13 ms
64 bytes from fra16s49-in-f14.1e100.net (142.250.185.110): icmp_seq=4 ttl=118 time=8.23 ms
64 bytes from fra16s49-in-f14.1e100.net (142.250.185.110): icmp_seq=5 ttl=118 time=8.19 ms
64 bytes from fra16s49-in-f14.1e100.net (142.250.185.110): icmp_seq=6 ttl=118 time=8.17 ms
64 bytes from fra16s49-in-f14.1e100.net (142.250.185.110): icmp_seq=7 ttl=118 time=8.11 ms
^C
--- google.com ping statistics ---
7 packets transmitted, 7 received, 0% packet loss, time 6007ms
rtt min/avg/max/mdev = 8.111/8.290/8.985/0.286 ms

➤ If Ping fails to connect,a message displays similar to the following:

bash:~ ping exampleserver
PING exampleserver.site.com (%ipadress%): 56 data bytes
Request timeout for icmp_seq 0
Request timeout for icmp_seq 1
Request timeout for icmp_seq 2
Request timeout for icmp_seq 3
Request timeout for icmp_seq 4
Request timeout for icmp_seq 5
Request timeout for icmp_seq 6
Request timeout for icmp_seq 7
Request timeout for icmp_seq 8
Request timeout for icmp_seq 9
Request timeout for icmp_seq 10
Request timeout for icmp_seq 11
^C
--- exampleserver.site.com ping statistics ---
13 packets transmitted, 0 packets received, 100.0% packet loss

➤ You can press CONTROL + C to break and return to cli. 

Failure to get a response using the Ping tool does not mean that there is no access to the server, it should also be checked with more advanced tools; Telnet, Traceroute etc.
For more information about Ping or access detailed manual page, open terminal and type the "man ping" command.

6. DNS TROUBLESHOOTING

DNS troubleshooting helps to figure out whether the remote server is accessible or its DNS is resolved.

Usage:

➤ Enter the command below:

host <DESTINATION_DNS_RECORD>

 Example: host google.com

Outputs Examples:

➤ If DNS Troubleshooting successfully connects, a message displays similar to the following:

[root@arge12 ~]# host arge11.tegsoftcloud.com
arge11.tegsoftcloud.com has address 169.50.37.167

➤ IfDNS Troubleshooting fails to connect,a message displays similar to the following:

[root@arge12 ~]# host example.tegsoftcloud.com
Host example.tegsoftcloud.com not found: 3(NXDOMAIN)

When there are DNS resolution problems related to the server, DNS servers can be viewed using the following command.
cat /etc/resolv.conf |grep nameserver

Outputs Examples:
[root@server ~]# cat /etc/resolv.conf |grep nameserver
nameserver 192.168.1.1
nameserver 192.168.1.2



Tegsoft makes no representations or warranties, either express or implied, by or with respect to anything in this document, and shall not be liable for any implied warranties of merchantability or fitness for a particular purpose or for any indirect, special or consequential damages.

Copyright © 2021, Tegsoft. All rights reserved.

"Tegsoft" and Tegsoft’s products are trademarks of Tegsoft. References to other companies and their products use trademarks owned by the respective companies and are for reference purpose only.


Was this article helpful?

Changing your password will log you out immediately. Use the new password to log back in.
First name must have atleast 2 characters. Numbers and special characters are not allowed.
Last name must have atleast 1 characters. Numbers and special characters are not allowed.
Enter a valid email
Enter a valid password
Your profile has been successfully updated.