From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4b) Gecko/20030507 Description of problem: According to the ppp man page ppp runs /etc/ppp/ip-up with the following parameters: $1=interface-name $2=tty-device $3=speed $4=local-IP-address $5=remote-ip-address $6=ipparam /etc/ppp/ip-up runs /etc/sysconfig/network-scripts/ifup-post with the following parameters: $1=ifcfg-${LOGDEVICE} where ${LOGDEVICE} is ipparam from above. Here we just lost the details of the real interface-name that we need to add a static route through a dynamically allocated ppp interface. It can, however, be recovered from the files in /var/run/ppp-{ipparam}.pid that was created by the ifup-ppp script, although it would be far better to pass it straight through. /etc/sysconfig/network-scripts/ifup-post runs /etc/sysconfig/network-scripts/ifup-routes ${DEVICE} ${NAME} where ${DEVICE} is ${LOGDEVICE} above and ${NAME} is NAME as defined in the configuration file ifcfg-ppp? Adding [ -f /var/run/ppp-$1.pid ] && { LOCALDEVICE="dev `tail -1 /var/run/ppp-$1.pid`" } near the top of /etc/sysconfig/network-scripts/ifup-routes and changing all occurrances of /sbin/ip route add $line to /sbin/ip route add $line $LOCALDEVICE will work around the problem as long as the ipparam parameter remains set by ifup-ppp and is not overridden by an entry in /etc/ppp/peers/ppp? This is a wastefull solution, though. Version-Release number of selected component (if applicable): initscripts-7.14-1 How reproducible: Always Steps to Reproduce: 1. echo 10.1.2.0/24 > /etc/sysconfig/network-scripts/route-ppp4 2. ipup ppp4 3. interface comes up. Actual Results: 1. Routing is not added. Expected Results: 1. Routing should have been added through the newly brought up ppp link. Additional info: 1. It cannot work since ip route does not know where to route to. 2. I am using ppp-2.4.2-b1 and pptp-linux client, but that really shouldn't make any difference since the behaviour of ppp in relation to the scripts is the same.
I can confirm this. Same problem on FC1. I've built a VPN solution using ppp and initscripts. My solution to the problem is: --8<--------- --- initscripts-7.42.2.orig/sysconfig/network-scripts/ifup-post 2004-02-15 13:49:15.000000000 +0100 +++ initscripts-7.42.2/sysconfig/network-scripts/ifup-post 2004-02-15 14:23:33.000000000 +0100 @@ -12,7 +12,13 @@ /etc/sysconfig/network-scripts/ifup-aliases ${DEVICE} ${CONFIG} fi -/etc/sysconfig/network-scripts/ifup-routes ${DEVICE} ${DEVNAME} +# The real device may be sent as a second parameter + +PHYSDEVICE=${DEVICE} +[ -z $2 ] || [ "foo$2" = "fooboot" ] || + PHYSDEVICE=$2 + +/etc/sysconfig/network-scripts/ifup-routes ${PHYSDEVICE} ${DEVNAME} if [ "$PEERDNS" != "no" -o -n "$RESOLV_MODS" -a "$RESOLV_MODS" != "no" ]; then --8<--------- Also, is using $NAME for finding route files deprecated? That was the behaviour for RH9 but $DEVNAME is used in FC1.
Sorry. This is needed also: --8<--------- --- initscripts-7.42.2.orig/ppp/ip-up 2004-02-15 13:49:15.000000000 +0100 +++ initscripts-7.42.2/ppp/ip-up 2004-02-15 14:36:03.000000000 +0100 @@ -8,7 +8,7 @@ LOGDEVICE=$6 REALDEVICE=$1 -[ -f /etc/sysconfig/network-scripts/ifcfg-${LOGDEVICE} ] && /etc/sysconfig/network-scripts/ifup-post ifcfg-${LOGDEVICE} +[ -f /etc/sysconfig/network-scripts/ifcfg-${LOGDEVICE} ] && /etc/sysconfig/network-scripts/ifup-post ifcfg-${LOGDEVICE} ${REALDEVICE} [ -x /etc/ppp/ip-up.local ] && /etc/ppp/ip-up.local "$@" --8<---------
Fixed in initscripts-8.32-1. Thanks for your report.