Mailinglist Archive: opensuse (882 mails)

< Previous Next >
Re: [opensuse] How to find list of hosts on local subnet? [Part Solved]
  • From: "David C. Rankin" <drankinatty@xxxxxxxxxxxxxxxxxx>
  • Date: Thu, 02 Dec 2010 18:51:23 -0600
  • Message-id: <4CF83F0B.30800@xxxxxxxxxxxxxxxxxx>
On 12/02/2010 06:43 PM, David C. Rankin wrote:
On 12/02/2010 06:15 PM, John Andersen wrote:
I use my Nexus One. Use to use my iPhone. Lots of apps for that.

When no tools at hand:
ping -c 2 -b <broadcast IP> (something like - You need
-b option)
-c 2 sends just two pings. No need to get crazy.

then immediatly do

/sbin/arp -n


I've noticed that using arpd seems to give you the best results for hosts that
might not be up at the moment. Just start arpd with:

# arpd -b /var/lib/arpwatch/arpd.db ath0

Here is the differences in the results. With arp I get only 4 hosts and the
router (.13)

18:45 alchemy:~/scr/utl/tst> ping -c2 -b

18:45 alchemy:~/scr/utl/tst> sudo arp -n
Address HWtype HWaddress Flags Mask Iface ether 00:0F:1F:D6:03:A0 C ath0 ether 00:23:69:5C:FD:B4 C ath0 ether 00:E0:81:55:4E:1D C ath0 ether 00:11:43:22:5A:25 C ath0 ether 00:21:85:1A:8C:FA C ath0

Using the script above, I get the whole list:

18:46 alchemy:~/scr/utl/tst> sh

Hostname IP Mac
archangel 00:21:85:1a:8c:fa
zachrys-iPhone d4:9a:20:92:0b:f5
gateway (Linksys) 00:06:25:5e:dd:29
supersff 00:0f:1f:d6:03:a0
gw 00:23:69:5c:fd:b4
mail 00:e0:81:55:4e:1d
dcrgx2 00:11:43:22:5a:25
dcrgx 00:11:43:22:4f:23
zion 00:0c:76:13:16:e6
Wii 00:1b:ea:d6:91:80
ripper 00:0c:76:13:90:c2

David C. Rankin, J.D.,P.E.
Rankin Law Firm, PLLC
510 Ochiltree Street
Nacogdoches, Texas 75961
Telephone: (936) 715-9333
Facsimile: (936) 715-9339
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx

< Previous Next >
Follow Ups