VPN Tunnel Keeps Disappearing

Status
Not open for further replies.

jerkbag

Dabbler
Joined
Feb 22, 2013
Messages
20
Hi All,

I had openvpn running fine on my freenas 8.1 (main system not jail) and recently upgraded to 9.1.1, and am encountering a strange issue: openvpn starts up fine, but after some time, the routes added when it starts simply disappear. So after a while openvpn is "running" but netstat will show all tun0 & other vpn routing gone. If I stop and start openvpn again the routes will re-appear, but if I check back in half an hour or so they will often be gone. If I look in the openvpn log I see nothing unusual, other then errors when it is being stopped after the route has disappeared, as it's trying to delete a nonexistent route.

Any idea where to start with troubleshooting this? I tried a clean install it made no difference.
 
D

dlavigne

Guest
Anything in /var/log/messages? What is the driver name of the NIC (from ifconfig)?
 

jerkbag

Dabbler
Joined
Feb 22, 2013
Messages
20
Not sure what you mean by driver name, but the NIC is called re0 on my system and I don't see anything unusual in the log. Closest thing to weird behaviour is this once in a while

Sep 12 01:18:37 freenas openvpn[5434]: [server] Inactivity timeout (--ping-restart), restarting
Sep 12 01:18:37 freenas openvpn[5434]: SIGUSR1[soft,ping-restart] received, process restarting
Sep 12 01:18:39 freenas openvpn[5434]: UDPv4 link local: [undef]
Sep 12 01:18:39 freenas openvpn[5434]: UDPv4 link remote: [AF_INET]x.x.x.x:1194
Sep 12 01:18:40 freenas openvpn[5434]: [server] Peer Connection Initiated with [AF_INET]x.x.x.x:1194
Sep 12 01:18:42 freenas openvpn[5434]: Preserving previous TUN/TAP instance: tun0
Sep 12 01:18:42 freenas openvpn[5434]: NOTE: Pulled options changed on restart, will need to close and reopen TUN/TAP device.
Sep 12 01:18:42 freenas openvpn[5434]: ERROR: FreeBSD route delete command failed: external program exited with error status: 1
Sep 12 01:18:42 freenas last message repeated 2 times -----> THIS IS BECAUSE THE ROUTE DISAPPEARS (I THINK)
Sep 12 01:18:42 freenas openvpn[5434]: /sbin/ifconfig tun0 destroy
Sep 12 01:18:42 freenas kernel: tun0: link state changed to DOWN
Sep 12 01:18:43 freenas openvpn[5434]: TUN/TAP device /dev/tun0 opened
Sep 12 01:18:43 freenas kernel: tun0: link state changed to UP
Sep 12 01:18:43 freenas openvpn[5434]: do_ifconfig, tt->ipv6=0, tt->did_ifconfig_ipv6_setup=0
Sep 12 01:18:43 freenas openvpn[5434]: /sbin/ifconfig tun0 X.X.X.X X.X.X.X mtu 1500 netmask 255.255.255.255 up
Sep 12 01:18:43 freenas openvpn[5434]: Initialization Sequence Completed
 

jerkbag

Dabbler
Joined
Feb 22, 2013
Messages
20
Thanks. I was hoping that was the issue, but I don't think so. Also - even if it does disconnect it simply restarts and recreates the tunnel so it shouldn't be an issue. What doesn't make sense to me is that this worked perfect for me up to a few days ago and the only difference is the freenas version so I feel there must be some change in behavior between the two versions.
 
D

dlavigne

Guest
Either that or the realtek is starting to get flaky? Not sure if much changed with that driver between 8.x and 9.x. It would be interesting to see if the issue persists with a different card, say an Intel.
 

jerkbag

Dabbler
Joined
Feb 22, 2013
Messages
20
True. When I have time I am going to downgrade and see if that is the sole difference.
 

jerkbag

Dabbler
Joined
Feb 22, 2013
Messages
20
For what's it worth, I downgraded to 8.3.2 and this problem went away -- no other changes. Obviously doesn't effect everyone, but there must be something different with 9.1 networking. . .
 
Status
Not open for further replies.
Top