Mastodon Skip to main content

Using NetDiscover to find Network Devices

As I've been re-working my home network, moving from an Eero Mesh install to an open source setup using OPNSense as my firewall and router, and DD-WRT for my Wired / Wireless Access Points, one thing I didn't want ot mess up was my IP addressing that I had setup in Eero.  Now, if you have only 5 or 10 devices, this is really no big issue to fix after switching over, but my network regularly reports 80 to 90 devices due to all of my VMs, containers, IoT devices, and so on.  And, I would imagine many of you have a growing number of devices as well.

There are some terrific tools out there for finding IPs and identifying devices on your network, including the Router / DHCP server itself in many cases.  

In my case, however, Eero does not have a web application for keeping control over your network.  They only offer a mobile app.  They also have no way (at least today) of exporting the network device information.  So I needed another way.

Beyond that, I had an IP camera that I got, and when connectingn it up, I couldn't locate it on my network, and even when I connected directly to my machine via Ethernet, I could not find it.  I was baffled.  Then I read a post by a person who said he found that the device came to him with a statically set IP on a weird subnet.  He did not, however, mention what he used to finally find that IP.  

In my case, I was lucky enough to come across NetDiscover.

This tool is simply incredible, and is so easy to install.  

Installation

Simply use the appropriate repository for your LInux distro, and NetDiscover is likely there... in my case I used apt as my distro is Ubuntu based.

sudo apt install netdiscover -y

within seconds it was installed and ready to use.

If you used RedHat based distros, try RPM, YUM, or DNF.

For Open Suse, you'll want to try Zypper, and so on.

Usage

Once installed, you can start Netdiscover with many different flags.

If you are just trying to identify devices on your network, then use a command like

sudo netdiscover -r <your ip range: example 192.168.1.0/24>

You can add other flags as well, to make your output even better.  You can use the lowercase 'p' to tell netdiscover not to actively ping a host, but instead to simply sniff network traffic an show results as they are found.

sudo netdiscover -p -r <your ip range>

You can get the results in a more Parsable format with

sudo netdiscover -p -P -r <your ip range>

Or, in the case of me looking for a camera on an ukknown IP in an unknown subnet, you can try this command.

sudo netdiscover -S -f -i <your interface name>

Where <your interface name> will be something like etho0, or eno1, or enp2s0, etc.  You can see your various interface names with the command:

ip a show

Now, you've got the tools to find all your devices, and see what's on your network in a simple, powerful, and fast tool.

Support my Content and Channel

Support my Channel and ongoing efforts through Patreon:
https://www.patreon.com/bePatron?u=234177