[GH-ISSUE #954] Automatic backup not worked for about a year #754

Closed
opened 2026-02-26 01:31:32 +03:00 by kerem · 14 comments
Owner

Originally created by @turkeyphant on GitHub (Apr 30, 2019).
Original GitHub issue: https://github.com/jberkel/sms-backup-plus/issues/954

Expected behaviour

Automatic backup to work according to regular schedule and post-receipt schedule settings.

Actual behaviour

Only manual backups work.

Steps to reproduce the behaviour

Set automatic backup to every 30 mins and receipt backup to 1 min after receiving a new SMS.

Receive an SMS/wait 1 hour.

No backup since last manual backup.

Last time it attempted an automatic backup was in August and then even after 34 SMS and 48 calls were logged, it did not do another automatic backup and I had to trigger it manually.

12-08 02:58 Backup requested (incoming)
12-08 02:58 Starting backup (INCOMING)
12-08 02:58 Skipped (no items found)
12-08 02:58 BackupState{currentSyncedItems=0, itemsToSync=0, backupType=INCOMING, exception=null, state=FINISHED_BACKUP}
12-08 02:58 Backup finished
12-08 12:29 Backup requested (regular)
12-08 12:29 Starting backup (REGULAR)
12-08 12:29 Skipped (no items found)
12-08 12:29 BackupState{currentSyncedItems=0, itemsToSync=0, backupType=REGULAR, exception=null, state=FINISHED_BACKUP}
12-08 12:29 Backup finished
23-08 14:15 Backup requested (manual)
23-08 14:15 Starting backup (MANUAL)
23-08 14:15 Backing up (34 SMS, 0 MMS, 48 call log)
23-08 14:15 Using config: BackupConfig{imap=BackupImapStore{uri=imap+ssl+://XOAUTH2:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX@imap.gmail.com:993}, currentTry=0, maxItemsPerSync=-1, groupToBackup=ContactGroup{_id=-1, type=EVERYBODY}, backupType=MANUAL, debug=true, typesToBackup=[SMS, MMS, CALLLOG]}
23-08 14:15 need to perform xoauth2 token refresh
23-08 14:15 token refreshed, retrying
23-08 14:15 Backing up (34 SMS, 0 MMS, 48 call log)
23-08 14:15 Using config: BackupConfig{imap=BackupImapStore{uri=imap+ssl+://XOAUTH2:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX@imap.gmail.com:993}, currentTry=1, maxItemsPerSync=-1, groupToBackup=ContactGroup{_id=-1, type=EVERYBODY}, backupType=MANUAL, debug=true, typesToBackup=[SMS, MMS, CALLLOG]}
23-08 14:17 BackupState{currentSyncedItems=82, itemsToSync=82, backupType=MANUAL, exception=null, state=FINISHED_BACKUP}
23-08 14:17 Backup finished

Please specify the following:

  • Android version 7.0
  • Phone model / brand LG G5 (LH-H850)
  • SMS Backup+ version installed 1.5.11
  • Messaging app hello
Originally created by @turkeyphant on GitHub (Apr 30, 2019). Original GitHub issue: https://github.com/jberkel/sms-backup-plus/issues/954 ### Expected behaviour Automatic backup to work according to regular schedule and post-receipt schedule settings. ### Actual behaviour Only manual backups work. ### Steps to reproduce the behaviour Set automatic backup to every 30 mins and receipt backup to 1 min after receiving a new SMS. Receive an SMS/wait 1 hour. No backup since last manual backup. Last time it attempted an automatic backup was in August and then even after 34 SMS and 48 calls were logged, it did not do another automatic backup and I had to trigger it manually. ``` 12-08 02:58 Backup requested (incoming) 12-08 02:58 Starting backup (INCOMING) 12-08 02:58 Skipped (no items found) 12-08 02:58 BackupState{currentSyncedItems=0, itemsToSync=0, backupType=INCOMING, exception=null, state=FINISHED_BACKUP} 12-08 02:58 Backup finished 12-08 12:29 Backup requested (regular) 12-08 12:29 Starting backup (REGULAR) 12-08 12:29 Skipped (no items found) 12-08 12:29 BackupState{currentSyncedItems=0, itemsToSync=0, backupType=REGULAR, exception=null, state=FINISHED_BACKUP} 12-08 12:29 Backup finished 23-08 14:15 Backup requested (manual) 23-08 14:15 Starting backup (MANUAL) 23-08 14:15 Backing up (34 SMS, 0 MMS, 48 call log) 23-08 14:15 Using config: BackupConfig{imap=BackupImapStore{uri=imap+ssl+://XOAUTH2:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX@imap.gmail.com:993}, currentTry=0, maxItemsPerSync=-1, groupToBackup=ContactGroup{_id=-1, type=EVERYBODY}, backupType=MANUAL, debug=true, typesToBackup=[SMS, MMS, CALLLOG]} 23-08 14:15 need to perform xoauth2 token refresh 23-08 14:15 token refreshed, retrying 23-08 14:15 Backing up (34 SMS, 0 MMS, 48 call log) 23-08 14:15 Using config: BackupConfig{imap=BackupImapStore{uri=imap+ssl+://XOAUTH2:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX@imap.gmail.com:993}, currentTry=1, maxItemsPerSync=-1, groupToBackup=ContactGroup{_id=-1, type=EVERYBODY}, backupType=MANUAL, debug=true, typesToBackup=[SMS, MMS, CALLLOG]} 23-08 14:17 BackupState{currentSyncedItems=82, itemsToSync=82, backupType=MANUAL, exception=null, state=FINISHED_BACKUP} 23-08 14:17 Backup finished ``` ### Please specify the following: * Android version 7.0 * Phone model / brand LG G5 (LH-H850) * SMS Backup+ version installed 1.5.11 * Messaging app hello
kerem 2026-02-26 01:31:32 +03:00
Author
Owner

@srauco commented on GitHub (May 8, 2019):

I have the same issue. It will manually backup, and says it's scheduled for the next increment, but never fires.

Android 9
Pixel 3
1.5.11
Stock Android Messenger

<!-- gh-comment-id:490690382 --> @srauco commented on GitHub (May 8, 2019): I have the same issue. It will manually backup, and says it's scheduled for the next increment, but never fires. Android 9 Pixel 3 1.5.11 Stock Android Messenger
Author
Owner

@MaKali42 commented on GitHub (May 24, 2019):

I've been having the same problem since the beginning of 2019 with the backup schedule not initiating but manual working just fine. I've checked all settings for both the app and phone, tried different schedules, and made sure everything is up to date.
Android 7.0
Note5
1.5.11
Stock messenger

<!-- gh-comment-id:495725834 --> @MaKali42 commented on GitHub (May 24, 2019): I've been having the same problem since the beginning of 2019 with the backup schedule not initiating but manual working just fine. I've checked all settings for both the app and phone, tried different schedules, and made sure everything is up to date. Android 7.0 Note5 1.5.11 Stock messenger
Author
Owner

@kwinz commented on GitHub (Jun 15, 2019):

I have the same problem. Galaxy S7. Stock Android 8.0
SMS backup is in the Doze "do not optimize"app exception list.
And also in the Samsung "don't put to sleep" list.
But still only manual backups work.

<!-- gh-comment-id:502404288 --> @kwinz commented on GitHub (Jun 15, 2019): I have the same problem. Galaxy S7. Stock Android 8.0 SMS backup is in the Doze "do not optimize"app exception list. And also in the Samsung "don't put to sleep" list. But still only manual backups work.
Author
Owner

@wuxxin commented on GitHub (Aug 7, 2019):

also affected: Google Pixel with Lineage 16 (Android 9), SMS Backup+ from fdroid Version 1.5.11
what is working: start manual backup
what is not working: automatic Backup (but selected)
what is greyed out: "Connect" (Verbinden in German) can not be selected
probably a duplicate: #957

<!-- gh-comment-id:519096282 --> @wuxxin commented on GitHub (Aug 7, 2019): also affected: Google Pixel with Lineage 16 (Android 9), SMS Backup+ from fdroid Version 1.5.11 what is working: start manual backup what is not working: automatic Backup (but selected) what is greyed out: "Connect" (Verbinden in German) can not be selected probably a duplicate: #957
Author
Owner

@kurahaupo commented on GitHub (Apr 26, 2020):

To confirm whether this is power-related, does your phone have the option to "never sleep while charging"? If so, turn that on, leave it on the charger, send it a message from another phone, and then let us know whether any automatic backup occurs.

Obviously that's not a permanent solution, but it helps by ruling out possible causes.

<!-- gh-comment-id:619487311 --> @kurahaupo commented on GitHub (Apr 26, 2020): To confirm whether this is power-related, does your phone have the option to "never sleep while charging"? If so, turn that on, leave it on the charger, send it a message from another phone, and then let us know whether any automatic backup occurs. Obviously that's not a permanent solution, but it helps by ruling out possible causes.
Author
Owner

@wuxxin commented on GitHub (Apr 26, 2020):

i only found "do not put display to sleep while charging", which was off, and i will switch it on for a test run. Also i put sms backup in the list of "non optimized" battery applications.
i will write tommorrow if anything of these two settings changed something

<!-- gh-comment-id:619520460 --> @wuxxin commented on GitHub (Apr 26, 2020): i only found "do not put display to sleep while charging", which was off, and i will switch it on for a test run. Also i put sms backup in the list of "non optimized" battery applications. i will write tommorrow if anything of these two settings changed something
Author
Owner

@kurahaupo commented on GitHub (Apr 27, 2020):

thanks, I await your findings.

<!-- gh-comment-id:619786119 --> @kurahaupo commented on GitHub (Apr 27, 2020): thanks, I await your findings.
Author
Owner

@turkeyphant commented on GitHub (Apr 27, 2020):

I don't have that option. Just checked the app and it hadn't updated since October 2019. Running manually worked fine.

<!-- gh-comment-id:619810147 --> @turkeyphant commented on GitHub (Apr 27, 2020): I don't have that option. Just checked the app and it hadn't updated since October 2019. Running manually worked fine.
Author
Owner

@wuxxin commented on GitHub (Apr 27, 2020):

none of the settings did make sms backup execute the backup. i pushed the manual backup button right now, and (as expected) it backed up my calls and sms from last day.

<!-- gh-comment-id:619861248 --> @wuxxin commented on GitHub (Apr 27, 2020): none of the settings did make sms backup execute the backup. i pushed the manual backup button right now, and (as expected) it backed up my calls and sms from last day.
Author
Owner

@kurahaupo commented on GitHub (May 7, 2020):

It's worth noting that the majority of scheduling failures are related to power management.

It would help diagnostic efforts if everyone could check whether or not bypassing power management fixes each problem. The easiest way to do that it to enable "keep screen on when charging" and put the phone on charge; then send a test message, and wait.

<!-- gh-comment-id:625018767 --> @kurahaupo commented on GitHub (May 7, 2020): It's worth noting that the majority of scheduling failures are related to power management. It would help diagnostic efforts if everyone could check whether or not bypassing power management fixes each problem. The easiest way to do that it to enable "keep screen on when charging" and put the phone on charge; then send a test message, and wait.
Author
Owner

@turkeyphant commented on GitHub (May 7, 2020):

Just tried that and no dice. MightyText started syncing immediately though.

<!-- gh-comment-id:625243414 --> @turkeyphant commented on GitHub (May 7, 2020): Just tried that and no dice. MightyText started syncing immediately though.
Author
Owner

@kurahaupo commented on GitHub (May 11, 2020):

@turkeyphant, @wuxxin thanks for doing that.

<!-- gh-comment-id:626813758 --> @kurahaupo commented on GitHub (May 11, 2020): @turkeyphant, @wuxxin thanks for doing that.
Author
Owner

@kurahaupo commented on GitHub (Jun 12, 2021):

I should have said sooner, the next thing is to enable and upload the debug log, so we can see whether SMS Backup+ is waking up but failing to sync, or not waking up.

If you are still having this problem (that is, manual backup works, but automatic backups do not) please:

  1. enable the debug log
  2. wait until the next time you notice it's failed to automatically back up a message
  3. add a comment to this ticket:
    • uploading your log (preferably as a file, not an image); AND
    • stating whether the device was apparently on WiFi, or on mobile data, or disconnected (which icons are in the status tray); AND
    • stating whether the device was awake with SMS Backup+ in the foreground, awake but doing something else, or asleep; AND
    • describing if and how any of those changed over the time covered by the log; AND
    • as always, the device & OS version

My suspicion is that on some phones, apps can be woken up but WiFi and/or mobile data might still be in "low power" mode and therefore not immediately unavailable, and that "try again in 5 seconds" might resolve the problem.

Another possibility is that the phone's security system doesn't want to let any background apps initiate direct TCP connections (instead of known APIs) "because malware blah blah", but isn't telling anyone.

It would also be really helpful if you have access to intercept WiFi data (tcpdump on your router?) and can check whether there's an outgoing TCP SYN to port 143 or 993 and a return SYN/ACK, at the time when the log indicates that it wakes up and attempts (but fails) to initiate an IMAP connection.

Also very useful would be if use your own IMAP server and can compare logs from both ends.

<!-- gh-comment-id:859993295 --> @kurahaupo commented on GitHub (Jun 12, 2021): I should have said sooner, the next thing is to enable and upload the debug log, so we can see whether `SMS Backup+` is waking up but failing to sync, or not waking up. If you are still having this problem (that is, manual backup works, but automatic backups do not) please: 1. enable the debug log 2. wait until the next time you notice it's failed to automatically back up a message 3. add a comment to this ticket: * uploading your log (preferably as a file, not an image); AND * stating whether the device was apparently on WiFi, or on mobile data, or disconnected (which icons are in the status tray); AND * stating whether the device was awake with SMS Backup+ in the foreground, awake but doing something else, or asleep; AND * describing if and how any of those changed over the time covered by the log; AND * as always, the device & OS version My suspicion is that on some phones, apps can be woken up but WiFi and/or mobile data might still be in "low power" mode and therefore not immediately unavailable, and that "try again in 5 seconds" might resolve the problem. Another possibility is that the phone's security system doesn't want to let any background apps initiate direct TCP connections (instead of known APIs) "because malware blah blah", but isn't telling anyone. It would also be really helpful if you have access to intercept WiFi data (tcpdump on your router?) and can check whether there's an outgoing TCP SYN to port 143 or 993 and a return SYN/ACK, at the time when the log indicates that it wakes up and attempts (but fails) to initiate an IMAP connection. Also very useful would be if use your own IMAP server and can compare logs from both ends.
Author
Owner

@kurahaupo commented on GitHub (Jul 8, 2021):

Thanks everyone for the feedback.

Using the new Oreo JobScheduler API is on the roadmap.

I'm marking this as a duplicate of #758 just so we can track one issue and keep all the feedback in one place.

<!-- gh-comment-id:876798928 --> @kurahaupo commented on GitHub (Jul 8, 2021): Thanks everyone for the feedback. Using the new Oreo JobScheduler API is on the roadmap. I'm marking this as a duplicate of #758 just so we can track one issue and keep all the feedback in one place.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/sms-backup-plus-jberkel#754
No description provided.