HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Installation/Configuration (http://www.howtoforge.com/forums/forumdisplay.php?f=27)
-   -   Dig command (http://www.howtoforge.com/forums/showthread.php?t=61134)

madmac007 25th March 2013 19:45

Dig command
 
After setting up 2 Debian DNS servers as per:
http://www.howtoforge.com/how-to-run...debian-squeeze

Added numerours entries, everything is cloned to 2nd server no probs.

However, when testing using " dig " Using this server name " ns1.test1.com and dns entry for mydomain1.com
Eg:
dig @ns1.test1.com any mydomain1.com

; <<>> DiG 9.7.3 <<>> @ns1.test1.comt any mydomain1.com
; (1 server found)
;; global options: +cmd
;; connection timed out; no servers could be reached


So I ran the same command using 127.0.0.1, and it works?

dig @127.0.0.1 any mydomain1.com

; <<>> DiG 9.7.3 <<>> @127.0.0.1 any mydomain1.com
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 158
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 7, AUTHORITY: 0, ADDITIONAL: 2

;; QUESTION SECTION:
;mydomain1.com. IN ANY

;; ANSWER SECTION:
mydomain1.com. 38400 IN SOA ns1.test1.com. admin@test1.com. 2013012503 10800 3600 604800 38400
mydomain1.com. 38400 IN A 192.168.11.3
mydomain1.com. 38400 IN MX 10 mx1..test1.com.
mydomain1.com. 38400 IN MX 20 mx2..test1.com.
mydomain1.com. 0 IN NS ns1.test1.com.
mydomain1.com. 0 IN NS ns2.test1.com.
mydomain1.com. 38400 IN TXT "v=spf1 include:.test1.com ~all"

;; ADDITIONAL SECTION:
ns1.test1.com. 7200 IN A 192.168.11.1
ns2.test1.com. 7200 IN A 192.168.11.2

;; Query time: 0 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Mon Mar 25 11:34:01 2013
;; MSG SIZE rcvd: 291


How do I fix this Please
Note names and IP`s changed to protect the inocent : )

madmac007 25th March 2013 20:51

Dig-Resolved
 
sorry I do feel stupid
Simple rookie mistake.
error in
/etc/hosts

it had
127.0.0. 1 ns1.test1.com ns1

Changed it to
192.168.11.1 ns1.test1.com ns1

Hope this prevents anyone making the same rookie mistake I did,
sorry it was a long day.


All times are GMT +2. The time now is 09:42.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.