[libvirt] [RFC] net-dhcp-leases: Query: Reg: Leases API Script

Nehal J Wani nehaljw.kkd1 at gmail.com
Tue Oct 22 10:45:37 UTC 2013


Q1. The --dhcp-script option will require libvirt to provide a script
or executable file to be run. Now as the man page says, this file is
executed "Whenever a new DHCP  ease is created, or an old one
destroyed". Life was easy with the script, as it used the command sed
to remove the destroyed lease. eblake had suggested me to use a C
program instead. So I wanted to finalize whether to go with C or
continue with shell script.

Q2. The above executable file will be writing the custom formatted
lease parameters to a file "dnsmasq-ip-mac.status" (suggestion open
for name). This newly created/updated file will be parsed by the API.
We need to decide the format for the file. Do we continue with space
separated parameters as before?

Q3. What should be the location of the above two files? Is there any
example that I can follow in libvirt for deploying custom-script
files/C programs which are not to be linked?

Script is attached.

-- 
Nehal J Wani
-------------- next part --------------
A non-text attachment was scrubbed...
Name: macscript.sh
Type: application/x-sh
Size: 1126 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20131022/6d00f206/attachment-0001.sh>


More information about the libvir-list mailing list