We use cookies
We use cookies to optimize our website. By continuing to browse the site, you agree to our use of cookies.
New design
Control panel
  • Русский
  • Українська
  • English
  • UAH
  • USD
  • RUB
  • EUR
  • 0-800-307-307 Hotline
  • +38 (044) 392-74-33 Kiev
  • +38 (057) 728-39-00 Kharkiv
  • +38 (056) 794-38-31 Dnipro
  • +38 (032) 229-58-93 Lviv
  • +38 (048) 738-57-70 Odessa
  • +38(093) 170-15-42  Life
  • +38 (067) 400-88-44 Kievstar
  • +1(888)393-24-51  USA, Toll free
  • +44(131)507-01-14  Great Britain
  • +7 (499) 348-28-61 Moscow

Host utility

host - utility (DNS-client) to work with domain records. Used for polling DNS-servers and receiving records about the requested domain.

  • -t entry - request for information about a specific record.
  • -t ANY or -a - request for information about all records.
  • IPaddress - reverse search DNS - to obtain information about a specific IP, it is enough to indicate its address.
  • server - to obtain information from a specific DNS-server is enough to indicate its name, name or address after the domain.
  • -v or -d - verbose output (options are equivalent).

The simplest query:

host ukraine.com.ua

Answer with explanatory comments:

ukraine.com.ua has address 185.39.224.54                      # Domain A record
ukraine.com.ua has IPv6 address 2a04:8000:0:e022::54          # AAAA domain record
ukraine.com.ua mail is handled by 20 alt1.aspmx.l.google.com. # MX records of the domain
ukraine.com.ua mail is handled by 10 aspmx.l.google.com.

To get information about a specific record, use the key -t and its name (A, AAAA, CNAME, TXT, MX, NS):

host -t a ukraine.com.ua

Answer:

ukraine.com.ua has address 185.39.224.54

To get information about all records, use the key -t and name ANY or just a key -a (equivalent -v -t ANY):

host -a ukraine.com.ua 8.8.8.8

Answer:

Trying "ukraine.com.ua"
Using domain server:
Name: 8.8.8.8
Address: 8.8.8.8#53
Aliases:;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 48991
;; flags: qr rd ra; QUERY: 1, ANSWER: 10, AUTHORITY: 0, ADDITIONAL: 0
 
;; QUESTION SECTION:
;ukraine.com.ua.                        IN      ANY
 
;; ANSWER SECTION:
ukraine.com.ua.         899     IN      SOA     ns1.ukraine.com.ua. hostmaster.adm.tools. 2019102588 43200 7200 604800 60
ukraine.com.ua.         899     IN      AAAA    2a04:8000:0:e022::54
ukraine.com.ua.         899     IN      TXT     "v=spf1 include:_spf.ukraine.com.ua include:_spf.google.com -all"       
ukraine.com.ua.         899     IN      TXT     "google-site-verification=IafnKVUlyUkkXGv3cgYvmdJch6oYHIm_vZwt8nwfnGc"  
ukraine.com.ua.         899     IN      A       185.39.224.54
ukraine.com.ua.         899     IN      NS      ns1.ukraine.com.ua.
ukraine.com.ua.         899     IN      NS      ns2.ukraine.com.ua.
ukraine.com.ua.         899     IN      NS      ns3.ukraine.com.ua.
ukraine.com.ua.         899     IN      MX      10 aspmx.l.google.com.
ukraine.com.ua.         899     IN      MX      20 alt1.aspmx.l.google.com.Received 398 bytes from 8.8.8.8#53 in 85 ms

Important points:

  • The command returns information strictly for the specified domain / subdomain. By specifying a domain name, it is impossible to obtain information about its subdomains, and vice versa - when specifying a subdomain, the command will return information only on it, records about the main domain will not be returned.
  • Not all all DNS-servers can return information about all records at once. For example, the CloudFlare server with the address 1.1.1.1 does not return, but the Google server with the address 8.8.8.8 does.

To determine the hostname by IP address (PTR record), simply specify the IP:

host 185.39.224.54

Answer:

54.224.39.185.in-addr.arpa domain name pointer ukraine.com.ua.

To receive a response from a specific DNS-server, specify its name or IP after the domain:

host ukraine.com.ua 8.8.8.8

Answer:

Using domain server:
Name: 8.8.8.8
Address: 8.8.8.8#53
Aliases:
 
ukraine.com.ua has address 185.39.224.54
ukraine.com.ua has IPv6 address 2a04:8000:0:e022::54
ukraine.com.ua mail is handled by 10 aspmx.l.google.com.
ukraine.com.ua mail is handled by 20 alt1.aspmx.l.google.com.

For a detailed answer, use the key -v:

host -v ukraine.com.ua

Answer:

Trying "ukraine.com.ua"
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 15072
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0
 
;; QUESTION SECTION:
;ukraine.com.ua.                        IN      A
 
;; ANSWER SECTION:
ukraine.com.ua.         354     IN      A       185.39.224.54
 
Received 48 bytes from 1.1.1.1#53 in 14 ms
Trying "ukraine.com.ua"
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 21694
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0
 
;; QUESTION SECTION:
;ukraine.com.ua.                        IN      AAAA
 
;; ANSWER SECTION:
ukraine.com.ua.         540     IN      AAAA    2a04:8000:0:e022::54
 
Received 60 bytes from 1.1.1.1#53 in 19 ms
Trying "ukraine.com.ua"
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 25901
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 0
 
;; QUESTION SECTION:
;ukraine.com.ua.                        IN      MX
 
;; ANSWER SECTION:
ukraine.com.ua.         407     IN      MX      20 alt1.aspmx.l.google.com.
ukraine.com.ua.         407     IN      MX      10 aspmx.l.google.com.Received 87 bytes from 1.1.1.1#53 in 16 ms