Hi,
I had a fatal crash of my nextcloud server and now need to restore the data from a borg backup. Restoring the files is not a big issue since I can access it in the backup but I am struggling to understand how I can recover the passwords from the passwords app.
In the borgbackup I have following data:
all the files in /var/www/nextcloud
an database backup as sql file created with mysqldump
To be more on the safe side in the future I would like to migrate to Hetzner Storage Share instead of having my own nextcloud instance. Is there a way to migrate my passwords from the borgbackup to the Hetzner Storage Share?
Can you elaborate a bit more on this password app? What is it and what passwords does it hold? Do you mean the Nextcloud user passwords? If so I think they should be part of you sql dump, encrypted obviously.
I’m not sure what data is stored in /var/www/nextcloud, but if it includes the config/config.php, then you can just create a new Nectcloud with this instance and the database dump you have.
Otherwise, look for a folder named appdata_<random strings here> in your data directory. Within there you’ll find a folder for the passwords app and in there the folder with the automatic backups created by the app. Then follow the Server Migration · Wiki · nextcloud / passwords · GitLab guide to restore the backup.
@mdw: I have found the “appdata_” directory but my problem is that I switched now to a Hetzner Storage Share which does also use Nextcloud but I do not have access to occ any longer. Is there a way to restore the passwords without having my own Nextcloud instance running and therefore having no access to occ? Also is there a way to regularly create password backups in a format that does not require occ to restore them? E.g. in the password-protected json format that is the default when I do the manual export?
You can try and see if occweb (OCC Web - Apps - App Store - Nextcloud) works for you. Otherwise the only way to restore them is to set up a local nextcould instance with the required user and restore the data there.
The app automatically makes server side backups, but these require server side access to restore.
You can make client side backups too, but these require client side access and therefore can’t be run on a schedule.