]> andersk Git - moira.git/blobdiff - gen/dhcp.sh
Reimplement events.gen as a Pro*C application.
[moira.git] / gen / dhcp.sh
index 4c2afe7b08738e5cd6a13460c067855bb55e3960..c43efea865107bf1b55eb27138fde4abdb456fc3 100755 (executable)
@@ -19,6 +19,9 @@ BOOTGEN=/var/boot/dhcpd.conf.print
 BOOTHEAD=/var/boot/dhcpd.conf.head
 BOOTFOOT=/var/boot/dhcpd.conf.foot
 BOOTFILE=/var/boot/dhcpd.conf
+LEASEFILE=/var/boot/dhcpd.leases
+PIDFILE=/var/boot/dhcpd.pid
+BINFILE=/var/boot/dhcpd
 PSWDFILE=/var/boot/hp.add
 
 # Alert if the tar file or other needed files do not exist
@@ -39,6 +42,10 @@ done
 # Build full bootptab
 cat $BOOTHEAD $BOOTGEN $BOOTFOOT > $BOOTFILE
 
+# kill and rerun dhcpd
+test -f $PIDFILE && kill `cat $PIDFILE`
+test -x $BINFILE && $BINFILE -cf $BOOTFILE -lf $LEASEFILE -pf $PIDFILE 
+
 # cleanup
 test -f $TARFILE && rm -f $TARFILE
 test -f $0 && rm -f $0
This page took 0.109219 seconds and 4 git commands to generate.