Would someone please tell me how I can display DHCP information on a RedHat client. When I use ifconfig it only gives the ip address status and gateway address. I need to display lease and DNS server info as well.
Depending on if you are using [tt]dhclient[/tt] rather than the old [tt]dhcpcd[/tt], the lease files are by default contained in [tt]/var/lib/dhcp[/tt].
Ok this ones a guess, I'll test on my dev box shortly, but in the meantime:
A good place to start is in the /proc "virtual" file system. You understand what /proc is about?
Ok /proc is a virtual file system of all the running process of your server, it is dynamically built as the system runs up, you (as root) can modify the files within /proc but any mods will be lost on re-boot.
But getting back to your question try: more /proc/net/* and see what's recorded there?
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.