LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (October 2001, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Tue, 16 Oct 2001 20:51:56 -0000
Reply-To:     David Wall <darkon@ONE.NET>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         David Wall <darkon@ONE.NET>
Organization: Posted via Supernews,
Subject:      Re: Resolving an IP-address

Brad.Goldman@AUTOTRADER.COM wrote on 16 Oct 2001: >> >> Does anyone know how I can resolve an IP-address from SAS? >> That is, make >> look like > > Simon, > > There is no easy way. I've been working on and off for months on a > project to do just this. And I know of at least two other lurkers who > want to steal -- I mean, get inspired by! -- my code if I ever finish. > > Here is the basic algorithm. > *get a dataset of the tcpips to lookup > *Loop through this dataset, dymanically build a shell script (I'm in > unix) that has a bunch of whois commands. > *x "shellscript" > *when results are in, parse the results text file that the shellscript > created.

That sounds awfully complicated. Since all you want to do is turn IPs into DNS, write one simple (non-SAS) program that reads an input (text) file with IP addresses, one per line, resolves the DNS name, and creates an output file with the IP address and DNS name on the same line. Then have SAS get the IPs, write them to a text file, use x to execute the little non-SAS program, then have SAS read in the IP and DNS from the output file. I'd write the non-SAS part in Perl, since it has tools that make this kind of thing easy, but you could use C or whatever.

-- David Wall

Back to: Top of message | Previous page | Main SAS-L page