DB image malformed. How to fix it?

Hi,

I have the same problem - db corruption. DB file is 8 GB in size (was 9 before i ran dump and restote clean in new database.

Now, I am using HAOS and are not exactly sure how to replace fixed db file with current one (being created few days ago when original was found corrupted.

I need pretty much something like:

mv home-assistant_v2.db home-assistant_v2.db.OLD
mv home-assistant_v2.db-recovered home-assistant_v2.db

But, how do I access that filesystem if I stop HA, not sure.

Also, do I need to remove current shm and wal files, or these are not to be touched?

Thanks!

Mario.