Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I use vpnc on Linux, and with our corporate VPN setup (it's a Cisco something or other router), it's not exactly rock-solid. I run most things inside screen, so it's not a huge deal, but isn't there some way of maintaining connections across VPN restarts?

It seems like if I had a separate router box running vpnc, I would get it for free just by setting that box as my gateway. How can I emulate the same behavior with a single box?

When the VPN restarts, I get a different IP address and MAC address on the tun0 or tap0 device.

I tried playing games by using tap0 for the tunnel and then bridging it to various things (dummy devices, loopbacks, etc.), but couldn't get anything working.

share|improve this question

2 Answers 2

If your IP address changes when the VPN restarts there's really not much you can do about it - the change of IP address is going to kill any active sessions.

share|improve this answer

You could run ppp over your VPNed connection to something on the other side that gives you a static IP. Run all of your stuff over that connection, and make it auto reconnect.

I wouldn't call it pretty, but it would work! :)

share|improve this answer
    
+1 - sweet hack –  James Dec 24 '09 at 14:50
    
I feel like I got the idea from somewhere... no idea where. –  Bill Weiss Dec 28 '09 at 21:07

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.