
dig
我在新安裝的 CentOS 上找不到該指令。我已經嘗試過dnf install dig
,但它說找不到該包。
如何在 CentOS 上安裝 dig?
答案1
這挖工具是的一部分綁定實用程序,因此您需要安裝它們。若要安裝 BIND 實用程序,請鍵入以下內容:
$ dnf install bind-utils
答案2
您已經提供了具體的答案,但是如果您正在尋找其他可執行檔或檔案來查看它們安裝的軟體包,請使用yum whatprovides *relative/path/to/file*
,例如:
$ yum whatprovides '*bin/dig'
32:bind-utils-9.8.2-0.17.rc1.el6_4.6.x86_64 : Utilities for querying DNS name servers
Repo : base
Matched from:
Filename : /usr/bin/dig
...
從man yum
:
provides or whatprovides
Is used to find out which package provides some feature or file. Just
use a specific name or a file-glob-syntax wildcards to list the pack-
ages available or installed that provide that feature or file.
答案3
在舊系統上,您必須使用yum
:
$ yum install bind-utils