[OpenVPN home] [Date Prev] [Date Index] [Date Next]
[OpenVPN mailing lists] [Thread Prev] [Thread Index] [Thread Next]
Web openvpn.net

Re: [Openvpn-users] Timeouts and routes

  • Subject: Re: [Openvpn-users] Timeouts and routes
  • From: Mathias Sundman <mathias@xxxxxxxxxx>
  • Date: Tue, 1 Feb 2005 07:18:49 +0100 (CET)

On Tue, 1 Feb 2005, Andrew Alston wrote:

On starting openvpn I may it add specific routes to the ADSL gateway
using the net_gateway parameter, when the adsl gets restarted while
openvpn reestablishes itself to the VPN server fine, these routes don't
get readded to the new net_gateway, is there any way I can make it read
these routes on reestablishment so I can fix this problem, as its
proving to be rather difficult to manage at the moment.

Hmm, I've got one teory:

When --redirect-gateway is used, OpenVPN saves the old default gw before it deletes it and adds its own.

When OpenVPN detects that it has lost connectivity (due to your IP change), it will delete the new route it had had added, re-add your old one.

If this happends, you will now end up with two default routes, your new correct one, and the old one re-added by OpenVPN.

When OpenVPN now re-connects it will try to save the old dafault gateway, and maybe it's saving the wrong one, before it deletes them, which would cause your routes to net_gateway to use the wrong gw.

Try using --redirect-gatway def1 instead to see if that makes any diffrence.

Mathias Sundman                  (^)   ASCII Ribbon Campaign
OpenVPN GUI for Windows           X    NO HTML/RTF in e-mail
http://www.nilings.se/openvpn    / \   NO Word docs in e-mail

Openvpn-users mailing list