Vpn L2TP Client does not automatically reconnect when disconnecting

Hello, I have an openwrt installation on an x86, it is running very well, if it weren't for one detail, I use a vpn client of the L2TP type, and sometimes it disconnects, either due to lack of internet or something like that, and at reestablish internet the vpn does not reconnect automatically. Would there be any way to solve this, could someone help me.