DEV Community

Cover image for DNS query without nslookup command
Alberto Gonzalez Escalante
Alberto Gonzalez Escalante

Posted on

DNS query without nslookup command

Problem

The nslookup command is not available on the system.

Solution

Use the command getent hosts.

getent hosts agonza.net
Enter fullscreen mode Exit fullscreen mode

Explanation

Most of the time, the getent command is available.

Other options include using dig or host, however, if the nslookup utility is not available, these commands are usually not installed either.

Top comments (0)