Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

At work, we have a network with internal IP addresses given to machines. How can I find the MAC address of machines in my network whose IP address is known to me?

Also how do I find the MAC address of my router whose IP address I know?

I work on Ubuntu.

share|improve this question
add comment

2 Answers

up vote 5 down vote accepted

Erm, arping isn't needed. You can just use arp.

arp <ipaddress>

same thing with your gateway. netstat -rn to find your gateway then arp <ipaddress>, use arp -i <device> <ipaddress> if you want to force a specific interface.

you probably also want to use the -c 4 arguments if you decide to use arping.

After all is said and done you can simply type arp -a to get your current ARP table. another reason arping isn't ideal is that it's not installed by default on many systems.

share|improve this answer
add comment

Use arping as superuser:

sudo arping -I<interface> <IP>
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.