I would like to verify a dhcp server configuration, i.e. if a client gets the correct DNS server, domain name, etc. I have a working DHCP setup, and a computer with a static IP address from which I can send DHCP requests to the DHCP server.
I am looking for a library (or program) to request a lease and dump all the information.
So far I have seen:
- dhcping -- works, but doesn't write out the lease it received
- pydhcpd -- not developed, alpha (?)
- pydhcplib -- no documentation, not sure if it can actually send packages or is just the encapsulation; The dhquery should work based on this library and claims to do partly what I want, but after fixing an API change on client.SendDhcpPacketTo it doesn't receive any response.
Is there any existing script or library that can print or receive the DNS information the DHCP server sends out? Any language is acceptable (Perl? Java?).
Ultimately, I would like to put that into a Nagios check script.