Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic back-up not working reliably #758

Open
rustyjarz opened this issue May 15, 2017 · 46 comments
Open

Automatic back-up not working reliably #758

rustyjarz opened this issue May 15, 2017 · 46 comments
Labels
backup related to backup schedule related to automatic scheduled backups
Milestone

Comments

@rustyjarz
Copy link

Hi - SMS autobackup doesn't seem to be happening on the latest version of Andriod (nougat). I really liked this feature, so if you could fix it that would awesome.

@GreenHex
Copy link

GreenHex commented May 24, 2017

I am having the same problem with v1.5.10 running on Android 5.1 (Meizu M3s).

"Regular schedule" and "Incoming schedule" give the following error: "isConnection failed; ENETUNREACH". However manual backup by pressing the button works perfectly.

@mhofman
Copy link

mhofman commented May 25, 2017

I think if you go to battery settings, battery optimizations, and set SMS Backup+ to "Not optimized" it will resume backing up automatically without delay.

@jasonab
Copy link

jasonab commented Oct 3, 2017

I have this problem as well, just changed the setting. Is there a code change that needs to be made here?

@rustyjarz
Copy link
Author

I've modified the power-saving features so this app is not 'optimised' for power saving, but hasn't fixed the problem.

@gaiuslove
Copy link

Problems lead to Solutions.

To get Android nougat to allow SMS backup to automatically backup, change this setting with these steps:

Settings, device maintenance, Battery, unmonitored apps, add apps, add "SMS Backup+" .

See screenshots to help assist you in this.

@gaiuslove
Copy link

It won't let me leave a screenshot. Okay. But you get the picture.

@rustyjarz
Copy link
Author

gaiuslove none of the settings labels you're referring to in your post marry up to the setting I have.

@gaiuslove
Copy link

I have Android 7.1.1, and that is the process by which my SMS backup's automatic backup started to work again.

@rustyjarz
Copy link
Author

gaiuslove any chance you could take the screenshots and put them in a document and share via dropbox or similar?

@gaiuslove
Copy link

Now it's letting me leave a screen shot. I'm on my laptop now, not on my phone as before:

screenshot_20171125-080651 1

@gaiuslove
Copy link

screenshot_20171125-080253 1

@jberkel
Copy link
Owner

jberkel commented Dec 20, 2017

Please try the new beta: https://github.com/jberkel/sms-backup-plus#beta

It should work without changes to the unmonitored apps configuration

@gaiuslove
Copy link

gaiuslove commented Dec 20, 2017 via email

@rustyjarz
Copy link
Author

gaiuslove if you read through the Beta Testing section of the page, it explains how to become a beta tester.

@jasonab
Copy link

jasonab commented Dec 20, 2017

@gaiuslove have you signed up for the beta program in Google Play? If so, it should push you an update soon (mine just showed up). If not, you need to scroll to the bottom of the app page in Play and click the sign up button.

@jberkel jberkel added this to the 1.5.11 milestone Mar 28, 2018
@jberkel jberkel added the backup related to backup label Mar 28, 2018
@jcrben jcrben added awaiting response awaiting response from reporter fixed in beta labels Mar 31, 2018
@jberkel jberkel modified the milestones: 1.5.11, 1.6.0 Apr 23, 2018
@jcrben jcrben removed awaiting response awaiting response from reporter fixed in beta labels Apr 24, 2018
@jcrben
Copy link
Collaborator

jcrben commented Apr 24, 2018

This has been added to the 1.6.0 milestone - I think the idea is to figure out how to ensure that the sleep doesn't affect the automatic backup.

@jberkel is that what you're thinking? I think we should update the title of this issue or fold it into a meta issue around this topic as this is just an unclear bug report

@jberkel
Copy link
Owner

jberkel commented Apr 24, 2018

@jcrben it looks like a duplicate issue and should be merged

@gaiuslove
Copy link

Google play just offered me the (once beta) 1.5.11 and I installed the update. When updating it, I also opted into the beta testing program. Has this (doesn't automatically back-up while phone is sleeping) bug been corrected in 1.5.11, (I guess I will soon see, as I now have 1.5.11), or will it be corrected in 1.6.0 ?

@kurahaupo kurahaupo added the schedule related to automatic scheduled backups label May 29, 2021
@mwisnicki
Copy link

FWIW It's been working for me so far on Samsung Galaxy Note 10+ with latest Android 11 after I've disabled battery optimizations.

@kurahaupo
Copy link
Collaborator

@mwisnicki Yes and it works for me too. Which makes it rather frustrating to diagnose the exact problem.

@madduck
Copy link

madduck commented Aug 5, 2021

Not working on LineageOS 18.1 (Android 11) on the OnePlus 5T, despite the app being "not optimized" for battery.

com.zegoggles.smssync is a running process, but it seems it never gets a chance to run, not in response to an incoming text, nor on a schedule. Been monitoring adb logcat *:S SMSBackup+:V k9:V for hours now, having received multiple text messages since I started.

Manual backups work. I am not using Google, of course not.

@kaistian
Copy link

It's also not working on CalyxOS 2.8.0 (Android 11) on a Pixel 5 with "not optimized"
Manual backups work fine to Dovecot IMAP server.

Just tried SMS Gate which is a fork of SMS Backup+ and it works, even when it's not set to "not optimized" yet.

So maybe look at the source there to get an idea how to fix the issue.

@Dubroamer
Copy link

Had same issue and battery optimization did not help but noticed in MOBILE DATA section I had allowed app run in the background but not while data saver was on. So would not back up automatically even when data saver was off but once I allowed this it backed up perfectly on its own.

@madduck
Copy link

madduck commented Oct 3, 2022

@Dubroamer Do you think this would have an effect even if I don't use datasaver? I've flicked it now, but so far have not been able to notice a difference.

@Dubroamer
Copy link

Perhaps. I never turned data saver on and I tried everything else without success before noticing that setting was on. Once I restarted the phone it backed up on its own

@sooyhwang
Copy link

I turned off the battery optimization and also turned on the mobile data setting that @Dubroamer mentioned above, but nothing happened (i.e. empty log). Then I turned on the "Old backup scheduler" option under "Auto backup settings" and the auto backups started to work! I had tried this old backup scheduler option before and it didn't work, so the combination of battery and background mobile data setting as well as the old scheduler option seem to have done the trick. Phone is Pixel 7 on Android 13.

@sooyhwang
Copy link

sooyhwang commented Dec 13, 2022

I spoke too soon. In addition to what I did above, the sync seems to work only when the sync log is enabled. If I turn off the sync log collection, syncing stops after about a day. Sync resumed once I turned on the log again. Has anyone noticed this?

@highfalutin
Copy link

highfalutin commented Dec 13, 2022 via email

@madduck
Copy link

madduck commented Dec 13, 2022

Same here, no automatic backups with or without log, neither on a schedule, nor on incoming SMS messages.

@mwisnicki
Copy link

Same here actually, it looks like it stopped working.
This time Samsung S22 Ultra / Android 13. Last scheduled backup ran in Nov 16 which might've been right before update to Android 13.

@voopoo
Copy link

voopoo commented Dec 21, 2022

Hi everyone I had this app working with Samsung note 9 and I bought a new phone s20+ android 13, after installing and configuring (imap/Outlook server) the manual sync would work but the auto sync just stood idle/never worked. After messing around I think I've fixed it by running the Samsung calendar stock app and letting it sync once. After they first sync the smsbackup+ autosync started working as it should. Hope this helps someone else. Cheers

@madduck
Copy link

madduck commented Dec 21, 2022

@voopoo Why would that fix it?

@voopoo
Copy link

voopoo commented Dec 21, 2022

I don't know, it triggered something? Wish I knew. This is what I remember doing: tried installing alternative apps (since this one wasn't auto syncing since day 1), like sms gate, call log calendar, calls & sms to calendar but I wasn't happy with any of them so I froze them with titanium backup and decided to reinstall/reconfigure sms backup+ again, I went to check calendar to see if my email was showing up/syncing and I saw an entry being added automatically, that's when I found out it was working and it has been since.

@marcellusca
Copy link

Hello,

I have a Google Pixel 5 running Android 13 Tiramisu with SMS Backup+ 1.5.11. I've already enabled unrestricted battery for the app and have no improvement as automatic backup does not run but manual backup does.
Any new developments and recommendations on the solution for this? Much appreciated.

@sshaikh
Copy link

sshaikh commented Jan 28, 2023

Pixel 6a and same issue, worked fine on previous handset.

@teezeuay
Copy link

my backup worked flawless on a samsung galaxy s9 for years with IMAP signin. 2 weeks ago the auto backup stopped. I regenerated a new password and restarted phone which worked last time. This time NO. I see in the past everyone said to use edge but I dont have the option to authenticate that way. I checked sleeping apps and battery settings which seem all correct. What am I missing. Manual backups work tho

@highfalutin
Copy link

@teezeuay you're not missing anything, the software isn't doing automatic backups for any of us

@teezeuay
Copy link

teezeuay commented Jan 31, 2023 via email

@voopoo
Copy link

voopoo commented Jan 31, 2023

I had same the problem and it's working for me (auto backup/incoming and manual - on Android 13) I just can't pin point what I did to fix it, I remember reinstalling the app from scratch and messed around with calendar and email app (Samsung apps in my case) Have you tried reinstalling and reconfiguring the sms+ again? I'm using plain auth on @outlook.com

@samej71
Copy link

samej71 commented Jan 31, 2023

I suspect the the latest round of breaks is related to the upgrade to Android 13. As a workaround, I think I am going to try to uninstall and reinstall in the hopes that there is something in the installation process that triggers granting permission to schedule/execute background jobs that isn't happening if the app is present during the upgrade.

@teezeuay
Copy link

teezeuay commented Jan 31, 2023 via email

@madduck
Copy link

madduck commented Jan 31, 2023

It has not been working for years now. I think it stopped working for me around Android 6 or 7. Nice if reinstalling works for you, but I think the problem is a different one from what can be solved with a reinstall.

@voopoo
Copy link

voopoo commented Feb 1, 2023

I mean I'm using plain text method for authentication (custom imap server options) and I'm using an outlook email to sync calls on calendar and sms on outlook email (sms folder) I ve been using this app for years and it's working, I recently bought an s20+ and at first the auto sync wasn't working but it is now

@samej71
Copy link

samej71 commented Feb 3, 2023

Update from previous comment: Uninstalling and reinstalling did not change anything for me (not surprising but wanted to rule it out).

I've been trying to dig a bit and found two things, which may or may not be significant, but to one of the contributing developers it might be useful:

  1. Despite the FOREGROUND_SERVICES in the manifest, when I view the permissions granted to the app, this permission is not listed, but it is also not listed in denied permissions. It is listed for another app I use (Automate), so it seems reasonable to think it would be listed for SMS Backup+, too. I'm not quite sure of the purpose of this permission yet, but it might be for ongoing notifications?

  2. In viewing debug logs, I see a log entry that I think correlates to a received SMS and is triggering the backup process:

[02-02 22:41:29.260 1691:2947 D/ActivityManager] Received SERVICE intent 0x3bc9d43 Key{startService pkg=com.zegoggles.smssync intent=act=INCOMING cmp=com.zegoggles.smssync/.service.SmsBackupService flags=0x0 u=0} requestCode=0 from uid 1000

But it is then followed by a fair number of messages that could be interpreted as errors. I suspect I am getting one for every SMS message it is trying to back up:

[02-02 22:41:33.827 6880:18142 D/k9] Got untagged EXISTS with value 12345 for com.zegoggles.smssync.mail.BackupStoreConfig@7a96900:SMS/AsyncTask #1/conn213609424

the value 12345 incremented by one for each message, like a counter or perhaps ID.

In researching this message, it appears to be part of the K9 email client, which at first made me concerned because I don't use this email client, but I then discovered it is also a email library that SMS Backup+ is using.

Even more interesting, is I see the backed up messages in my gmail from my tests just a few minutes ago, but the "last item backed up" timestamp in SMS Backup+ still shows the date/time of last manual backup which was three days ago.

I currently have the "legacy scheduler" option enabled, along with "sync log" and "extra debug information" options enabled.

When I view the sync log within SMS Backup+, I see (paraphrased, since typing a screenshot)

02-02 22:41 Backup requested (Incoming)
02-02 22:41 Starting backup (INCOMING)
02-02 22:41 Using config: BackupConfig{......lots of stuff not going to type....}
02-02 22:45 BackupState{...lots of stuff not going to type..., exception=null, state=FINISHED_BACKUP}
02-02 22:45 Backup finished

And now when I check the last backup in SMS Backup+, it shows Feb 02, 2023 10:39:57, slightly before the log entries, which I'm not sure how that figures... but it did actually execute for the first time today automatically and it hasn't done it since November last year.

One thing I did notice is the messages that were backed up appear to have odd threading, like there is a message thread of just the messages I've sent, and not inline with the messages I've received. I see other recently threads where both sides of the conversation are present.

I don't know if any of this information will be an "aha" for any developer, but here's to hoping.

@kurahaupo
Copy link
Collaborator

@samej71 thanks that's really helpful.

The threading mismatch is a known issue; the original version of Android always presented the "sender" and "recipient" in that order, but newer versions present them in random order, meaning that we need to look for the tags to see which is which.

Unfortunately I don't know if/when @jberkel is coming back, or if someone is going to fork the project and maintain it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backup related to backup schedule related to automatic scheduled backups
Projects
None yet
Development

No branches or pull requests