LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   DHCP - Get next available IP address? (https://www.linuxquestions.org/questions/linux-server-73/dhcp-get-next-available-ip-address-4175430978/)

anon233 10-07-2012 11:49 AM

DHCP - Get next available IP address?
 
Is it possible to use dhclient (or any other utility available on CentOS) to query the DHCP server for the next available IP address? This will be used in a script to assign a static IP to a new virtual machine, using the next IP address in the DHCP address pool.

I suppose I could simply get an address via DHCP, and convert it to static on the new virtual server, but I would like to get the address on the host machine, and update the kickstart file's network options prior to creating the VM.

I have been searching Google, and going over man pages, but haven't come across anything yet.

acid_kewpie 10-07-2012 01:44 PM

no, you can't do this. Or rather, surely the "workaround" is exactly what you really want anyway.


All times are GMT -5. The time now is 06:28 AM.