[Bug 249802] Re: Restart of vpnc when not requested to stop.

2008-09-08 Thread Tim Jones
Excellent idea, works perfectly :) Although I'd add the '--local-port 0' option to ensure the respawned vpnc doesn't fail due to port already in use problems. I'm using the exec line: exec /usr/sbin/vpnc --no-detach --pid-file /var/run/vpnc/pid --ifmode tun --non-inter --local-port 0 --dpd-idle 0

[Bug 249802] Re: Restart of vpnc when not requested to stop.

2008-09-07 Thread Christoph Langner
I solved this now by using upstart. Create a /etc/event.d/vpnc with the following content --- console output exec /usr/sbin/vpnc --no-detach respawn --- Now, you can use $ sudo start vpnc to start vpnc or $ sudo stop vpnc to stop it. In the case vpnc died when started via `sudo start vpnc` it

[Bug 249802] Re: Restart of vpnc when not requested to stop.

2008-09-07 Thread Christoph Langner
Yep, i noticed too that vpnc looses quite often it's connection. What I've got in my mind is some kind of process monitor. Like $ foo vpnc start --respawn $ foo vpnc stop When i start vpnc with `foo vpnc start --respawn` it get's restarted until i quit it with `foo vpnc stop`. There are some proc