I access the internet via pptp. So I configured /etc/ppp/options.pptp and /etc/config/network and successfully brought up VPN ( I can ping any site so i think it works ok)
According wiki the file /etc/ppp/ip-up is a shell script which is executed when the tunnel is started.
$ls -l /etc/ppp/ip-up
-rwxr-xr-x 1 root root 694 Jun 17 19:33 /etc/ppp/ip-up
my vpn brings up automatically on router start (or '$ifup vpn-iface-name' if it was down)
Should this script really be executed on start? (I put 'echo lol > file' and I can execute it with shell so I'm absolutely sure it's not executed on start) Is there another way to configure NAT on vpn start?