From Bugzilla Helper: User-Agent: Mozilla/4.7 [en] (X11; I; SunOS 5.7 sun4u) Description of problem: dhcpcd is stopped when you do a network stop command. network calls ifdown which kills dhcpcd by calling dhcpcd -k. The -k option sends dhcpcd a SIGHUP which causes the lease on the IP address to be released. This is wrong. Instead it should be sent a SIGTERM so that the cache info for the lease is retained. Also, the ifup script does not allow the user to specify additional options to dhcpcd. How reproducible: Always Steps to Reproduce: 1.service network stop 2. 3. Actual Results: dhcpcd was killed with a SIGHUP instead of a SIGTERM. Expected Results: dhcpcd should have saved its information about its current lease so that on next startup it would ask for its old lease. Additional info: A possible fix for ifdown: ifdown should *not* do a dhcpcd -k ${DEVICE} instead it should do a kill -15 The associated fragment should look lsomething like this: dhcpcdPid=$(pidof -x dhcpcd) [ -n "${dhcpcdPid}" ] && { kill -15 ${dhcpcdPid} retcode=$? } ifup should look like this instead of what it currently does. (The initial value for DHCPCDASRGS are my customizations.) if [ -n "${DYNCONFIG}" ]; then PUMPARGS= DHCPCDARGS='-d -R' # My example additional flags. if [ -n "${DHCP_HOSTNAME}" ]; then PUMPARGS="-h ${DHCP_HOSTNAME}" DHCPCDARGS="${DHCPCDARGS} -h ${DHCP_HOSTNAME}"
One reason for having additional arguments to dhcpd is one I just ran into. In setting up my new fractional T1, I needed to install a Linux box as the router and firewall. Like the more popular cable modems and DSL setups, there is an ethernet connection from the Wan and of course the local network. You don't want to run dhcpd on the external network, but you do want to run it on the internal networks (in my case, I have two disjoint local networks, and the firewall box has 3 ethernet cards). You don't want to hack the Red Hat provided script, since that won't survive any upgrades.
Fixed in 6.13-1 (both using kill -15, and also using any DHCPCDARGS/PUMPARGS in the environment (so they can be set in the ifcfg files.)
*** Bug 53670 has been marked as a duplicate of this bug. ***