Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I add SOA and nameservr to my zone file. When I ran DNS lookup I found unknown A record (31.170.162.67) and MX information. See here: http://network-tools.com/default.asp?prog=dnsrec&host=jumaat.cheapantivirus.me

Is there anyway I could get the same information from command tool. Since I'm just adding nameserver and need A record to be added to my DNS zone I was hoping I could made the automated process of getting A and MX record from webhost and pasted it to my DNS zone.

See my zone file:

root@server1:/etc/bind# cat pri.jumaat.cheapantivirus.me
$TTL        7200
@       IN      SOA     ns01.000webhost.com. hadi.blablajkjhjkh.com. (
                        2012020402       ; serial, todays date + todays serial #
                        28800              ; refresh, seconds
                        7200              ; retry, seconds
                        604800              ; expire, seconds
                        7200 )            ; minimum, seconds
;

jumaat.cheapantivirus.me. 7200      NS        ns01.000webhost.com.
jumaat.cheapantivirus.me. 7200      NS        ns02.000webhost.com.

Right now my website can't propagate because no A record is added.

share|improve this question
    
The question is unclear. Are you looking for some automated way to populate your zone file? –  Massimo Feb 4 '12 at 15:53
    
@Massimo yes. By using IP from webhost nameserver. –  sg552 Feb 4 '12 at 17:25
add comment

2 Answers

up vote 1 down vote accepted

I see, with small delay between request, two different A-data for NSes of domain jumaat.cheapantivirus.me

Do you know it?

BTW, 000 is terrible unreliable in any job. JFYI, two different responses from two different ns01.000webhost.com

Quering 63.223.113.202 for {jumaat.cheapantivirus.me.,ANY}
; Answer ID: 18467  QR: true  OPCODE: QUERY  AA: true  TC: false  RD: true
; RA: false  RCODE: NOERROR  qc 1  an 3  au 0  ad 0

; Question section:
;jumaat.cheapantivirus.me. IN ANY

; Answer section:
jumaat.cheapantivirus.me. 2h IN SOA ns01.000webhost.com. hadi.blabl.com. 2012020403 28800 7200 604800 7200 
jumaat.cheapantivirus.me. 2h IN NS ns01.000webhost.com. 
jumaat.cheapantivirus.me. 2h IN NS ns02.000webhost.com. 

; Authority section:
;(none)

; Additional section:
;(none)

; Query took: 250 msec
; Server queried: 63.223.113.202[udp]

Some minutes later

Quering 208.43.152.32 for {jumaat.cheapantivirus.me.,ANY}
; Answer ID: 18467  QR: true  OPCODE: QUERY  AA: true  TC: false  RD: true
; RA: false  RCODE: NOERROR  qc 1  an 5  au 0  ad 2

; Question section:
;jumaat.cheapantivirus.me. IN ANY

; Answer section:
jumaat.cheapantivirus.me. 2d IN SOA ns01.000webhost.com. freehosting.000webhost.com. 2012012701 172800 7200 3600000 172800 
jumaat.cheapantivirus.me. 2d IN A 31.170.162.67 
jumaat.cheapantivirus.me. 2d IN MX 0 aspmx.l.google.com. 
jumaat.cheapantivirus.me. 2d IN NS ns01.000webhost.com. 
jumaat.cheapantivirus.me. 2d IN NS ns02.000webhost.com. 

; Authority section:
;(none)

; Additional section:
ns01.000webhost.com. 2d IN A 208.43.152.32 
ns02.000webhost.com. 2d IN A 64.120.10.10 

; Query took: 219 msec
; Server queried: 208.43.152.32[udp]

For both requests I started with query to 8.8.8.8 (Google public NS)

And second answer seems as full and correct, but it's serial is older, you know?!

share|improve this answer
    
thank you for your reply. Please tell me what command you use. dig jumaaat.cheapantivirus.me ANY is only repying my main domain IP. I don't understand this: "For both requests I started with query to 8.8.8.8 (Google public NS)". I hope you can explain it in detail. Thank you. –  sg552 Feb 5 '12 at 4:11
    
sg552 - I used dnsquery from Posadis-DNS and requested initial data (list of NSes for your domain) from public google-dns. A typical invocation of dig looks like: dig @server name type. And better to ask authoritative servers for your domain ns01 + ns02 –  Lazy Badger Feb 5 '12 at 5:10
    
I understand what you are saying now. dig jumaaat.cheapantivirus.me ANY didn't work on my first try. After query dig @ns02.000webhost.com jumaat.cheapantivirus.me ANY I get the result I wanted and a moment later dig jumaaat.cheapantivirus.me ANY gave me result. Don't know what happen but thank you. –  sg552 Feb 5 '12 at 18:48
    
@sg552 - when you dig without server defined in request, you asked your default nameserver for recursive query (which failed), second direct request from authoritative for zone server will show result, third request was served from default-server cache. Most important for you is first FAIL, because other requesters also can meet such problem. Dig cheapantivirus.me domain, glue records in it for your subdomain, A for subdomain at the end –  Lazy Badger Feb 5 '12 at 23:06
    
I'm sorry I don't understand this: ...glue records in it for your subdomain, A for subdomain at the end... What are you trying to say? –  sg552 Feb 6 '12 at 11:17
add comment

you can use the "dig" (unix/linux) tool and specify what records you want returned if you like.

dig cheapantivirus.me A

dig cheapantivirus.me MX
share|improve this answer
    
both command will only gave me result of my main domain (cheapantivirus.me). It will not work with my subdomain (jumaat.cheapantivirus.me) –  sg552 Feb 4 '12 at 17:30
    
hm, I think it should if your subdomain is set up in DNS "dig jumaaat.cheapantivirus.me A" gives me "jumaaat.cheapantivirus.me. 86400 IN A 63.223.113.202" as an answer. –  Devin Ceartas Feb 4 '12 at 17:36
    
63.223.113.202 is my main domain IP. If you see here: network-tools.com/… you can see that my subdomain A record jumaat.cheapantivirus.me is pointing to 31.170.162.67. How could I use any command to see that? Thank you. –  sg552 Feb 4 '12 at 17:53
    
@sg552 - dig jumaaat.cheapantivirus.me ANY –  Lazy Badger Feb 4 '12 at 19:15
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.