Linux

How to Install and Use dig and nslookup commands in Linux

Dig and nslookup are DNS troubleshooting utilities that help you to get informations about domain names and also used for network troubelshooting.

In this article we will learn how to install dig and nslookup command on On Red Hat Linux /CentOS and ubuntu systems.

Installing dig and nslookup on RHEL/CentOS

On RHEL/CentOS, to install dig and nslookup you have to install a package called bind-utils. Run the dnf command bellow :

# dnf install bind-utils

To the dig’s version use the command bellow :

# dig -v

To the nslookup’s version use the command bellow :

# nslookup -v

Installing dig and nslookup on Ubuntu

On Debian and any of its derivatives including Debian, the installation is done using the apt command, and tha package is called dnsutils :

# apt install dnsutils

Again, to verify the installation, run the command :

# dig -v

Testing DNS troubleshooting commands

# dig www.sysreseau.net
# nslookup www.sysreseau.net

You might also like

Laisser un commentaire

Votre adresse e-mail ne sera pas publiée. Les champs obligatoires sont indiqués avec *