Restoring data when apps/extensions are logged in doesn't actually restore the data #3513

Closed
opened 2026-04-06 04:56:30 +02:00 by MrUnknownDE · 0 comments
Owner

Originally created by @vitobotta on 3/7/2019

Hi! First of all thanks a lot for bitwarden_rs, it's much simpler and works great.

I wrote a simple script to backup both the sqlite database and the attachments (it's in this gist if someone wants to use it - https://gist.github.com/vitobotta/3a6c53c3693ff77cd0c920d0a541622d); backups work fine, but I am seeing a weird behavior with restores if I leave the client apps (including browser extensions) open/logged in while restoring the database. The procedure I use to do a restore is as follows:

  1. docker stop
  2. replace the sqlite database with the backup file (and optionally replace the attachments directory if needed)
  3. docker start

If I delete an item from my vault after a backup, and then restore that backup while leaving the apps open/logged in, that item doesn't appear again in the client apps after a sync. It seems to me that I have to logout from all the client apps and browser extensions before restoring, so that the restored data appears again in the apps when re-logging in. Why is this happening? Is it because any changes made after the backup -which will be restored- are more recent than the backup and therefore when syncing the clients the restored data gets replaced again with the modified data? If yes perhaps this should be explained in the README.

I took a note for myself to log out from both the mac/Android apps and the browser extensions (Firefox and Chrome) before restoring, but I would like to know if this is expected behavior / if there is a way to avoid this and leave the apps logged in while restoring, which would be easier.

Thanks in advance for your help!

*Originally created by @vitobotta on 3/7/2019* Hi! First of all thanks a lot for bitwarden_rs, it's much simpler and works great. I wrote a simple script to backup both the sqlite database and the attachments (it's in this gist if someone wants to use it - https://gist.github.com/vitobotta/3a6c53c3693ff77cd0c920d0a541622d); backups work fine, but I am seeing a weird behavior with restores if I leave the client apps (including browser extensions) open/logged in while restoring the database. The procedure I use to do a restore is as follows: 1. docker stop <container> 2. replace the sqlite database with the backup file (and optionally replace the attachments directory if needed) 3. docker start <container> If I delete an item from my vault after a backup, and then restore that backup while leaving the apps open/logged in, that item doesn't appear again in the client apps after a sync. It seems to me that I have to logout from all the client apps and browser extensions before restoring, so that the restored data appears again in the apps when re-logging in. Why is this happening? Is it because any changes made after the backup -which will be restored- are more recent than the backup and therefore when syncing the clients the restored data gets replaced again with the modified data? If yes perhaps this should be explained in the README. I took a note for myself to log out from both the mac/Android apps and the browser extensions (Firefox and Chrome) before restoring, but I would like to know if this is expected behavior / if there is a way to avoid this and leave the apps logged in while restoring, which would be easier. Thanks in advance for your help!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/vaultwarden#3513