"Ivan J. Varzinczak" wrote: > I'd like to know if someone can give me any sugestions about > how I can discover the domain name given an IP address. For example, > if I have the IP address 205.188.146.23, I would like to discover what > the domain name is, in that case, aol.com. > I've tried to use nslookup, but I've had some problems in > setting the servers, because perhaps I'll need the "root" servers on > internet and it doesn't work very well. > Thanks in advance!
the 'reverse-name lookup' construct swaps the order of the IP numbers and appends '.in-addr.arpa' to the end, so that 123.45.67.89 would be looked up as 89.67.45.123.in-addr.arpa and to keep your server from appending any local 'search' domains (if you're at 'myserver.com' the sought address might be mangled into '89.67.45.123.in-addr.arpa.myserver.com' if you don't) then be sure to put the trailing DOT at the end: 89.67.45.123.in-addr.arpa. like this: % nslookup Default Server: localhost Address: 127.0.0.1 > 23.146.188.205.in-addr.arpa. Server: localhost Address: 127.0.0.1 Name: 23.146.188.205.in-addr.arpa [woo. not very informative, there.] > set q=any [now we'll get ANY records available.] > 23.146.188.205.in-addr.arpa. Server: localhost Address: 127.0.0.1 23.146.188.205.in-addr.arpa name = www2.aol.com 146.188.205.in-addr.arpa nameserver = dns-01.ns.aol.com 146.188.205.in-addr.arpa nameserver = dns-02.ns.aol.com dns-01.ns.aol.com internet address = 152.163.159.232 dns-02.ns.aol.com internet address = 205.188.157.232 > voila! if you get into setting up your own DNS, you'll get quite familiar with this stuff. (see 'man named' and 'man named.conf' for the scoop.) -+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- Their is five errers in this sentance.