Migration from sqlite to mysql incomplete #2709

Closed
opened 2026-04-06 03:58:11 +02:00 by MrUnknownDE · 0 comments
Owner

Originally created by @fbartels on 11/23/2020

Subject of the issue

When following the instructions outlined in https://github.com/dani-garcia/bitwarden_rs/wiki/Using-the-MySQL-Backend and https://github.com/dani-garcia/bitwarden_rs/issues/984 to switch from the default sqlite database to a mysql one, users are able to login and see entries. but entries are missing all data such as usernames, passwords, 2fa token, urls (attachments however are preserved).

Your environment

Steps to reproduce

  • sqlite3 db.sqlite3 .dump | grep "^INSERT INTO" | grep -v "__diesel_schema_migrations" > sqlitedump.sql ; echo -ne "SET FOREIGN_KEY_CHECKS=0;\n$(cat sqlitedump.sql)" > mysqldump.sql
  • sed -i s#\"#\#g mysqldump.sql
  • move data to new system
  • import database with mysql --force --password --user=bitwarden_rs --database=bitwarden_rs < mysqldump.sql

Expected behaviour

  • password vault has same data as before the migration

Actual behaviour

  • users can login and see items in vault, but items are missing data such as usernames, passwords, urls

Relevant logs

  • no error to be seen in logs
*Originally created by @fbartels on 11/23/2020* ### Subject of the issue When following the instructions outlined in https://github.com/dani-garcia/bitwarden_rs/wiki/Using-the-MySQL-Backend and https://github.com/dani-garcia/bitwarden_rs/issues/984 to switch from the default sqlite database to a mysql one, users are able to login and see entries. but entries are missing all data such as usernames, passwords, 2fa token, urls (attachments however are preserved). ### Your environment * Bitwarden_rs version: 1.17.0 * Install method: build from source as part of https://git.cloudron.io/cloudron/bitwardenrs-app/-/blob/master/Dockerfile * Clients used: web vault 2.16.1 * Reverse proxy and version: Apache + Nginx * Version of mysql/postgresql: unknown * Other relevant information: ### Steps to reproduce - `sqlite3 db.sqlite3 .dump | grep "^INSERT INTO" | grep -v "__diesel_schema_migrations" > sqlitedump.sql ; echo -ne "SET FOREIGN_KEY_CHECKS=0;\n$(cat sqlitedump.sql)" > mysqldump.sql` - `sed -i s#\"#\#g mysqldump.sql` - move data to new system - import database with `mysql --force --password --user=bitwarden_rs --database=bitwarden_rs < mysqldump.sql` ### Expected behaviour - password vault has same data as before the migration ### Actual behaviour - users can login and see items in vault, but items are missing data such as usernames, passwords, urls ### Relevant logs - no error to be seen in logs
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/vaultwarden#2709