Syncthing remains sleeping when connected to WiFi

Syncthing doesn’t work on my parents phone when screen is off and then connected to charger. Not an issue if screen is still on before disconnecting.

However, if I disable “Run of specified Wi-FI networks” then it works. I’ve checked if regular 2.4GHz and 5GHz network was the issue but made no difference. I thought it was a battery optimization issue but this disproves it. Happens on Syncthing-Fork and Syncthing Android.

Only commonality of my parents device are that they are Xiaomi devices running MIUI 12 (Android 11). My phone however is also a Xiaomi (Mi 12X) and has zero issues. Pretty strange issue… any clue why this is or what can I do about it? I suppose it doesn’t really matter if they try to Sync on a public WiFi, since it wouldn’t connect to my local server.

The app isn’t being killed, it just won’t run if choose to “Run on specified Wi-FI networks”. It works when this option is disabled. Do WiFi network names relate to app optimization too?

The other typical reason is that location permissions aren’t granted and/or location is disabled (not entirely sure the latter is really required, I keep forgetting, and it might also depend on android version).

Location does need to be enabled, and it is enabled. Pretty sure location permissions are granted, but I would check again, could be something about allowing gps only while app is being used.

Yep that, or android removed the permission - at least for me it started doing that. Though I’d expect it wouldn’t if syncthing “uses” the permission regularly, but one never knows.


Same issue here.

Localisation permissions granted (permanently), no battery optimization. It should wake up when the phone is connected to 2 specified wifi networks. Sometimes the phone is connected but it seems like ST doesn’t reconize them.

Samsung Galaxy S22 Ultra (SM-S908B/DS) with android 13.

not sure if i fixed it, but i found a deeper permission settings, to Allow all the time instead of when Only when app is open. Anyway i just turned off Specified Wifi networks, and turned on CPU wakelock now it works fine

Hi HansLau

That’s what i mean when i say “Localisation permissions granted (permanently)”. Sorry but english isn’t my native language and mine is poor. Anyway, this option is on “allow all the time”.

What is “CPU wakelock” option? My GUI is in french and i don’t see that.

Thank’s for your response.

CPU wakelock option is not recommended, but i need it for my dads phone. Only available on the origianl Syncthing android, not Syncthing-fork (on fork, only Android 5 below can use it).

Ok. I use the F-Droid app, doesn’t seem to me it’s a fork but maybe it’s one…

This issue appears randomly, today i went away and came back home, no issue. Just now i turned wifi off then on, no issue. Wait and see…

Thank you HansLau.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.