Page 1 of 1

disconnected on lock

Posted: Wed Jan 01, 2014 9:33 pm
by pkillpeers
hey there.

Im using iphone 5s with ios 7.04 and openvpn 1.03 build 108
Everytime i lock my iphone, i get disconnected from the vpn! is this normal? something i can do?
This defeats the purpose of getting a vpn in the first place, because i have to connect everytime i turn my screen on.

I don't know if this information is needed, but i'm using Mullvad vpn. thanks in advance

Re: disconnected on lock

Posted: Wed Jan 01, 2014 10:01 pm
by pkillpeers
From my testing, i can conclude its not about lock.
After a few minutes the vpn pauses.
Acording to my logs:
2014-01-01 21:52:09 OS Event: SLEEP
2014-01-01 21:52:09 EVENT: PAUSE
2014-01-01 21:55:43 OS Event: WAKEUP

I guess its not waking up when i turn on my screen

Re: disconnected on lock

Posted: Thu Jan 02, 2014 1:06 am
by jamesyonan
Having the device blank the screen and go into a low-power state is essential to preserve battery life when the device is idle, and any VPN app would need to disconnect during this period.

OpenVPN Connect will always enter an inactive "pause" state while the device is in a low-power sleep state or when the network is unavailable.

James

Re: disconnected on lock

Posted: Thu Jan 02, 2014 11:44 am
by pkillpeers
Yes but isnt it supposed to reconnect when i start using my phone again? I turned on my screen, waited for 3 or 4 min and no connection, stays paused. Had to manually disconnect and connect again

Re: disconnected on lock

Posted: Thu Jan 02, 2014 9:55 pm
by jamesyonan
Yes, it should reconnect on wakeup.

Are you using WiFi or cellular data? Because there's a known bug that appears on iOS 7 where OpenVPN will remain paused after wakeup instead of reconnecting onto cellular data. It can happen on wakeup from sleep where cellular data is the active network, or on transitions from WiFi to cellular data. We're working with Apple to resolve it.

James

Re: disconnected on lock

Posted: Fri Jan 03, 2014 4:27 pm
by dbfellowes
Jamesyonan
Are you using WiFi or cellular data? Because there's a known bug that appears on iOS 7 where OpenVPN will remain paused after wakeup instead of reconnecting onto cellular data. It can happen on wakeup from sleep where cellular data is the active network, or on transitions from WiFi to cellular data. We're working with Apple to resolve it.
Ah, so it's not just me, clearly. Good to know. Would you be willing to provide us with a rough estimate on when you expect 1.0.4 to be released? This bug's basically taken out the most crucial feature for me, and for those of us living in third world police states, VPN's pretty much constantly on.

Re: disconnected on lock

Posted: Sat Jan 04, 2014 10:36 am
by pkillpeers
Thanks for the clarification. Im using celular data almost all time. It does reconnect when using wifi though. But on celular it just keeps pausing. Cant wait for the update then. :D
Cheers

Re: disconnected on lock

Posted: Sat Jan 04, 2014 6:18 pm
by jamesyonan
This issue should be fixed by OpenVPN 1.0.4 + iOS 7.1.

James

Re: disconnected on lock

Posted: Sun Jan 05, 2014 12:13 am
by anatoli
James, if the OVPN Client disconnects when the phone enters an inactive "pause" state in a low-power sleep, how push notifications are handled? Do they enter via unencrypted connection? If yes, is there any way to make absolutely all communications to and from the device via OVPN? If not, do you plan to add this feature? In many cases it's much more important to encrypt everything than to save battery.

Re: disconnected on lock

Posted: Wed Jan 08, 2014 6:29 am
by jamesyonan
OpenVPN basically tries to continue running as long as (a) a network connection is available, and (b) the device isn't sleeping. If the device is handling push notifications such as checking for email, the device may actually be awake and on the network, even though the display is blanked. In these situations, OpenVPN should be running as well.

Now to answer your question about "is there any way to make absolutely all communications to and from the device via OVPN" there is a feature that we plan to add in the future called "Seamless Tunnel" where once OpenVPN is connected it will block all traffic from leaving the device except through the OpenVPN tunnel, even if OpenVPN is in a paused state due to network transitions, reconnects, device sleep, etc. Because this feature requires support from the iOS VPN Framework, we're working with Apple to try to get this implemented.

James

Re: disconnected on lock

Posted: Fri Dec 27, 2019 7:46 am
by train_wreck
So, it's been almost 6 years since this was first mentioned. I'm still having this problem.

Will this ever be fixed???

Re: disconnected on lock

Posted: Mon Dec 23, 2024 9:00 am
by EvelynC93
Ugh, that's so annoying! It's like your iPhone is playing a game of hide-and-seek with your Wi-Fi. Here are a few things that might be causing this:-
Power Saving Mode:- When your iPhone goes into Power Saving Mode, it might disconnect from Wi-Fi to conserve battery. Check your Power Saving Mode settings and see if it's enabled.
Wi-Fi Assist:- This feature automatically switches your phone to cellular data when Wi-Fi is weak. It might be causing your phone to disconnect from Wi-Fi when the screen locks. Try turning off Wi-Fi Assist in your Settings.
Background App Refresh:- Some apps might be trying to refresh in the background, which can interfere with Wi-Fi connectivity. Try restricting background app refresh for some of your apps.
Router Settings:- Sometimes, your router's settings might be causing Wi-Fi disconnections. Try adjusting your router's settings, such as the channel or bandwidth.

If you have problem persist after trying these step, you can follow for more details instruction below.
https://thegeekpage.com/wi-fi-gets-disc ... ed-solved/