Best practice to restore single files without harming the database

Hello Nextcloud Community,

I am thinking about the right way to restore single files into …/data/USER/files. If a user completely deleted some important file, and asks me to restore it, what is the best practice to do this correctly?

I know how to activate the maintenance mode, stop the webserver, restore some complete archive (borgbackup), restore the database, start the webserver and deactivate the maintenance mode.

I also know how to take single files out of some archives and upload it manually over the webinterface, but what to do if i want to put it directly into some user data directory without damaging the database consistency?

The occ command

occ files:scan

is exactly for that purpose

Read → this ← for detailed information.


Much and good luck,
ernolf

2 Likes

Thank you :slight_smile: