resolve ip address into a host name

eon

2[H]4U
Joined
Oct 11, 2003
Messages
2,218
Hello, I'm looking for a way to automate resolving ip external addresses into their host name, something like:
xxx.xx.xxx.xx => google.com

The ip addresses are stored in a sql server 2008 database. I guess I can make some script that can call nslookup or something on the address and update the database. And I just was reading that there are some .net functions that can do this too. So im just checking here for the path of least resistance, maybe like a way to call an ip resolution function from a t-sql procedure.
Thanks
 

ameoba

Supreme [H]ardness
Joined
Jan 9, 2001
Messages
6,413
Keep in mind that there's not a 1:1 mapping of IP and DNS entries.
 

eon

2[H]4U
Joined
Oct 11, 2003
Messages
2,218
looks like .net will work...

string domain = Dns.GetHostByAddress("208.49.52.135").HostName;

are there some public nameservers I can use to try to resolve an address? Using our own leaves a couple unresolved but if I go to website like whois I can find the domain.
 
Top