This is a equivalent question asked here for OSX. What is the easiest way to find out a NetBIOS name of a WIndows PC in my LAN by MAC address and vice versa?It can be done by IP with: nmblookup -A a.b.c.dnmblookup pc_netbios_nameIs there a similar command for MAC address?
How can I find out the name of a Windows PC on my LAN by MAC address?
lan;netbios
You can find out the MAC address of a recently contacted device by its IP address using the arp table:ping -c1 -w1 10.0.2.2PING 10.0.2.2 (10.0.2.2) 56(84) bytes of data.64 bytes from 10.0.2.2: icmp_seq=1 ttl=63 time=0.785 ms--- 10.0.2.2 ping statistics ---1 packets transmitted, 1 received, 0% packet loss, time 0msrtt min/avg/max/mdev = 0.785/0.785/0.785/0.000 msarp -n 10.0.2.2Address                  HWtype  HWaddress           Flags Mask            Iface10.0.2.2                 ether   52:54:00:12:35:02   C                     eth0You could merge this into a little function:iptoarp() {    local ip=$1    ping -c1 -w1 $ip >/dev/null    arp -n $ip | awk '$1==ip {print $3}' ip=$ip}iptoarp 10.10.0.2    # --> 52:54:00:12:35:02I know of no easy way to get an IP address or NetBIOS name from a MAC address. Either run arpwatch and scan the log file for chat from that device, or ping each IP address on your LAN in turn and look for the arp response.