VPN tunnel closes after 1 hour

Hi,

I have a VPN server with strongSwan and xl2tpd, using PSK for authentication.

The clients are Window 7 and Windows 8. The initial connection is successful, then after 1 hour (~58 min) the connection drops. If I use dead peer detection the connections is cut off, if not the client show as connected but no packets go through.

You'll see below the log. Looks like the re-key is successful, but immediately after the client requests another re-key.
Any ideas?
1.2.3.4 is the client, 5.6.7.8 is the server.



Have you checked your vpn timing ?



Have you checked your vpn timing ?



conn vpnserver
type=transport
ike=3des-sha1-modp1024!
authby=secret
rekey=yes
lifetime=2h
ikelifetime=4h
left=5.6.7.8
leftprotoport=udp/l2tp
leftid=@5.6.7.8
right=%any
rightprotoport=udp/%any
auto=add

1:2:3:4:5:6:7:8:9:10:11:12:13:


Select all

Open in new window
jqBind('#answerOrCommentView .buttonsInline20-40637046-1','click',function(e){selectElementById('answerOrCommentViewInlineCode20-40637046-1');return false;});



It looks like the "other side" is configured with a 3600 second (1 hour) lifetime. From your log:
"Feb 28 12:42:28 firewall charon: 03[IKE] received 3600s lifetime, configured 7200s"



Yup. Already tried it with 3600s, with 1800s etc. Spent about 3 days on this.

The same config works out-of-the-box (just install and copy config files) on a debian system, so it's something system specific. Could not figure out why.



Can you get a log from the client side?

Are all the clients at different locations, or could they by chance be at the same location. So that you have 2 or more client connections that appear to be coming from the same source IP address?

Share this

Related Posts

There was an error in this gadget