element-desktop icon indicating copy to clipboard operation
element-desktop copied to clipboard

Unable to restore session due to missing session data

Open johannes-krude opened this issue 1 year ago • 4 comments

Steps to reproduce

  1. Login into Element Desktop
  2. Close Element Desktop
  3. Start Element Desktop
  4. "Unable to restore session" appears
  5. Click "Clear Storage and Sign out"
  6. Signing in waits forever, but never succeeds
  7. rm -r .config/Element to get Element Desktop into a usable state
  8. Now, login into Element Desktop succeds

Additionally, Element Desktop fails to recover encryption keys from server key backup, but successfully imports encryption keys from a file which are saved in element-web from firefox.

Operating system

Ubuntu 22.04.4 LTS

Application version

1.11.59

How did you install the app?

deb https://packages.element.io/debian/ default main

Homeserver

comsys.rwth-aachen.de

Will you send logs?

Yes

johannes-krude avatar Mar 12 '24 09:03 johannes-krude

With 1.11.63, element-desktop now shows a different error message on startup:

Missing session data
Some session data, including encrypted message keys, is missing. Sign out and sign in to fix this, restoring keys from backup.

Your browser likely removed this data when running low on disk space. To help us prevent this in future, please send us logs.

johannes-krude avatar Apr 10 '24 09:04 johannes-krude

I built element desktop from source and I face the same issue.

When I run element-desktop in terminal, I get the following result:

Keytar isn't installed; secure key storage is disabled.
Seshat isn't installed, event indexing is disabled.
/home/USERNAME/.config/Element exists: yes
/home/USERNAME/.config/Riot exists: no
Starting auto update with base URL: https://packages.element.io/desktop/update/
Auto update not supported on this platform
Fetching translation json for locale: en_EN
Changing application language to en
Fetching translation json for locale: en
Resetting the UI components after locale change
Resetting the UI components after locale change
Changing application language to en
Fetching translation json for locale: en
Resetting the UI components after locale change
[32056:0613/173459.253777:ERROR:gl_surface_presentation_helper.cc(260)] GetVSyncParametersIfAvailable() failed for 1 times!

I get this error after I removed ~/.config/Element, and restarting Element after once successful login.

The first two lines seems to be related to the issue:

Keytar isn't installed; secure key storage is disabled.
Seshat isn't installed, event indexing is disabled.

ahangarha avatar Jun 13 '24 14:06 ahangarha

@ahangarha your issue is different then. You should follow the instructions to install the native modules. https://github.com/element-hq/element-desktop/blob/develop/docs/native-node-modules.md

t3chguy avatar Jun 13 '24 14:06 t3chguy

Logs contain:

2024-04-10T09:15:04.921Z E StorageManager: Data exists in local storage and crypto is marked as initialised  but no data found in crypto store. IndexedDB storage has likely been evicted by the browser!
2024-04-10T09:15:04.921Z E StorageManager: Storage consistency checks failed

richvdh avatar Aug 06 '24 13:08 richvdh