In /etc/sysconfig/network-scripts/network-functions, add_default _route tests check_device_down before restoriing the default route defined in $GATEWAY and $GATEWAYDEV. The test is reversed, since check_device_down returns zero if the tested interface is down, and the ! in the test will cause the route to be added if the interface is still up. I found this when trying to setup a ppp connection in addition to my nornal lan connection on eth0. Starting ppp replaces the default route by its own default, and the original default should be reactivated when ppp goes down. This did not work until I changed the code as shown below. Here is the code as I have modified it: add_default_route () { . /etc/sysconfig/network find_gateway_dev if [ "${GATEWAY}" != "" -a "${GATEWAY}" != "none" -a "${GATEWAYDEV}" != "" ] ; then # if ! check_device_down ; then # direction of test reversed by BEB 6 sept 2000 if check_device_down ; then /sbin/route add default gw ${GATEWAY} ${GATEWAYDEV} fi fi }
It occurs to me that there may be something else going on here. Perhaps the original test is correct, but that the wrong interface is being checked. that is, instead of "add default route (for eth0) if ppp0 has gone down", it should be "add default route (for eth0) if eth0 is still up". In this case, when check_device_down checks $DEVICE, $DEVICE should be eth0, not ppp0.
Closing out bugs on older, no longer supported, releases. Please open a new bug if this persists on current releases.