Linux 技术手札

解决 nslookup, dig , host Command Not Found

nslookup, dig 及 host 这三个指令是 DNS 查询工具, 对 DNS 除错很实用, 原因是系统没有安装以上工具的套件, 执行以上指令会出现 Command Not Found:

nslookup :command not found

dig :command not found

host:command not found

只要安装相关的套件包即可解决问题, RHEL 及 CentOS 安装 bind-utils; Debian 及 Ubuntu 安装 dnsutils:

RHEL / CentOS

# yum install bind-utils

Debian / Ubuntu

$ sudo apt-get install dnsutils
Exit mobile version