dnsmx command not found
Introduction
When you run more command in linux terminal / console, you get the following error message
dnsmx: command not found
or when using sudo you get the following error message
sudo: dnsmx: command not found
Solutions to dnsmx: command not found
How To Fix dnsmx: command not found in Ubuntu / Debian / Kali Linux / Raspbian
In Ubuntu dnsmx is provided by djbdns-utils package.
djbdns-utils is:
This package provides number of tools for working with DNS, that can be used to diagnose misconfigured remote servers.
- dnsfilter - reverse-resolves IP addresses, converting them to host names.
- dnsip, dnsipq - lookup IP addresses.
- dnsmx - prints the MX records of fqdn.
- dnsname - does a reverse lookup for the IP address.
- dnsq - sends a non-recursive DNS query to DNS server.
- dnsqr - asks for records of specified type under a the domain name
- dnstrace searches for all DNS servers that can affect the resolution of records of specified type under a domain name, starting from the root server.
- dnstxt - prints the TXT record of fqdn.
- random-ip - print random IPv4 addresses.
This package also includes users guide to name qualification.
To fix this problem, we can install more using the command below.
sudo apt-get -y install djbdns-utils
This command might take some time to finish depending on your machine internet connection.
You can also use apt command to install djbdns-utils.
sudo apt -y install djbdns-utils
Or if you have aptitude installed you can use the following command.
sudo aptitude install djbdns-utils
Summary
In this tutorial we learn how to fix dnsmx command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.