VPN Connection Authentication Failed Trying to Reconnect
I have an iPhone 6 running iOS 8.4 and an iPad Air 2 running iOS 8.4. I am able to make a VPN connection from each of them to my ubuntu 14.04 server. The iPhone can do it through cellular network or wifi. They both work fine and all packets go through the VPN and appear on the internet as coming from the ubuntu server.
When I close the VPN connection and try to reconnect, I get a popup window that says the VPN Connection Authentication Failed. Looking at the logs on my server, the device successfully authenticates with the server, but then it closes the connection. Rebooting the server makes no difference, the devices are still unable to connect. However, rebooting the device allows it to work again. I can connect and reconnect to my server as many times as I like as long as I reboot the iOS device after each disconnect.
Turning off wifi and using the cellular network doesn't help. It is still unable to connect until the device is rebooted. The reverse is also true. After connecting through the cellular network and disconnecting, the device must be rebooted before it can connect again even if I switch it back to wifi.
Changing dpddelay, dpdtimeout, and dpdaction on the server does not make any difference.
I am using an L2TP VPN type. Putting the device to sleep and waking it back up does not allow it to connect.
I have searched far and wide, but have not seen this problem anywhere. I see it on both devices I have tried. So far the only solution I can find is rebooting the devices. Is there a way to reset whatever needs to be reset without shutting down the device?
Thanks for your help.
Ed
iPhone 6, iOS 8.4