<html><body><span style="display:block;" class="xfm_18967603"><div><span style="font-size:14.4px;">On your advice, I set the "keyingtrays = 0" option on Friday and restarted LibreSwan. But this morning I discovered that L2TP-connection is disabled again. I executed the command "</span><span style="white-space:pre-wrap;">ipsec auto --up myvpn</span><span style="font-size:14.4px;">" and the connection was restored. That is, the problem remains. What else can be done to solve the problem?</span><br/></div> <br/><blockquote class="xfmc1" style="border-left:1px solid rgb(204, 204, 204);margin:0px 0px 0px 0.8ex;padding-left:1ex;"><pre>Auto=omdemand or auto=start but leaves keyingtries to 0 (infinite)

Sent from mobile device

> On Mar 15, <span data-ukrnet-code="2019">2019</span>, at 09:52, yuryb <<a href="mailto:yuryb@ukr.net" target="_self" rel="noreferrer noopener">yuryb@ukr.net</a>> wrote:

> Good for you!
> I configured L2TP/IPSec tunnel, which should work around the clock. But, when I come to work in the morning, I find that the tunnel is disconnected. At the same time, if I run the command "ipsec auto --up myvpn", the connection restores.
> How to automate reconnection using LibreSwan?

> My configuration:
> config setup
>         virtual_private=%v4:10.0.0.0/8,%v4:192.168.0.0/16,%v4:172.16.0.0/12,%v4:25.0.0.0/8,%v4:100.64.0.0/10,%v6:fd00::/8,%v6:fe80::/10
>         protostack=netkey
> conn myvpn
>         ikev2=never
>         type=transport
>         authby=secret
>         pfs=no
>         ike=aes128-sha1-modp<span data-ukrnet-code="1024">1024</span>
>         esp=aes128-sha1
>         left=%defaultroute
>         leftprotoport=17/<span data-ukrnet-code="1701">1701</span>
>         right=195.149.70.70
>         rightprotoport=17/<span data-ukrnet-code="1701">1701</span>
>         auto=ondemand
>         keyingtries=3
>         dpddelay=30
>         dpdtimeout=120
>         dpdaction=clear
>         rekey=yes
>         ikelifetime=8h
>         keylife=1h

> _______________________________________________
> Swan mailing list
> <a href="mailto:Swan@lists.libreswan.org" target="_self" rel="noreferrer noopener">Swan@lists.libreswan.org</a>
> <a href="https://lists.libreswan.org/mailman/listinfo/swan" target="_blank" rel="noreferrer noopener">https://lists.libreswan.org/mailman/listinfo/swan</a>

</pre></blockquote>   </span></body></html>