KHOST(1)
β¨ NAME β¨
okay bestie, meet khost β the simple DNS lookup utility from Knot DNS (manual name KHOST(1), and yes we're getting into it π
). It's the cute little lookup tool that keeps things readable, fr fr.
π¦ SYNOPSIS π¦
khost [options] name [server]
π DESCRIPTION π
So khost sends a DNS query for name to server and prints the reply in a more user-readable form. It's giving simple and readable energy. For more advanced DNS queries use kdig instead. No cap.
Parameters π
nameβ a domain name that is to be looked up. Ifnameis an IPv4 or IPv6 address, thePTRquery type is used. Reverse vibes β¨serverβ a name or an address of the nameserver to send a query to. The address can be specified using[address]:portnotation. If noserveris specified, the servers from/etc/resolv.confare used. Periodt.
If no arguments are provided, khost prints a short help. Cute of it π«Ά
Options π
-4β Use the IPv4 protocol only.-6β Use the IPv6 protocol only.-aβ Send ANY query with verbose mode.-dβ Enable debug messages.-h,--helpβ Print the program help.-rβ Disable recursion.-Tβ Use the TCP protocol.-vβ Enable verbose output.-V,--versionβ Print the program version. The option-VVmakes the program print the compile time configuration summary.-wβ Wait forever for the reply.-cclass β Set the query class (e.g.CH,CLASS4). The default class isIN.-ttype β Set the query type (e.g.NS,IXFR=12345,TYPE65535). The default is to send 3 queries (A,AAAAandMX).-Rretries β The number (>=0) of UDP retries to query a nameserver. The default is1.-Wwait β The time to wait for a reply in seconds. This timeout applies to each query try. The default is2seconds.
β EXIT VALUES β
Exit status of 0 means successful operation. Any other exit status indicates an error. So if it's not 0, something's up bestie π.
π EXAMPLES π
- Get the
A,AAAAandMXrecords forexample.com:
$ khost example.com
- Get the reverse record for address
192.0.2.1:
$ khost 192.0.2.1
- Perform a verbose zone transfer for zone
example.com:
$ khost -t AXFR -v example.com
π FILES π
/etc/resolv.conf
π₯ SEE ALSO π₯
π AUTHOR π
the icons behind this: CZ.NIC, z.s.p.o. and contributors <https://www.knot-dns.cz/>
π COPYRIGHT π
Copyright (C) CZ.NIC, z.s.p.o. and contributors
okay that's the whole KHOST(1) page, bestie β version 3.6.2, dated 2026-10-21, from the Knot DNS manual. mwah ππ
π¦ where this page comes from
- nixpkgs unstable: knot-dns 3.6.2
- opensuse-leap 16.0: knot-utils 3.6.2-bp160.1.1 Β· GPL-2.0-or-later
- opensuse-leap 16.0: knot-utils 3.6.2-bp160.1.1 Β· GPL-2.0-or-later
- opensuse-leap 16.0: knot-utils 3.6.2-bp160.1.1 Β· GPL-2.0-or-later
- opensuse-leap 16.0: knot-utils 3.6.2-bp160.1.1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms