Replies: 2 comments 2 replies
-
Ok after I had posted this I managed to find the migrations folder - I ran all the commands backwards and its all working. For anyone else in the same position here's what I did: Hope that helps someone. |
Beta Was this translation helpful? Give feedback.
-
@BlackDex I had a power outage and had to restart everything, and vaultwarden looks like it is trying to now execute the migrations. However, in doing so its finding that the fields already exists. Any idea how i can resolve this since I ran migrations manually ? `[2025-01-11 14:03:42.892][panic][ERROR] thread 'main' panicked at 'Error running migrations: QueryError(DieselMigrationName { name: "2023-02-18-125735_push_uuid_table", version: MigrationVersion("20230218125735") }, DatabaseError(Unknown, "duplicate column name: push_uuid"))': src/db/mod.rs:452 0: vaultwarden::init_logging::{{closure}} 1: std::panicking::rust_panic_with_hook 2: std::panicking::begin_panic_handler::{{closure}} 3: std::sys::backtrace::__rust_end_short_backtrace 4: rust_begin_unwind 5: core::panicking::panic_fmt 6: core::result::unwrap_failed 7: vaultwarden::db::DbPool::from_config 8: vaultwarden::main::{{closure}} 9: vaultwarden::main 10: std::sys::backtrace::__rust_begin_short_backtrace 11: main 12: 13: __libc_start_main � |
Beta Was this translation helpful? Give feedback.
-
Hi I had been using vaultwarden through tteck's proxmox script to create lxc containers. I believe when I had it installed it I believe these are the version numbers :
`~ # apk info vaultwarden
vaultwarden-1.28.1-r4 description:
bitwarden alternative backend
vaultwarden-1.28.1-r4 webpage:
https://github.com/dani-garcia/vaultwarden
vaultwarden-1.28.1-r4 installed size:
17 MiB
vaultwarden-1.32.7-r0 description:
Bitwarden alternative backend
vaultwarden-1.32.7-r0 webpage:
https://github.com/dani-garcia/vaultwarden
vaultwarden-1.32.7-r0 installed size:
19 MiB`
I had gziped the files including the sqlite dbs and moved it to the new docker version of vaultwarden. However, it looks like the db schema has changed between the version that I was running to the latest.
Is there a way to migrate the sqlite db to the new schema - if so where can I get the new schema ?
`1: std::panicking::rust_panic_with_hook
2: std::panicking::begin_panic_handler::{{closure}}
3: std::sys::backtrace::__rust_end_short_backtrace
4: rust_begin_unwind
5: core::panicking::panic_fmt
6: core::result::unwrap_failed
7: vaultwarden::db::models::two_factor_duo_context::TwoFactorDuoContext::find_expired::{{closure}}::{{closure}}
8: vaultwarden::api::core::two_factor::duo_oidc::purge_duo_contexts::{{closure}}
9: tokio::runtime::task::raw::poll
10: tokio::runtime::scheduler::multi_thread::worker::Context::run_task
11: tokio::runtime::scheduler::multi_thread::worker::run
12: tokio::runtime::task::raw::poll
13: std::sys::backtrace::__rust_begin_short_backtrace
14: core::ops::function::FnOnce::call_once{{vtable.shim}}
15: std::sys::pal::unix::thread::Thread::new::thread_start
16:
17: __clone
[2025-01-10 11:10:31.566][panic][ERROR] thread 'tokio-runtime-worker' panicked at 'Error loading auth_requests: DatabaseError(Unknown, "no such table: auth_requests")': src/db/models/auth_request.rs:137
0: vaultwarden::init_logging::{{closure}}
1: std::panicking::rust_panic_with_hook
2: std::panicking::begin_panic_handler::{{closure}}
3: std::sys::backtrace::__rust_end_short_backtrace
4: rust_begin_unwind
5: core::panicking::panic_fmt
6: core::result::unwrap_failed
7: vaultwarden::db::models::auth_request::AuthRequest::find_created_before::{{closure}}::{{closure}}
8: vaultwarden::api::core::accounts::purge_auth_requests::{{closure}}
9: tokio::runtime::task::raw::poll
10: tokio::runtime::scheduler::multi_thread::worker::Context::run_task
11: tokio::runtime::scheduler::multi_thread::worker::run
12: tokio::runtime::task::raw::poll
13: std::sys::backtrace::__rust_begin_short_backtrace
14: core::ops::function::FnOnce::call_once{{vtable.shim}}
15: std::sys::pal::unix::thread::Thread::new::thread_start
16:
17: __clone
[2025-01-10 11:10:31.566][panic][ERROR] thread 'tokio-runtime-worker' panicked at 'Error finding expired contexts in twofactor_duo_ctx: DatabaseError(Unknown, "no such table: twofactor_duo_ctx")': src/db/models/two_factor_duo_context.rs:61
0: vaultwarden::init_logging::{{closure}}
1: std::panicking::rust_panic_with_hook
2: std::panicking::begin_panic_handler::{{closure}}
3: std::sys::backtrace::__rust_end_short_backtrace
4: rust_begin_unwind
5: core::panicking::panic_fmt
6: core::result::unwrap_failed
7: vaultwarden::db::models::two_factor_duo_context::TwoFactorDuoContext::find_expired::{{closure}}::{{closure}}
8: vaultwarden::api::core::two_factor::duo_oidc::purge_duo_contexts::{{closure}}
9: tokio::runtime::task::raw::poll
10: tokio::runtime::scheduler::multi_thread::worker::Context::run_task
11: tokio::runtime::scheduler::multi_thread::worker::run
12: tokio::runtime::task::raw::poll
13: std::sys::backtrace::__rust_begin_short_backtrace
14: core::ops::function::FnOnce::call_once{{vtable.shim}}
15: std::sys::pal::unix::thread::Thread::new::thread_start
16:
17: __clone
[2025-01-10 11:10:56.896][request][INFO] POST /identity/connect/token
[2025-01-10 11:10:56.897][response][INFO] (login) POST /identity/connect/token => 400 Bad Request
[2025-01-10 11:11:31.567][panic][ERROR] thread 'tokio-runtime-worker' panicked at 'Error loading auth_requests: DatabaseError(Unknown, "no such table: auth_requests")': src/db/models/auth_request.rs:137
0: vaultwarden::init_logging::{{closure}}
1: std::panicking::rust_panic_with_hook
2: std::panicking::begin_panic_handler::{{closure}}
3: std::sys::backtrace::__rust_end_short_backtrace
4: rust_begin_unwind
5: core::panicking::panic_fmt
6: core::result::unwrap_failed
7: vaultwarden::db::models::auth_request::AuthRequest::find_created_before::{{closure}}::{{closure}}
8: vaultwarden::api::core::accounts::purge_auth_requests::{{closure}}
9: tokio::runtime::task::raw::poll
10: tokio::runtime::scheduler::multi_thread::worker::Context::run_task
11: tokio::runtime::scheduler::multi_thread::worker::run
12: tokio::runtime::task::raw::poll
13: std::sys::backtrace::__rust_begin_short_backtrace
14: core::ops::function::FnOnce::call_once{{vtable.shim}}
15: std::sys::pal::unix::thread::Thread::new::thread_start
16:
17: __clone
[2025-01-10 11:11:31.567][panic][ERROR] thread 'tokio-runtime-worker' panicked at 'Error finding expired contexts in twofactor_duo_ctx: DatabaseError(Unknown, "no such table: twofactor_duo_ctx")': src/db/models/two_factor_duo_context.rs:61
0: vaultwarden::init_logging::{{closure}}
1: std::panicking::rust_panic_with_hook
2: std::panicking::begin_panic_handler::{{closure}}
3: std::sys::backtrace::__rust_end_short_backtrace
4: rust_begin_unwind
5: core::panicking::panic_fmt
6: core::result::unwrap_failed
7: vaultwarden::db::models::two_factor_duo_context::TwoFactorDuoContext::find_expired::{{closure}}::{{closure}}
8: vaultwarden::api::core::two_factor::duo_oidc::purge_duo_contexts::{{closure}}
9: tokio::runtime::task::raw::poll
10: tokio::runtime::scheduler::multi_thread::worker::Context::run_task
11: tokio::runtime::scheduler::multi_thread::worker::run
12: tokio::runtime::task::raw::poll
13: std::sys::backtrace::__rust_begin_short_backtrace
14: core::ops::function::FnOnce::call_once{{vtable.shim}}
15: std::sys::pal::unix::thread::Thread::new::thread_start
16:
17: __clone
`
Beta Was this translation helpful? Give feedback.
All reactions