Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have list of computers on my "Shared" sidebar, however I don't have their IP addresses.

My router has their IP addresses, however there is no computer-name <> IP address mapping.

How do I find the mapping of computer-name <> IP address?

share|improve this question

You can use a tool like Bonjour Browser or dns-sd(1) to browse services, find the hosts publishing those services, and find the IP addresses of those hosts.

With dns-sd, it might go something like this:

  1. Find hosts sharing files via the Apple Filing Protocol (AFP):

    dns-sd -B _afpovertcp._tcp local

    This will give you a list of AFP file services on your local network. You'll have to Ctrl-C out of dns-sd to get back to the shell prompt.

  2. After picking the name of an AFP service from the list, you can find out the .local hostname of the host providing that service like this:

    dns-sd -L MyOtherMac _afpovertcp._tcp local

    Again, Ctrl-C out of it after you get your answer.

  3. Resolve the "hostname.local" style mDNS host name to a set of IP addresses:

    dns-sd -G v4v6 MyOtherMac.local

    Again, Ctrl-C out of it after you get your answer.

share|improve this answer
thanks. what about finding windows/netbios mapping ? – portoalet Jul 1 '12 at 16:11
Sorry I am very bad in regular expression.. can you give me some hints to do this with a script and repeat it for each computer on my network? – nkint Oct 14 '14 at 23:11

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .