Friday, February 24, 2006

Finding the MAC Address of Remote Computer (Advanced)

Every device on a TCP/IP network has a unique number assigned to it called the MAC (Media Access Control) address. The MAC address is used by the network hardware such as routers, switches, etc. to send traffic from one device to another device on your network.

Your computer uses a service called ARP (Address Resolution Protocol) to resolve and track the TCP/IP and MAC address of the remote devices that you're communicating with. This information is handy for doing semi-low level network troubleshooting. It can also be used for granting or denying permissions to a network segment or device on that network.

To determine the MAC address of a remote device:
  • Open the MS-DOS prompt (From the Run... command, type "CMD" and press Enter).
  • Ping a remote device that you want to find the MAC address (for example: PING 192.168.0.1).
  • Type "ARP -A", and press Enter.

Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\WINDOWS>arp -a


Interface: 192.168.1.100 --- 0x10004
Internet Address Physical Address Type

192.168.1.1 aa-fb-c8-34-da-7a dynamic

21 comments:

Unknown said...

Thanks. this is helpful for me and no need to check on client side.

Anonymous said...

but only works on single subnet network. once the ping hits a gateway you can't tell the remote ip/MAC.

Anonymous said...

GetMAC does the same thing in an enterprise environment - it's part of Windows XP - getmac /s w.x.y.z - make sure you have admin permissions on the remote system.

Dan said...

Sylvio - if you are reading this, i'm very proud of you! It means that even after writing it on your whiteboard and asking me multiple times over the years, you finally figured out how to use google to answer your questions... Congratulations!

(to make this comment useful, if you need to get MAC's from other subnets, check the DHCP server table)

Unknown said...

How about "getmac /s pcname' in the CMD prompt....

James said...

Thanks guys or gals. This saved me an hour trip to get a remote MAC!

Anonymous said...

You guys are awsome. 'getmac' works perfectly with IP or Computer Name. Saved me alot of time.

Anonymous said...

hi to all....
ping to remote computer ip
arp -a
it displays remote ip address and mac address of ur neighbour router address.

Anonymous said...

Thanks bro.
Gud Work. Keep it up.
:)

Anonymous said...

use: "getmac /S ip adress" to get a remote MAC address outside your subnet: like getmac /S 192.168.1.1

Anonymous said...

Thanks!!

Ramani said...

use: "getmac /S ip adress" to get a remote MAC address outside your subnet: like getmac /S 210.xxx.xxx.xxx


system waits for a long time and tells

ERROR: The RPC server is unavailable.

sooji said...

This Gives only to Find out our own MAC address.In order to Get Remote system's MAC address , you must run a Data Sniffer.

Anonymous said...

ERROR RPC server is unavailable, means remote asset is powered off.

GGG said...

Anonymous said...
ERROR RPC server is unavailable, means remote asset is powered off.


-------------

Remote Procedure Call services could be turned off as well. Or the asset type is maybe a different OS other than Windows.

Anonymous said...

you may also ssh into your router and look at its arp table, in the case of cisco this would be show arp.

Anonymous said...

thanks

Ihabov said...

Hi All

Try nbtstat -a in the command prompt, it give you the mac address of the remote computer better than Getmac command.

Anonymous said...

nbstat -a worked for getting the MAC address for a device on a different subnet. thanks!

Anonymous said...

nbstat -a was successful in retrieving the mac address of a Brother printer from a school district building in the next town. Both on the education network but 1/2 hour apart.

Anonymous said...

In my experience: "nbtstat -a IPADDRESS" can be used on machines for which you are not local administrator, whereas "getmac /S IPADDRESS" seems to require local admin on the remote machine (at least here on our network).