This is not a EOS question, but a general one - and I’m happy to delete it if not appropriate for this forum.
I am trying to see all devices connected to my LAN
my own laptops IP is 192.168.1.80/24
all the instructions I found on the web say the command should be this: sudo nmap -sn 192.168.1.0/24
nmap discovers some devices but not others. ( I have access to the router so I can see the other devices via the router)
I’d love to know why?
Thank you
It is strange that you allow someone else to connected to your home network.
You can man nmap to see all sort of different options that you can use. -sn is only ping scan - some devices do not respond to ping (firewall block it or low cost hardware do not support it).
Also are you sure all your devices are connected to the same IPv4 subnet you are probing? Is your router/switch isolating devices from each other? Try a simple ping from your terminal to see if the device on the oter side respond to it.
When you have a big family you have many devices connected…
The admin panel of the home router - where all devices are seen - shows that they all have the same structure 192.168.1.xx - so I take it to mean they are all on the same subnet mask.
You can see here that nmap -sn 192.168.1.0/24 returns
$ sudo nmap -sP 192.168.1.0/24
Starting Nmap 7.92 ( https://nmap.org ) at 2022-04-19 09:51 BST
Nmap scan report for 192.168.1.254
Host is up (0.00097s latency).
MAC Address: 30:B1:B5:B8:42:5C (Arcadyan)
Nmap scan report for 192.168.1.80
Host is up.
Nmap done: 256 IP addresses (2 hosts up) scanned in 8.52 seconds
does not return 192.168.1.164 - which is my iphone.
but ping -c 3 192.168.1.164 returns:
--- 192.168.1.164 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2003ms
rtt min/avg/max/mdev = 19.255/65.009/98.098/33.410 ms
Oh, I was thinking more like a neighbour or that nice guy in the black van in front of the house, etc…
You can also check the network trafic with wireshark. When you use nmap -sn 192.168.1.0/24 (or more precisely your subnet) then you will see your computer will send out ARP broadcast asking on each ip address to whom it belongs. Next you should see an ARP response from valid targer informing your computer that it has that ip and what it its MAC address.
If you do not see those arp packets then there is something blocking the trafic - most likely the router or firewall.