Thanks for coming back.What do you mean with "got stacked"? There is a possibility that it couldn't reconnect because of the Killswitch. How do you have vpnmon configured?
by got stacked I mean the script was stacked somewhere in routine i.e. it stopped trying to connect for some reason, last try was on 04:16:09 (VPN reset) and no logs after this time until I kill it and re-run the script manually. Shame i did not take the picture from SSH
Code:
Fri Jul 21 04:16:09 CEST 2023 - VPNMON-R2 - Executing VPN Reset
Fri Jul 21 19:29:53 CEST 2023 - VPNMON-R2 - API call made to update WAN0 city to Brno
Here are more detail logs from the router itselfs
Code:
<15>1 2023-07-21T04:15:02+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 3
<15>1 2023-07-21T04:15:03+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient4)
<15>1 2023-07-21T04:15:03+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 841:notify_rc stop_vpnclient5
<15>1 2023-07-21T04:15:03+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: waitting "stop_vpnclient4" via ...
<15>1 2023-07-21T04:15:03+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 4
<15>1 2023-07-21T04:15:04+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient5)
<15>1 2023-07-21T04:15:04+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 5
<15>1 2023-07-21T04:16:09+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 1312:notify_rc stop_vpnclient1
<15>1 2023-07-21T04:16:09+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient1)
<15>1 2023-07-21T04:16:09+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 1316:notify_rc stop_vpnclient2
<15>1 2023-07-21T04:16:09+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: waitting "stop_vpnclient1" via ...
<15>1 2023-07-21T04:16:09+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 1
<15>1 2023-07-21T04:16:10+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient2)
<15>1 2023-07-21T04:16:10+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 1354:notify_rc stop_vpnclient3
<15>1 2023-07-21T04:16:10+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: waitting "stop_vpnclient2" via ...
<15>1 2023-07-21T04:16:10+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 2
<15>1 2023-07-21T04:16:11+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient3)
<15>1 2023-07-21T04:16:11+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 1394:notify_rc stop_vpnclient4
<15>1 2023-07-21T04:16:11+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: waitting "stop_vpnclient3" via ...
<15>1 2023-07-21T04:16:11+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 3
<15>1 2023-07-21T04:16:12+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient4)
<15>1 2023-07-21T04:16:12+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 1462:notify_rc stop_vpnclient5
<15>1 2023-07-21T04:16:12+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: waitting "stop_vpnclient4" via ...
<15>1 2023-07-21T04:16:12+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 4
Manual kill and restart time
<15>1 2023-07-21T19:29:57+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 14093:notify_rc stop_vpnclient1
<15>1 2023-07-21T19:29:57+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient1)
<15>1 2023-07-21T19:29:58+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 14096:notify_rc stop_vpnclient2
<15>1 2023-07-21T19:29:58+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: waitting "stop_vpnclient1" via ...
<15>1 2023-07-21T19:29:58+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 1
<15>1 2023-07-21T19:29:59+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient2)
<15>1 2023-07-21T19:29:59+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 14136:notify_rc stop_vpnclient3
<15>1 2023-07-21T19:29:59+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: waitting "stop_vpnclient2" via ...
<15>1 2023-07-21T19:29:59+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 2
<15>1 2023-07-21T19:30:00+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient3)
<15>1 2023-07-21T19:30:00+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 14173:notify_rc stop_vpnclient4
<15>1 2023-07-21T19:30:00+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: waitting "stop_vpnclient3" via ...
<15>1 2023-07-21T19:30:00+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 3
<15>1 2023-07-21T19:30:01+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient4)
<15>1 2023-07-21T19:30:01+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: service 14214:notify_rc stop_vpnclient5
<15>1 2023-07-21T19:30:01+02:00 RT-AX86U-3E18-AB67A2D-C rc_service - - - rc_service: waitting "stop_vpnclient4" via ...
<15>1 2023-07-21T19:30:01+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 4
<15>1 2023-07-21T19:30:02+02:00 RT-AX86U-3E18-AB67A2D-C custom_script - - - custom_script: Running /jffs/scripts/service-event (args: stop vpnclient5)
<15>1 2023-07-21T19:30:02+02:00 RT-AX86U-3E18-AB67A2D-C openvpn-routing - - - openvpn-routing: Clearing routing table for VPN client 5
99% time, the script is running just fine. This was the first time my internet (WAN connection) was offline for 20h and when WAN connection gets back the script was not trying to reconnect.
Attaching config.