Network Discovery Question

Hi, I have been searching for a few hours to this question, no joy. This is an attempt at better understanding under-the-hood networking at a lower level.

My ISP gave me a new router, and they gave me the wrong local IP to access it. I know I can check the box for an IP, call the ISP, or set DHCP and then check `ifconfig` ...

However, I wanted to go the academic route and use something like `arp -a` or some kind of layer 2 broadcast function (??) to receive the mac/IP of any devices to which I have a physical ethernet cable connection. Obviously I can't ping since I technically don't know which IP to ping. `arp -a` returned a totally empty table. I figured there would be some terminal command out there to just "ping" (so to speak) at the datalink layer for network discovery and configuration. I found `arping` but that doesn't seem to exist on my FreeBSD 12.1 install. Ideas?
 
Try tcpdump, to see what packets are physically on the wire. The only problem is, you need to ifconfig your port before you do that, and if you're relying on DHCP, your port will be down. So you can hand-configure your port to be on the whole address namespace.
 
Disconnect all devices, turn off router, run net/wireshark, turn on router, you should get something on wireshark.
`arp -a` returned a totally empty table.
a option in arp(8) display current ARP entries (address-mapping table)
[EDIT] Regarding arp -a command: there should be some cache somewhere. that's why (I think) you get empty result.
 
I wanted to go the academic route
About academic route (first, I thought you're talking about router):
If you can find a copy of Computer Networks written by Andrew S. Tanenbaum, take it and read it. It doesn't matter which edition. Even old editions are fine. There's just one problem with books written by Tanenbaum. The gentleman is very long-winded. pretty much like Bjarne Stroustrup. If you have no problem with that, everything should be fine.
 
Back
Top