Passion/Network

dig ANSWER section

sunshout 2018. 11. 30. 00:29

$ dig www.google.com


; <<>> DiG 9.9.4-RedHat-9.9.4-51.el7_4.2 <<>> www.google.com

;; global options: +cmd

;; Got answer:

;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 54506

;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1


;; OPT PSEUDOSECTION:

; EDNS: version: 0, flags:; udp: 4096

;; QUESTION SECTION:

;www.google.com.                        IN      A


;; ANSWER SECTION:

www.google.com.         60      IN      A       172.217.25.196


;; Query time: 1 msec

;; SERVER: 10.0.0.2#53(10.0.0.2)

;; WHEN: Thu Nov 29 15:28:34 UTC 2018

;; MSG SIZE  rcvd: 59



The first field is the NAME: The domain name being returned

The second field (108 in your example) is the TTL in seconds.

IN is the CLASS. Here, IN stands for Internet.

A is the TYPE. Here, A stands for mapping a domain name to an IPv4 address.

The last field is of course the IP Address.