Switches, Hubs, and Modems
1752785 Members
5619 Online
108789 Solutions
New Discussion юеВ

Re: Find a specific IP Address

 
Alen Ahja
Frequent Advisor

Find a specific IP Address

Hi!

How can a find which IP-Address is link on which port? Is this possible?

Thanx for help

Alen Ahja
9 REPLIES 9
Les Ligetfalvy
Esteemed Contributor

Re: Find a specific IP Address

You need to first resolve the IP to the MAC address. Then you need to query the ports in sequence for the MAC, tracing back the route as you go.

Or you could use 3rd party software to do it for you.
Alen Ahja
Frequent Advisor

Re: Find a specific IP Address

Ok - to resolve the IP to the MAC address is logic. But how can i query the ports in swquence to the MAC.

Which 3rd party software can do this for me?
Ron Kinner
Honored Contributor

Re: Find a specific IP Address

Which switch(es) do you want to do this on?

Usually SNMP can get the forwarding table for you and if you ping an IP address on the same switch and immediately check your arp table (arp -a) you will see the IP address and the MAC address so I suppose you could write a perl program that would do this. It's also possible that Toptools (or whatever their management app is called these days) already has this feature in it if you are talking HP procurve switches.

Ron
Alen Ahja
Frequent Advisor

Re: Find a specific IP Address

We have 4108GL, 2650, 2824 amd 2024 Procuve Switches. We managed them with the PCM+
Les Ligetfalvy
Esteemed Contributor

Re: Find a specific IP Address

I am sure it could be done programatically. To do it from a telnet console session, go into the menu:

1. Status and Counters

7. Port Address Table

Follow your nose.
Rajinikanth_1
Advisor

Re: Find a specific IP Address

In Telnet sessions use this command

show ip arp

this must give a list of ip address with Mac address and the port no.s in brackets
Alen Ahja
Frequent Advisor

Re: Find a specific IP Address

Hi,

i can only type "sh arp" and the list shows only the stacking devices.
If i type "sh arp vlan vlan-id" the list shows no entry.

Alen
Kell van Daal
Respected Contributor

Re: Find a specific IP Address

If you have an ip address, and you want to find out what port it is on, you can do that easily.

From the switch, ping the needed ip address.
Then do a "show arp" on the switch.
It will say what port it is on.
Ron Kinner
Honored Contributor

Re: Find a specific IP Address

Don't think sh arp is what you want on the switches. That just shows the IP-MAC table for stuff that is either on the switch or that the switch has just talked to.

Try sh mac

Syntax: show mac-address [ | mac-addr |
Lists the MAC addresses of the devices the switch has detected, along with the number of the specific port on which each MAC address was detected.
[ port-list ]
Lists the MAC addresses of the devices the switch has detected, on the specified port(s).
[ mac-addr ]
Lists the port on which the switch detects the specified MAC address. Returns the following message if the specified MAC address is not detected on any port in the switch:
MAC address < mac-addr > not found.
[ vlan < vid > ]
Lists the MAC addresses of the devices the switch has detected on ports belonging to the specified VLAN, along with the number of the specific port on which each MAC address was detected.

Of course that only tells you the MAC address and not the IP. If you have a router you can ask it sh arp and get the table or you can ping a device and get the mac from
arp -a

or you can use a program like ArpWatch

Ron