Ubuntu dig command not found – How to install dig on Ubuntu

The dig command is part of the dnsutils package in Ubuntu. To install the dig command on Ubuntu, you can use the apt package manager.

Here are the steps to install dig command on Ubuntu:

  1. Open a terminal window on your Ubuntu system.
  2. Run the following command to update the package list and ensure that you have the latest version of dnsutils package:
sudo apt update
  1. Run the following command to install the dnsutils package, which includes the dig command:
sudo apt install dnsutils
  1. Once the installation is complete, you can verify that the dig command is installed by running the following command:
dig --version
  1. Now you can use the dig command to query DNS servers for information about a domain or IP address.

Note: In some cases you might have to run the command with sudo prefix. Also, depending on your ubuntu version and package manager you might have to use apt-get instead of apt.

Leave a Comment