--- /etc/init.d/net.eth.orig 2003-05-21 10:59:15.000000000 +0200 +++ /etc/init.d/net.eth0 2003-05-21 16:26:04.000000000 +0200 @@ -107,6 +107,25 @@ eend 0 fi + # Set up static routes (if any) + if eval [ \"\${stroutes_$IFACE}\" ]; then + ebegin " Setting static routes" + local route= target= mask= gw= ttype= + for route in $(eval echo \${stroutes_$IFACE}); do + target=${route%%_*} + mask=${target##*/} + gw=${route##*_} + if [ -z "$mask" -o "$mask" = '32' ]; then + ttype=host + else + ttype=net + fi + /sbin/route add -$ttype $target gw $gw dev $IFACE + retval=$? + done + eend $retval + fi + # Enabling rp_filter causes wacky packets to be auto-dropped by # the kernel if [ -e /proc/sys/net/ipv4/conf/${IFACE}/rp_filter ]