Re: using dhcpcd's -c option
On Tue, 23 Jun 1998, Eric House wrote:
> dhcpcd takes as a option a script that gets run when an IP address is
> assigned, and I could use this script to put the IP address in some
> known place on the network. But I can't figure out how dhcpcd is
> getting called -- or rather, in which of the myriad places in
> /etc/rc?.d/* where it *is* invoked I ought to be adding this param.
$ more /etc/init.d/dhcpc
[...]
case "$1" in
start)
start-stop-daemon --start --verbose --exec $DAEMON -- -r -c \
/root/bin/dhcp.up
;;
stop)
kill -9 `cat /var/run/dhcpcd-eth0.pid`
#start-stop-daemon --stop --verbose --exec $DAEMON
;;
[...]
I use the rude stop because dhcp will send out an ip release message,
which means my ip will change, when killed normally. I also need the -r
for my setup.
HTH,
Brandon
--+--
Brandon Mitchell <bhmit1@mail.wm.edu> | Debian Testing Group Status
PGP Key: finger -l bhmit1@cs.wm.edu | http://bhmit1.home.ml.org/deb/
Dijkstra probably hates me (Linus Torvalds, in kernel/sched.c)
--
To UNSUBSCRIBE, email to debian-user-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Reply to: