Linux "ping -a " analogue

Rigler, Steve srigler at marathonoil.com
Fri Sep 24 18:32:08 UTC 2004


Assuming your PC's are using WINS, you could try nmblookup:

nmblookup -A <ipaddr>

-Steve 

-----Original Message-----
From: redhat-list-bounces at redhat.com
[mailto:redhat-list-bounces at redhat.com] On Behalf Of Milen Dimitrov
Sent: Friday, September 24, 2004 1:06 PM
To: redhat-list at redhat.com
Subject: Re: Linux "ping -a " analogue

All machines in the LAN use DHCP.
Do I still need to put the IP/names in /etc/hosts?

Are there any other options?


Ryan Golhar wrote:

>The only way to do that is to put the names and ip addresses of the
>machines in your lan in your /etc/hosts file.  There is no other way to
>do it.
>
>-----
>Ryan Golhar
>Computational Biologist
>The Informatics Institute at
>The University of Medicine & Dentistry of NJ
>
>Phone: 973-972-5034
>Fax: 973-972-7412
>Email: golharam at umdnj.edu
>
>-----Original Message-----
>From: Milen Dimitrov [mailto:milend at ansco.com] 
>Sent: Friday, September 24, 2004 12:49 PM
>To: golharam at umdnj.edu
>Subject: Re: Linux "ping -a " analogue
>
>
>I tried "nslookup 192.168.0.1" but it didn't work.
>It works fine for public IP addresse but it doesn't work for the
private
>
>ones. (192.168.0.1)
>
>Is there any other command/tool I can use to resolve IP addresses into 
>names for PCs in my LAN????
>
>Ryan Golhar wrote:
>
>  
>
>>I think the Windows version uses NETBIOS to resolve names that don't 
>>have a DNS entry.
>>
>>Use nslookup.  That will return the name as registered with a DNS 
>>server.  It won't use NETBIOS so private IP address probably won't be 
>>resolved unless its in your /etc/hosts files.
>>
>>Ryan
>>
>>-----Original Message-----
>>From: redhat-list-bounces at redhat.com 
>>[mailto:redhat-list-bounces at redhat.com] On Behalf Of Milen Dimitrov
>>Sent: Friday, September 24, 2004 11:56 AM
>>To: General Red Hat Linux discussion list
>>Subject: Linux "ping -a " analogue
>>
>>
>>Hi gurus,
>>
>>Windows' command "ping -a 192.168.0.1" will resolve the IP address
>>192.168.0.1 into to a name if possible.
>>What is the linux analogue of this command?
>>Linux ping command doesn't seem to be able to do that...
>>Any ideas?
>>============================
>>C:\>ping -a 192.168.0.1
>>
>>Pinging MYNEWPC [192.168.0.1] with 32 bytes of data:
>>
>>Reply from 192.168.0.1: bytes=32 time<10ms TTL=64
>>Reply from 192.168.0.1: bytes=32 time<10ms TTL=64
>>Reply from 192.168.0.1: bytes=32 time<10ms TTL=64
>>Reply from 192.168.0.1: bytes=32 time<10ms TTL=64
>>
>>Ping statistics for 192.168.0.1:
>>   Packets: Sent = 4, Received = 4, Lost = 0 (0% loss), Approximate 
>>round trip times in milli-seconds:
>>   Minimum = 0ms, Maximum =  0ms, Average =  0ms 
>>=================================
>>
>>
>>
>>
>>
>>
>>
>> 
>>
>>    
>>
>
>
>  
>



-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request at redhat.com?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list







More information about the redhat-list mailing list