• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How to find ip address using mac in a network

 
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i know the mac address of all machines in a network. how to find ip address of all the machines using mac.
i am using rarp and dhcp to find ip address.but it shows commands not found.
how can i access the rarp or dhcp?. or
any other way to find ip address from mac in a network?
 
rama ilango
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Simply i want list of all used ip addresses in a network.
how to find it?
 
Saloon Keeper
Posts: 27763
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Rama, you've basically asked the same question 3 times now. PLEASE don't do that! Just keep the original thread going. It keeps the message board from getting untidy.

There is no absolute way to do what you want. There's no central authority in TCP/IP that hands out IP addresses. Each machine that participates in the network is free to select one or more addresses to service.

Actually, there's sort of a central authority, and that's DHCP. But DHCP cannot forbid machines from grabbing any address they want, it just manages a database of addresses that it can assign to machines that solicit it.

All you can do is ping each possible IP address in the subnet. Excluding, of course, the network and broadcast addresses. If a machine answers the ping. If it does not, one of the following is true:

1. No machine has been configured for that address
2. The machine that responds to that address is not currently live on the network.
3. A machine is using that address, but has been instructed not to respond to PING requests (usually by firewall rules).
4. The address may be served up by DHCP, but at the moment, no machine has been assigned to it.

Actually, I had to take an inventory just this past Friday. I needed a new IP address for a test server. At one time almost all my public IP addresses were assigned, but over the years, many of them had fallen idle. So I pinged all possible addresses to see which ones were still in use.
 
rama ilango
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sorry for using muli thread to single question.
If i do ping each possible IP address(ex 192.xxx.xxx.1 to 192.xxx.xxx.255), it take more time.So i can't apply this.
But i know the mac address and vnc port of all the machine. Any other way to find ip addresses from this?.
advance thanks for reply
 
author and jackaroo
Posts: 12200
280
Mac IntelliJ IDE Firefox Browser Oracle C++ Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
As Tim mentioned, each single computer can have multiple IP addresses for any given MAC address.

Rama wrote:If i do ping each possible IP address(ex 192.xxx.xxx.1 to 192.xxx.xxx.255), it take more time.


Please don't ping that address range - some of those addresses may be internal computers, but others in that range belong to other companies. As one simple example, the address range 192.165.0.0 - 192.165.0.255 belongs to Celsius Industrier AB in Sweden.

A quick Google search found a simple table showing the private address ranges. As you can see from that, if you want to use an address starting with 192, then you have 2 choices:
  • 192.0.0.0 - 192.0.0.255 : a class C network with a total of 255 addresses.
  • 192.168.0.0 - 192.168.255.255 : technically 255 class C networks, although many people use it as a class B network


  • Rama wrote:If i do ping each possible IP address(ex 192.xxx.xxx.1 to 192.xxx.xxx.255), it take more time.


    True, but it is the only reliable way of finding which IP addresses are in use. And the amount of time is not too excessive:

    If you are using the 192.0.0/24 network, even a simple shell script could reach every address within that range within 4 minutes.

    If you are using the 192.168/16 network as a class B network, it would only take 18 hours using a simple shell script. Start it today: get the results by tomorrow.
     
    reply
      Bookmark Topic Watch Topic
    • New Topic