On 11/09/09 11:10 AM, Daniel wrote:
Hi,I have a situation where I'm trying to determine an IP address from a mac address on a network that uses a DHCP server. I use the following command: arp -a | grep $macAddress | awk "{print $2}" but this is returning multiple addresses. I believe what's happening is that we're restarting these hosts frequently during testing and the old leases for the mac address are not up yet and so there are multiple entries in the dhcp table. What's the best way to solve this? I need to determine for sure which IP address is being used. Should I just ping each address that I get or is there a better way to do this?
You need to make sure that your test hosts shutdown cleanly and as a part of that actively release the DHCP address that they receive from the DHCP server.
Darren _______________________________________________ networking-discuss mailing list [email protected]
