MozillaZine

Android Firefox: Sync stopped working, doesn’t update

Talk about Mozilla browsers for small devices such as PDAs and cellphones.
Noc1
 
Posts: 8
Joined: February 27th, 2017, 8:00 pm

Post Posted February 27th, 2017, 8:07 pm

I hop this is the right place to ask about a problem with Firefox for Android; I didn’t see any Android/mobile-specific section.

Earlier I noticed that my Android Firefox Sync had stopped working for the last few days; it said “Last updated: 5 days ago” under the Synced devices → History tab. It had worked without issue until then. Swiping down to update does nothing; the “busy” circle animation appears for a moment, then disappears without updating anything; the “last updated” timestamp is unchanged. When I go to Settings → (Account) and tap “Sync now”, the “last updated” timestamp there might change, but back under my History tab my synced tabs haven’t updated at all.

My Firefox for Android is already at the latest version. I’ve tried uninstalling it and reinstalling from scratch, but that changed nothing at all.

The only workaround I’ve found is to disconnect my Android Firefox and reconnect; this will sync tabs the first time, but subsequent syncs still don’t work. Because of this I now have four instances of my phone’s Firefox profile under “Synced devices”.

Any help would be greatly appreciated.

Device: Asus ZenFone 3 (ZE552KL)
OS: Android 6.0.1
Firefox version: 51.0.3

DanRaisch
Moderator

User avatar
 
Posts: 117379
Joined: September 23rd, 2004, 8:57 pm
Location: Somewhere on the right coast

Post Posted February 27th, 2017, 8:18 pm

Moving to Mobile.

JanH
 
Posts: 102
Joined: March 23rd, 2011, 1:19 pm

Post Posted March 1st, 2017, 4:56 am

Small note on the side: Pulling down to refresh from the history panel only refreshes the tabs list, so to force a sync for everything you do indeed have to go into the Accounts menu.

That apart, is everything else you might sync (like bookmarks, history, send tab to device, ...) still working normally? If it's only tab sync that is affected, this sounds suspiciously like my case in bug 1342679 - I think that tab sync stopped working properly approximately around the same time for me - some time last Thursday or Friday.

Noc1
 
Posts: 8
Joined: February 27th, 2017, 8:00 pm

Post Posted March 1st, 2017, 5:03 am

JanH wrote:That apart, is everything else you might sync (like bookmarks, history, send tab to device, ...) still working normally?

Nope, nothing syncs at all for me, either by pulling down or forcing a sync from the Accounts menu. As I said, I can force a one-time sync by disconnecting my Android Firefox Sync account, then reconnecting it; it’ll sync once and get up to date, but it won’t sync after that. (To be clear, I’ve checked that Auto-Sync and other related settings are all normal.) It really just stopped working out of the blue sometime last week.

Noc1
 
Posts: 8
Joined: February 27th, 2017, 8:00 pm

Post Posted March 2nd, 2017, 2:09 am

Update! I just noticed something interesting: Tabs still don’t sync, but when I launch a manual full sync from the Accounts menu, it does sync my browser history between my PC and Android Firefox. I just tried it, and pages I’d just visited minutes ago with my PC Firefox appeared on my Android Firefox, even though the tabs still haven’t updated (and the “Last updated” timestamp hasn’t changed, either). However, I can’t be sure if this is a new development, or if I was always able to sync history this way.

JanH
 
Posts: 102
Joined: March 23rd, 2011, 1:19 pm

Post Posted March 4th, 2017, 9:37 am

You could try installing the About Sync add-on and check whether - if necessary after forcing a manual sync on desktop or mobile - the Tabs collection contains the expected tabs (look in the "Records (object)" tab). If yes, that means that Firefox is still successfully uploading your tabs.

You could then check the "Response" tab and see whether any of the time fields change after syncing (and reloading the About Sync page) from either desktop or mobile.
If you're in the same situation as me, then "date" and "x-weave-timestamp" will change, but "x-last-modified" will stay unchanged, which is why you don't see any new tabs appearing - Firefox thinks they haven't changed and therefore doesn't request any updates.

Noc1
 
Posts: 8
Joined: February 27th, 2017, 8:00 pm

Post Posted March 4th, 2017, 3:29 pm

Thanks for the tip. I’ve installed About Sync and confirmed a few things:

1) Under “Records (object)”, tabs from my PC Firefox are uploading when I manually sync my browser.

2) Under “Response”, the “date” and “x-weave-timestamp” fields (for my PC Firefox) do update after I manually sync my browser.

3) Indeed, the “x-last-modified” field does not update after syncing.

4) On Android Firefox, I tested whether open tabs uploaded to my sync account (opened YouTube.com in a tab, then manually ran sync through the Accounts menu). I then refreshed About Sync on my PC and checked Tabs → Records (object) → the “Object” entry for my Android Firefox device, and saw that the YouTube tab was not there. I understand this means my Android Firefox isn’t uploading its tabs?

Additionally (and I kept forgetting to mention this), I don’t know if this is relevant, but since this problem began, I’ve experienced difficulties logging in to my Firefox Sync account whenever I disconnected my Android Firefox device from my account and reconnected it.
» First, upon trying to reconnect I would receive some error messages (usually “No Internet connection”, despite my phone being perfectly connected), which would eventually go away after a reload or two.
» Then, after logging in, under the Accounts menu, a red warning would state that my account isn’t verified (which it is) and asked me to tap to resend a verification email. Tapping simply opened up my Firefox Accounts page (https://accounts.firefox.com/settings); nothing else happened, and I didn’t receive any verification email.
» After a few minutes, the “unverified account” warning disappears and sync would start working again, syncing all history and tabs up to that point. This is the only time syncing my devices works as expected; trying afterwards doesn’t sync my tabs, as previously described.

JanH
 
Posts: 102
Joined: March 23rd, 2011, 1:19 pm

Post Posted March 5th, 2017, 4:34 am

Okay, so the desktop side sounds similar to bug 1342679. To get further with what is happening on your phone, we need to look at the logs.

You can use ADB (get it from here if you don't already have it), or else try installing the Log View add-on on your phone. I think that using ADB would be slightly preferred, since if I remember correctly, the Log View add-on doesn't show quite as much log entries going back. You then need to look for log entries from "FxAccounts".

If you're using ADB, use the following command line:
Code: Select all
Windows:
adb logcat -dv threadtime | findstr FxAccounts > sync.log

Linux/Mac:
adb logcat -dv threadtime | grep FxAccounts > sync.log


Then, add or close a few tabs, try to trigger a sync and get the logs afterwards. The same thing applies for capturing what is going on when you're having difficulties logging in.

Noc1
 
Posts: 8
Joined: February 27th, 2017, 8:00 pm

Post Posted March 5th, 2017, 2:55 pm

I’ll preface this by saying I know nothing about programming or debugging, so this is stretching the limits of my know-how.

I tried using ADB first (more below), but I don’t think I got it working right. I then tried the LogView add-on: I manually synced, then opened about:logs and published the resultant log to Pastebin: https://pastebin.mozilla.org/8981121

As for ADB: I downloaded it from here to my desktop, then enabled USB debugging on my phone, launched adb.exe manually (double-clicking it did nothing), started the daemon, then pasted the command line you quoted (“adb logcat -dv threadtime | findstr FxAccounts > sync.log”). It generated an empty “sync.log” in the “platform-tools” directory.

I then opened a couple new tabs on my PC Firefox, ran sync, then ran sync on my Android Firefox (under the Accounts menu as always). I then ran the command line again, and it generated another empty (0 bytes) “sync.log” file.

Since the log file is empty, I’m guessing I’m doing one or several things wrong, though I have no idea what – as I said, I have no knowledge of this stuff.

JanH
 
Posts: 102
Joined: March 23rd, 2011, 1:19 pm

Post Posted March 6th, 2017, 11:59 am

No problem and thanks for taking the time.

I'm not quite sure why ADB wouldn't work, but since the add-on is working fine, it doesn't matter. So if you ever encounter any strange problems like
Noc1 wrote:» First, upon trying to reconnect I would receive some error messages (usually “No Internet connection”, despite my phone being perfectly connected), which would eventually go away after a reload or two.
» Then, after logging in, under the Accounts menu, a red warning would state that my account isn’t verified (which it is) and asked me to tap to resend a verification email. Tapping simply opened up my Firefox Accounts page (https://accounts.firefox.com/settings); nothing else happened, and I didn’t receive any verification email.
» After a few minutes, the “unverified account” warning disappears and sync would start working again, syncing all history and tabs up to that point. This is the only time syncing my devices works as expected; trying afterwards doesn’t sync my tabs, as previously described.
run the add-on immediately afterwards to get some logs of this.

Also, if you open/close a few tabs on your phone and sync afterwards, you can check what it's saying for tab sync - normally, the next sync afterwards should say something like "Stage tabs received 0 and sent 1 records in x seconds".

As for the log you've posted, if you look through it, you'll see that when it's trying to sync history, you get an HMACVerificationException. That's bug 1343414 and apparently it's something that normally shouldn't be able to happen. Unfortunately, the only fix is to reset your sync account (disconnect all devices, either delete and recreate the account or else reset the password and subsequently choose a different one, then reupload everything from one Desktop instance [1] and reconnect everything else again afterwards).

Unfortunately it probably won't help with tab sync, though - I've encountered the HMAC problem as well and had to reset my sync account and sadly the tab syncing problem persisted. We'll just have to wait for some movement on bug 1342679.

[1] From the About Sync add-on, you can temporarily turn on "Create log files even on success?" to see when the initial sync from Desktop has finished. Just remember to switch it back off afterwards.

Edit: Correction - rnewman helpfully pointed out that disabling history sync, waiting a bit and then re-enabling it should be enough to fix that.

Noc1
 
Posts: 8
Joined: February 27th, 2017, 8:00 pm

Post Posted March 6th, 2017, 4:46 pm

I followed what you said and seem to have fixed the HMAC issue – disabled History syncing (in both my PC and Android FF), synced, waited a couple hours, then re-enabled History and re-synced both. I Ctrl+F’d for “HMACVerificationException” in the new logs and it isn’t there, so I’m guessing that’s resolved.

As expected, it didn’t do anything for the synced tabs issue. I’m Googling around and I can’t find many mentions of others having the same problem with Android Firefox. I wonder what specific circumstances trigger it – after all, syncing tabs worked just fine for months until it suddenly stopped out of the blue.

Noc1
 
Posts: 8
Joined: February 27th, 2017, 8:00 pm

Post Posted March 7th, 2017, 7:11 pm

Okay, so I updated both my desktop and Android Firefox to the newer version, and Sync has utterly died. Just flat-out dead. So that’s nice.

Updated my PC FF first; first thing I noticed was the “send tab to” option when you right-click a tab (I had enabled it in about:config) had disappeared. Then I noticed that the sync button in the right-hand menu had stopped working; clicking on it did nothing at all, it didn’t even animate. Tools → Sync Now also did bupkes. Everything appeared normal under the Preferences → Sync tab, but syncing completely stopped working. The About Sync add-on also stopped working; I checked that it’s still installed just fine, but its Tools menu entry is gone and pasting “chrome://aboutsync/content/index.html” in a new tab just gives me a permanent “Fetching account…” message with no other info.

I then updated my Android Firefox, and its sync died as well. Before, I could still sync history, passwords & etc. even if tabs didn’t sync, but now when I tap “Sync now” in the accounts menu, it says “Syncing…” for a moment, but the “Last synced: never” timestamp doesn’t change, and the history doesn’t update.

I tried a few things, including disconnecting and reconnecting both devices; nothing worked. I even deleted my entire Firefox account and created a new one with a different password, then reconnected both devices, but sync still doesn’t work. Here’s the latest from LogView.

I’m wondering whether I should create a new thread since this issue just got a lot bigger than tabs failing to sync.

JanH
 
Posts: 102
Joined: March 23rd, 2011, 1:19 pm

Post Posted March 8th, 2017, 1:10 am

It's getting 503 errors, so it's probably server problems, not your browser. Coincidentally the tab sync problem was server-side as well and should be fixed now.

Noc1
 
Posts: 8
Joined: February 27th, 2017, 8:00 pm

Post Posted March 8th, 2017, 1:14 am

Bellissimo! Indeed, everything is working now, including tab sync. All’s good.

Thanks for the help, it’s much appreciated. :)

cenon415
New Member
 
Posts: 1
Joined: January 28th, 2017, 3:57 pm

Post Posted June 19th, 2017, 5:59 pm

I'm currently having this problem at the moment. I have tried everything that was mentioned on this thread. Are there any other solutions that may fix this problem?

Return to Mobile


Who is online

Users browsing this forum: No registered users and 1 guest