I've a connection between an openVPN server on the cloud and an openVPN client installed on a mobile router using a WindTre SIM.
The problem is that the windTre SIM disconnects every for hours for some second (to change IP address) and this cause openvpn to fall and the openvpn reconnection happens after 17 minutes, this is really too much, is there some option to avoid this ugly behaviour ?
these are the configuration on both sides:
key server.key # This file should be kept secret
server 10.8.0.0 255.255.255.0
push "route 172.18.0.0 255.255.0.0"
route 172.18.0.0 255.255.0.0
push "redirect-gateway def1 bypass-dhcp"
push "dhcp-option DNS 22.214.171.124"
push "dhcp-option DNS 126.96.36.199"
keepalive 10 120
tls-auth ta.key 0 # This file is secret
management localhost 7505
you're right, the problem is not on Openvpn, it restarts correctly after about 40 seconds, the problem is with the application software that remain freezed due to this lost of connection. I will check if it is possible to modify the software but otherwise is there some chance to hide the disconnection on openvpn? I know, it could be a workaround but if available it will solve imediately my problem.
it is the IP address of the client that changes,
-float seems to be associated with the client configuration
Allow remote peer to change its IP address and/or port number, such as due to DHCP (this is the default if –remote is not used). –float when specified with –remote allows an OpenVPN session to initially connect to a peer at a known address, however if packets arrive from a new address and pass all authentication tests, the new address will take control of the session. This is useful when you are connecting to a peer which holds a dynamic address such as a dial-in user or DHCP client.Essentially, –float tells OpenVPN to accept authenticated packets from any address, not only the address which was specified in the –remote option.