Hi!
Sorry for posting the patch on the list, I know this is bad, but it is
really small and I don't remember who said he would change pump by dhcpcd.
So I tried to change /sbin/ifup myself. Obviously, I'm no expert and I can't
imagine that it is perfect now. It probably isn't. But as far as I have
tested, it works quite fine for me, so it is not totally broken. Only
problem I have is that it sometimes says "failed" even if the IP information
comes up. I don't understand why. Maybe put a "sleep" somewhere (?). I don't
know how to debug this, sorry.
I even simulated a system crash to test if the error message appeared on
startup when trying to kill a process that isn't running.
Little explanation : if the /var/run/dhcpcd-{$DEVICE}.pid file exists, we
try to kill the process with this PID (it doesn't exist if we are rebooting
from a crash), then we delete the pid file, and then we rerun dhcpcd. So we
are sure there is one-and-only-one dhcpcd running. It can helps if someone
start ifup without starting ifdown before, because dhcpcd doesn't seem to
complain when it is loaded many times from ifup. =(
The patch for /sbin/ifdown is probably just :
========================================================
if [ "$BOOTPROTO" = bootp -o "$BOOTPROTO" = dhcp ]; then
dhcpcd -k ${DEVICE}
fi
========================================================
instead of the same with "pump".
Thanks for your help. Tell me if you want some testing for your
modifications.
Gregus
ifup-dhcpcd.patch.bz2