-
Every one to three hours at 5 minutes after the hour, I get the following error:
Any ideas what could be causing this? Is it worthy of a bug report? Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 13 replies
-
Could you try the latest |
Beta Was this translation helpful? Give feedback.
-
Strange, since the stuff you posted contained latest and not testing as the image which is used. For some reason the database is locked/in use. |
Beta Was this translation helpful? Give feedback.
-
Is there more I can check to give you better information? I build the image using the docker_image module with Ansible and restart it every time after a rebuild. These errors have been occurring at least as far back as April 5th (as far back as my journal goes). Rebuilds happen on any new vaultwarden or web vault tag. The only hourly task on my server is a btrbk snapshot, but that is completing typically over 10 minutes before the vaultwarden errors. No other processes or containers access the What could possibly be accessing that file on such a regular basis?? That's so weird! |
Beta Was this translation helpful? Give feedback.
-
I was just looking at my logs, but doesn't look like I'm able to reproduce it. It could be some query takes a long time and for some reasons holds the lock on the database. For now to mitigate it i suggest to change the timings of those schedules to not take place at the exact same time. What the environment variables are and what there defaults can be seen here https://github.com/dani-garcia/vaultwarden/blob/main/.env.template#L84..L100 I do have some thoughts on how you could try and debug it. But that would mean modifying some code and probably having a lot of extra logging. It will also make the instance slower because of this logging. And other thing you could try to do now i think of it, is too try and VACUUM the database. You could do this your self, or use the backup function located into the /admin interface. After the backup is created you need to restore that backup which should be a vacuumed copy of the current running database. I do suggest to keep the original also btw, just rename it or something. |
Beta Was this translation helpful? Give feedback.
-
Ok, i did a quick test and set the scheduler to write every second something to the database and to the exact same table with 3 different scheduled jobs. During that writing i was also performing full syncs on two different users in a while-loop to stress the database, and i was downloading a lot of icons at the same time. I was unable to exactly reproduce this specific issue, but, with my tests i didn't used a container, so that could be a difference here. But, what i did found was that with the default settings, i would get a different amount of added entries from the 3 different functions. Which shouldn't be the case of course. A difference of 1 or 2 i can understand because i press ctrl+c and that could prevent one or two items from being added. But... this seems to be solved if when i configured So, i suggest to try and change the config to add If i only were able to reproduce it, that would make it a lot easier. |
Beta Was this translation helpful? Give feedback.
Ok, i did a quick test and set the scheduler to write every second something to the database and to the exact same table with 3 different scheduled jobs. During that writing i was also performing full syncs on two different users in a while-loop to stress the database, and i was downloading a lot of icons at the same time.
I was unable to exactly reproduce this specific issue, but, with my tests i didn't used a container, so that could be a difference here.
But, what i did found was that with the default settings, i would get a different amount of added entries from the 3 different functions. Which shouldn't be the case of course. A difference of 1 or 2 i can understand because i press ct…