Site icon Web hosting in Kenya & Domain Names in Kenya

DNS commands

And now, here are the commands. To use them, open your terminal on Linux/Mac or command line in Windows.

  1. Ping

This is by far the most common command used to quickly check for reachability of an IP. You can ping an IP, domain name, host name or even name server.

Usage: On Linux/Mac, open Terminal and type as follows:

[user@hostname ~]$ ping -c 4 127.0.0.1

[user@hostname ~]$ ping -c 4 truehost.co.ke

[user@hostname ~]$ ping -c 4 ns15.truehost.cloud

Note: You need to specify how many ping test should be run before ping stops. Otherwise you will need to manually stop the ping process by typing Ctrl+Z as it will continually ping

On windows open Command Line and type:

ping 127.0.0.1

ping truehost.co.ke

ping ns15.truehost.cloud

Other than checking the reachability of an IP, the ping command also displayed the IP address of the domain name or name server.

  1. Nslookup

This one is used to query the IP address, name servers and host name. If used to query a domain name or host name, it will provide an IP address for as a result if the domain name/host name is valid and reachable. If used to query an IP, it will provide the host name, PTR and name servers for the server owning the IP.

  1. traceroute / tracert

This one shows the path taken by a packet from your computer to the server. Typically, it displays the route taken by a packet to reach destination.

Usage: On Linux/Mac, the command is used as traceroute while on Windows, the command is used as tracert. To use, open Terminal and type

[user@hostname ~]$ traceroute truehost.co.ke

[user@hostname ~]$ traceroute 127.0.0.1

  1. host

This is probably the most powerful DNS tool available for Linux machines. It is a DNS lookup utility that us used to lookup all types of DNS records. All you’ll need to do is provide the correct option.

Usage:

Share some Love
Exit mobile version