Sunny wrote:
Hi, I have a tun0 device, created by the openvpn connection to another machine. I need to start some script _after_ the vpn is fully initialized - i.e. after the tun0 device is set up (it takes a little time). I tried to set this script as a service, which runs after all other services (incl. openvpn) are started, but it still fails, because it tries too early, before the tun device is up.
So, looks like I have to go trough another route - like using all the infrastructure under if-up maybe, i.e. using ifservices-xxxx. I have created /etc/sysconfig/network/ifservices-tun0 directory, and put there links to the start/stop scrip, but it never gets kicked.
Any ideas what's wrong, or how I can apporach this problem?
Why not add a test to your script to verify the VPN is up? For example, you could try to ping the other end of the tunnel and if fail, pause and then retry. Once you have a successful ping, you can continue on with the rest of the script. -- Check the headers for your unsubscription address For additional commands send e-mail to suse-linux-e-help@suse.com Also check the archives at http://lists.suse.com Please read the FAQs: suse-linux-e-faq@suse.com