[Tfug] LAN hostnames

Tony tfug@tfug.org
Tue Sep 17 04:27:02 2002


This might not be exactly what you were looking for, but you could run 
something like the following then extract the pertinent information with 
a little C++ app which would append the IP and hostname to your 
/etc/hosts file.

~
Wazzup? nmap -sP 10.0.0.* -oM outputfile.txt

Starting nmap V. 2.53 by fyodor@insecure.org ( www.insecure.org/nmap/ )
Host foo.skullbocks.lin (10.0.0.1) appears to be up.
Host  (10.0.0.2) appears to be up.
Nmap run completed -- 256 IP addresses (2 hosts up) scanned in 5 seconds

~
Wazzup? less outputfile.txt
# Nmap (V. nmap) scan initiated 2.53 as: nmap -sP -oM outputfile.txt 
10.0.0.*
Host: 10.0.0.1 (foo.skullbocks.lin)     Status: Up
Host: 10.0.0.2 ()       Status: Up
# Nmap run completed at Tue Sep 17 04:20:47 2002 -- 256 IP addresses (2 
hosts up
) scanned in 5 seconds

There's probably a better way, but mine is interesting enough that I'd 
do it myself if I had the time and a similar problem.


Paul Scott wrote:
> Paul Scott wrote:
> 
>> Since moving from fixed local IP's to getting them from my Actiontec 
>> DSL gateway I have lost the ability to look up the local host names 
>> that used to come from the fixed entries in '/etc/hosts'.
>>
>> BIND is installed.  named is running.  I have read the man pages that 
>> I have found and the DNS HOWTO.
> 
> 
> I see that I haven't read the DNS HOWTO well enough and I will do that 
> and I would still appreciate hints.
> 
> Thanks,
> 
> Paul
>