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

tbsync office 365 account vanishes periodically from account list (totally erased account list) #632

Open
JJ-Author opened this issue Nov 15, 2022 · 19 comments

Comments

@JJ-Author
Copy link

JJ-Author commented Nov 15, 2022

Your environment

TbSync version: 4.3
Thunderbird version: 102.4.2 (64-Bit) - Ubuntu
Provider for EAS: 4.1.5

Expected behavior

tbsync should not delete or forget about accounts that I added

Actual behavior

tbsync shows an empty accounts list (i.e. missing the office 365 account that I added to sync the calendar)
Moreover Thunderbird renamed the tbsynced office365 calendars to "disconnected"

Steps to reproduce

This behavior happend already 2 times in the last 4 weeks. But I do not know what triggered it. I know the this morning TB showed the office365 calendars as "deactivated" out of nothing. I activated them by clicking on the grey button next to them but now they are "disconnected" and the accounts are gone.

To help resolving your issue, enable debug logging (TbSync Account Manager -> Help) and send me the debug.log via e-mail (use the title of your issue as subject of the email).

What logging level do you need? Will send log when it occurs the next time.

@jobisoft
Copy link
Owner

Did you clone your profile with already set up tbsync account and use the cloned profile elsewhere as well? If the account list returned by the server suddenly no longer includes a resource, tbsync is not deleting the local synced copy, but disconnects it from the sync for you to inspect. For WHY your server returns a wrong resource list from time to time, I do not know. Cloned profiles could be a cause.

@JJ-Author
Copy link
Author

JJ-Author commented Nov 15, 2022

I do not know what you exactly mean by profile (maybe it is the same as "account" and this is a translation confusion since I am using the german version and "Konto" translates back to English as "account")
I created the account from the scratch using the add new account button.
I mean these accounts here
image
This list was just blank after the calendars were reported as disconnected. It is a regular office 365 subscription hosted on the cloud so there is no "server" involved on my side.

@JJ-Author JJ-Author changed the title tbsyncs forgets office 365 accounts after a while (or just erases/loses accounts list) tbsync forgets office 365 accounts after a while (or just erases/loses accounts list) Nov 15, 2022
@JJ-Author
Copy link
Author

and it happened again. I did not change anything at the config. But I remember that the pc had a hard reset since it went out of battery.
image

I also recognized that it seems that the debug log is not persisted and might therefore be useless. Sent it anyhow as requested.

Let me know if I can help to further debug this issue (e.g. install a development version with a debugging fix of the tool)
I would recommend to persist the log otherwise it could be hard to get more insight here.

The situation reminds me of a configuration corruption problem I've seen in the past. So is there a chance that the hard reset occured while the config was rewritten in place without having a backup?

@JJ-Author
Copy link
Author

JJ-Author commented Nov 28, 2022

the account disappeared again this morning
i attached the debug.log nothing suspicious in there
but a picture with timestamps of the extension config files maybe that helps
image

0 bytes file for accounts does not look good to me. I recognized that this file is re-written every minute once I have reconfigured the account againg (I have sync time with 1 minute)
I think this is the cause of the issue - something with accounts writing routine is not right (maybe the file is not closed properly)

@jobisoft
Copy link
Owner

Is there something monitoring this folder, which could prevent TbSync from writing to it? Could you check if your AV solution (if any) could be configured to not touch your profile folder? What else could you think of which could interfere?

FYI: This is one of the things which will be removed with the next big version of TbSync: I will use the dedicated WebExtension storage, instead of writing files.

@JJ-Author
Copy link
Author

Thanks for the quick reply. I can not think of anything (I do not have any AV tool). I see a correlation between the instant turnoff/ improper shutdown of the notebook.

I did not find any note on write atomicity/consistency level of WebExtensions storage, but I would assume that this storage mechanism can handle OS crashes and sudden battery drops and is likely to resolve the issue.

Is there any rough timeline when this new version could be released?

@snowbird25
Copy link

I confirm above stated behavior. Tbsync has to be disabled and re-enabled in order to sync properly again. After shutting down PC and restarting TbSync loses connection again and disabling and re-enabling solves the issue again. Maybe this could be fixed in the next release? Thanks.

@JJ-Author
Copy link
Author

@snowbird25 you might have a different problem. In my case the account from the tbsync account list is gone. disabling and re-enabling the extension does not bring the account back for me.

@DerXteMensch
Copy link

I also already had the same problem as @JJ-Author. I'm not sure but I had the feeling this happened with a bad/not existing internet connection. I then also had to add the account once again. And to delete the calendars with lost connection.

@writemusic
Copy link

I also have the same problems as @JJ-Author. More or less every day when I launch Thunderbird, TBSync has "forgotten" the calendar connection to our on-premises Exchange 2016. Tasks usually still sync. In order to even see the Calendar resource, I need to uncheck "Enable and synchronize this account" and then activate it again. The calendar option returns and I can sync again.

@OneTwoBarbecue
Copy link

I can confirm this behaviour. Unfortunatley I have the same problem which also can be resolved the way writemusic describes it. I will enable logging and see if I can further nail down the issue. Always disabling and reenabling the Calendar resources which then have forgotten their colors is a little bit annoying.

@writemusic
Copy link

It seems to happen because I am using Thunderbird on multiple computers (laptop and desktop). It is possible that this occurs only if both instances happen to sync at the same time, but I am not certain.

@OneTwoBarbecue
Copy link

I am using Thunderbird only on one single computer - however I do sync via exchange to multiple devices. Behaviour persists.

@OneTwoBarbecue
Copy link

OneTwoBarbecue commented Oct 10, 2023

Hi,

I'm still facing the problem with TB 115.3.1 (64bit) and TbSync 4.7 and Exchange Proder 4.7.

It seems that TbSync performs a complete resync of the calender thus erasing it completely. Only deactivating synchronisation and again reactivating it makes the corresponding calender reappear.

The corresponding log shows:
``

** Tue Oct 10 2023 11:34:50 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: send.request.remotechanges, Account: Schulkonto, Folder: Kalender

** Tue Oct 10 2023 11:34:50 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[Sending (EAS v14.0)] : POST https://kopano.gymnasium-ettenheim.de/Microsoft-Server-ActiveSync?Cmd=Sync&User=ho&DeviceType=TbSync&DeviceId=MZTB603f29339ba1ab3fa4e692e1e347

** Tue Oct 10 2023 11:34:50 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[wbxml status check] : Sync: Sync.Collections.Collection.Status = 3

** Tue Oct 10 2023 11:34:50 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[EventLog] : Forced Folder Resync
Request:
<?xml version="1.0"?>
<Sync xmlns='AirSync'>
<Collections>
<Collection>
<SyncKey>%7B0b8c17c8-076f-4722-835a-9b94a2b5b2cc%7D31</SyncKey>
<CollectionId>Uff799</CollectionId>
<DeletesAsMoves/>
<GetChanges/>
<WindowSize>50</WindowSize>
<Options>
<FilterType>7</FilterType>
<Class>Calendar</Class>
<BodyPreference xmlns='AirSyncBase'>
<Type xmlns='AirSyncBase'>1</Type>
</BodyPreference>
</Options>
</Collection>
</Collections>
</Sync>

After disabling and enabling the corresponding account the calendar is found and synced and log shows:

** Tue Oct 10 2023 11:43:22 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: done, Account: Schulkonto

** Tue Oct 10 2023 11:43:22 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: preparing, Account: Schulkonto, Folder: Kalender

** Tue Oct 10 2023 11:43:22 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: prepare.request.synckey, Account: Schulkonto, Folder: Kalender

** Tue Oct 10 2023 11:43:22 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: send.request.synckey, Account: Schulkonto, Folder: Kalender

** Tue Oct 10 2023 11:43:22 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[Sending (EAS v14.0)] : POST https://kopano.gymnasium-ettenheim.de/Microsoft-Server-ActiveSync?Cmd=Sync&User=ho&DeviceType=TbSync&DeviceId=MZTB603f29339ba1ab3fa4e692e1e347

** Tue Oct 10 2023 11:43:31 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: eval.response.synckey, Account: Schulkonto, Folder: Kalender

** Tue Oct 10 2023 11:43:31 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: prepare.request.estimate, Account: Schulkonto, Folder: Kalender

** Tue Oct 10 2023 11:43:31 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: send.request.estimate, Account: Schulkonto, Folder: Kalender

** Tue Oct 10 2023 11:43:31 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[Sending (EAS v14.0)] : POST https://kopano.gymnasium-ettenheim.de/Microsoft-Server-ActiveSync?Cmd=GetItemEstimate&User=ho&DeviceType=TbSync&DeviceId=MZTB603f29339ba1ab3fa4e692e1e347

** Tue Oct 10 2023 11:43:31 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: eval.response.estimate, Account: Schulkonto, Folder: Kalender

** Tue Oct 10 2023 11:43:31 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: prepare.request.remotechanges, Account: Schulkonto, Folder: Kalender

** Tue Oct 10 2023 11:43:31 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[setSyncState] : State: send.request.remotechanges, Account: Schulkonto, Folder: Kalender

** Tue Oct 10 2023 11:43:31 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[Sending (EAS v14.0)] : POST https://kopano.gymnasium-ettenheim.de/Microsoft-Server-ActiveSync?Cmd=Sync&User=ho&DeviceType=TbSync&DeviceId=MZTB603f29339ba1ab3fa4e692e1e347

** Tue Oct 10 2023 11:43:32 GMT+0200 (Mitteleurop鋓sche Sommerzeit) **
[Timezone matched via both offsets (std:-60, dst:-120)] : Europe/Berlin

... repeated multiple times due to syncing ~1200 appointments

After a few days TB shows the same behavoir and calendar has to be deactivated, activated and completely synced again.

Any help ist kindly appreciated :)

@craigarno
Copy link

craigarno commented Dec 21, 2023

I'm experiencing the same problem as @JJ-Author , @DerXteMensch @OneTwoBarbecue with all 4 machines.

The machines are running MS Windows 11, MS Windows 10, and Ubuntu 22.04 LTS:

TbSync 4.8
Provider for Exchange ActiveSync 4.8
Thunderbird 115.6.0 (64-bit)

Connection is 100Mb/100Mb Fiber Latency ~6mS:

C:\Users\craig>ping outlook.office365.com

Pinging eat-efz.ms-acdc.office.com [52.96.164.82] with 32 bytes of data:
Reply from 52.96.164.82: bytes=32 time=5ms TTL=238
Reply from 52.96.164.82: bytes=32 time=6ms TTL=238
Reply from 52.96.164.82: bytes=32 time=7ms TTL=238
Reply from 52.96.164.82: bytes=32 time=7ms TTL=238

Ping statistics for 52.96.164.82:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 5ms, Maximum = 7ms, Average = 6ms

For consistency, I get the same latency results on an 8-core Linux machine.

I just read reducing sync level from the default 15 minutes to 10 minutes may help, I'm trying this next. Otherwise, the symptoms I'm experiencing are identical to the ones described by @JJ-Author , @DerXteMensch @OneTwoBarbecue
The Linux machine defaults to '0' and isn't experiencing this problem at this time. The Windows 11 machine did log a "Communication Error". The other Windows 11 machine had nothing logged and everything was blank, like the Windows 10 machine.
image

The Windows 10 machine just produced this error:
image

Which looks like this...
image

@craigarno
Copy link

Yesterday I noticed the Linux TbSync isn't having problems and the periodic synchronization is set to '0'. I set all 3 Windows machines to '0'. This morning, all 3 Windows machines are still connected and syncing.

I don't know what the consequences are of setting this value to '0', but it seems to work, and I hope this helps someone.
image

@craigarno
Copy link

This may need to be submitted as a new problem, but I tried adding an event to my calendar and asked tbSync to sync and it failed. However, after disabling the account and re-enabling, the event was stored and all sync'ed things restored themselves, even color changes. Setting Sync to '0' doesn't cure everything.
image

@craigarno
Copy link

I just discovered on my Windows 10 machine that setting periodic synchronization to 0 does not solve this problem. The problem is reduced, but doesn't disappear.

I hope a solution can be found soon.

@JJ-Author JJ-Author changed the title tbsync forgets office 365 accounts after a while (or just erases/loses accounts list) tbsync office 365 account vanishes periodically from account list (totally erased account list) Jan 3, 2024
@JJ-Author
Copy link
Author

Guys (@writemusic @snowbird25 @OneTwoBarbecue @craigarno) I think you are experiencing things that are very different to mine. I can not disable sync for my account an re-enable it because the account is gone / vanished / does not show up in the accounts lists anymore.
I think only @DerXteMensch described something like what happened to me.

I renamed the issue a little bit to make it even clearer.
please open a separate issue for your problems, they seem not relevant to mine.

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants