Finding switch port from IP address
Sometimes it is necessary to be able to find the port a PC is connected to in case you need to VLAN that particular port or troubleshoot other issues. Below are some quick instructions for how to find the port a device is plugged into based on IP address and or MAC address.
1. Record the IP address or MAC address of the computer or device you are trying to locate
2. Locate the network switch your device is connected to
3. Telnet to the Cisco switch the device is connected to
4. You will see the following prompt highlighted in RED. Ping the IP address of the device you are working on.
Switch1#ping 192.168.16.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.16.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/4/9 ms
3. Type in the following sho arp command
Switch1#sho arp | inc 192.168.16.2
Internet 192.168.16.2 0 001e.4f2f.1506 ARPA Vlan1
4. Type in the following sho mac address-table command
Switch1#sho mac address-table add 001e.4f2f.1506
Depending on the version of IOS on the switch, this can be:
sho mac-address-table address 001e.4f2f.1506
Mac Address Table
——————————————-
Vlan Mac Address Type Ports
—- ———– ——– —–
1 001e.4f2f.1506 DYNAMIC Fa0/7
Note the port Fa0/7. This device has been found on Port 7 of this network switch.