Skip to content

Instantly share code, notes, and snippets.

@tknv
Created November 5, 2011 16:49
Show Gist options
  • Save tknv/1341761 to your computer and use it in GitHub Desktop.
Save tknv/1341761 to your computer and use it in GitHub Desktop.
add route after pon KAISYA
#!/bin/sh
if [ "${PPP_IPPARAM}" = "KAISYA" ];then
while [ -z `ifconfig | grep ${IFNAME}` ]
do
sleep 1
done
# accept forward
echo 1 > /proc/sys/net/ipv4/ip_forward
# add route
route add -net 172.20.0.0 netmask 255.255.0.0 dev ${IFNAME}
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment