"Correct" way to obtain DHCP lease info?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Is there a correct way to obtain information about the DHCP lease received by systemd-networkd's DHCP client functionality? It was easy enough to find SERVER_ADDRESS in /var/run/systemd/netif/leases/4, but there is a big fat warning stamped at the top of the file:

# This is private data. Do not parse.
I'd like to be able to make a widget that can tell me which DHCP server issued my lease, how much more time I have, etc., mainly because I want to be able to ping something that is known to be on the network. I'm dealing with a lazy sysadmin who doesn't want to put a gateway on this private network, I haven't found a solution using the CLI tools.

Thanks in advance.

--
Bruce A. Johnson | Firmware Engineer
Blue Ridge Networks, Inc.
14120 Parke Long Court Suite 103 | Chantilly, VA 20151
Main: 1.800.722.1168 | Direct: 703-633-7332
http://www.blueridgenetworks.com
OpenPGP key ID: 296D1CD6F2B84CAB https://keys.openpgp.org/


Attachment: OpenPGP_signature
Description: OpenPGP digital signature

_______________________________________________
systemd-devel mailing list
systemd-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/systemd-devel

[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux