← 返回命令列表

Linux command

kdig 命令

文本

复制后可按需替换文件名、目录或参数。

常用示例

Query A record

kdig [example.com] A

Query specific server

kdig [example.com] @[8.8.8.8]

Query using TCP

kdig +tcp [example.com]

Query using TLS (DoT)

kdig +tls [example.com] @[1.1.1.1]

Perform zone transfer

kdig [example.com] AXFR @[ns1.example.com]

Query with DNSSEC validation

kdig +dnssec [example.com]

Reverse DNS lookup

kdig -x [192.0.2.1]

说明

kdig is an advanced DNS lookup utility from the Knot DNS project. It supports modern DNS protocols including DNS over TLS (DoT) and DNS over HTTPS (DoH). Provides more features than traditional dig for DNS troubleshooting and testing.

参数

@_server_
Nameserver to query.
-t _type_
Query type (A, AAAA, MX, NS, etc.).
-x _address_
Reverse lookup for IP address.
+tcp
Use TCP instead of UDP.
+tls
Use TLS (DNS over TLS).
+https
Use HTTPS (DNS over HTTPS).
+dnssec
Request DNSSEC records.
+short
Display short output.

FAQ

What is the kdig command used for?

kdig is an advanced DNS lookup utility from the Knot DNS project. It supports modern DNS protocols including DNS over TLS (DoT) and DNS over HTTPS (DoH). Provides more features than traditional dig for DNS troubleshooting and testing.

How do I run a basic kdig example?

Run `kdig [example.com] A` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does @_server_ do in kdig?

Nameserver to query.