Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #186283

Re: Can't find ip addresses of devices on LAN

From Steve Witt <sawitt@ieee.org>
Newsgroups linux.debian.user
Subject Re: Can't find ip addresses of devices on LAN
Date 2017-09-01 19:10 +0200
Message-ID <ukXCa-81A-23@gated-at.bofh.it> (permalink)
References <ukWZs-7vc-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, Sep 01, 2017 at 12:28:05PM -0400, Thomas George wrote:
> I have tried ping 192.168.1.225 followed by arp -a
> 
> and I have tried netstat -r
> 
> Neither report ip addresses of attached devices.
> 
> I know there are two devices besides this pc and I know the address of one
> of these devices. I can ping it and it responds.
> 
> How to find the address of the second device other than ping each address
> from 192.168.1.2 to 192.168.1.255?
> 

What sort of network are you on? Are the IP addresses of the devices
assigned via DHCP from a router? Can you query the router to find the
DHCP leases that it has assigned (through a web interface perhaps)?
Otherwise, pinging every address in the subnet is one of the only
surefire ways to do this, depending upon what you want to
accomplish. My rule of thumb is, that if I need to perform some task
more than a couple of times, then write a script/program to do it. I'd
much rather code something up than issue 254 ping commands.

In a little more of a big picture view, if you need to communicate
between devices on your network and you want to have IP addresses
dynamically assigned through DHCP, then your DHCP server (probably a
router) should accept hostname from the device and then incorporate
that into a local DNS service so you can communicate to other devices
via their hostnames and the underlying IP address is somewhat
irrelevant. Or assign fixed IP addresses (which can be a
pain). 'dnsmasq' is a package that does this kind of thing. But it
depends upon your use case and the details of your network (mostly who
controls it).

Back to linux.debian.user | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

Can't find ip addresses of devices on LAN Thomas George <lists@tomgeorge.info> - 2017-09-01 18:30 +0200
  Re: Can't find ip addresses of devices on LAN Markus Schönhaber <debian-user@list-post.mks-mail.de> - 2017-09-01 19:00 +0200
  Re: Can't find ip addresses of devices on LAN Steve Witt <sawitt@ieee.org> - 2017-09-01 19:10 +0200

csiph-web