-1

I would like to find out the physical port number (the connector itself!) of a Router where a series of devices are connected to. Finding their IP and MAC is not issue at all. Let's say, finding out that for example the device with IP or MAC xxx is connected to his router on plug #03.

My topologie is a private LAN: a computer (where the java program runs and with windows 7) connected to a single router from which up to 10 devices will be connected.

I read something about activating the protocol SNMP + and installing a NMS server on the router, and after executing "show mac address-table address xxxx.xxxx.xxxx", but as the routers could be from different manufacturers, if it was possible it would be nice to have a solution which didn't involve configuring or installing anything at the router site. Any ideas or point outs?

Thanks in advance, you all!

1 Answers1

0

Some network network switches and routers commonly send out packets that allow the identification of the switch/router port the device at the other end of the cable is connected to, but this will only let the inquiring device to find its own port, not the port of any other device. For this, there are various vendors' original solutions, like Cisco's CDP protocol, and a more recent IEEE802.1AB Link Layer Discovery Protocol (LLDP).

The mapping of physical ports beyond that requires the cooperation of the router or switch. And unfortunately, there is not yet an universal standard for this. And even if there were, there could be situations in which the network administrator would want to keep the port numbers confidential, so even if a suitable protocol existed, the information is not necessarily freely available without an authentication of some sort.

On larger scales, there are techniques like active probing (similar to traceroute) and analysis of routing protocol information, but these are not very useful within a single network segment.

Fortunately, SNMP is a well-established management protocol, especially in devices like switches and routers. If your router supports SNMP, it is very likely it can provide you a listing of its MAC address table, with some sort of port identifier associated with each MAC address.

Depending on the make and model of the router, installing anything on it might not be possible. I think a mapping service would be appropriate for enterprise-type situations where you have multiple switches feeding a router: in such cases, a mapping service on the router would have to access the (mapping-compatible) switches to provide a comprehensive mapping: "MAC address X is located at edge switch A port B, which is connected via core switch C port D to router port E."

But for a single router and up to 10 directly-connected devices, you would just need basic read-only SNMP access to the router's MAC address table - and that is actually the only way I know of solving your problem without going there and looking at the cables physically.

telcoM
  • 4,153
  • 12
  • 23