Restore NextcloudPi instance after Raspberry Pi was broken

I used NextcloudPi installed on Raspberry Pi 4. NC data and database were moved to external hdd.

Recently, as I think, after OS update Raspberry stoped booting. The problem is that it is installed in my parents’ house and I don’t have access to it right now. I asked parents to insert microSD to a desktop pc and it works without any problem, I mean I have access to the data on SD.

So, what is the easiest way to restore NextcloudPi instance? I am not sure there is a latest backup file on hdd.

Maybe it is possible to install a new instance with the same params and then just replace nextcloud folder from the old instance?

Thanks for any advice.

You could try something I’ve done before however I don’t know how many users you have or if it works with a large number of users, technically it should as far as I know, but I haven’t tested it with more than 3-4 users.

What I’ve done when I needed to restore an instance & wasn’t able to make a backup but still had access to the data, was to move the data from the nextcloud data directory on the external drive to the external drive’s root directory, then I’ve installed nextcloudpi again and set it up, created the users and moved the files back. Afterwards you will need to use the ncc or occ command to scan for external files that have been added, this can take a while, then you should see the files again in nextcloud file viewer if everything went well

EDIT: Note that you must not format your external drive if you use this method, cuz your data is still on it in the root directory :smiley:

Thanks much. There were 4 users in my instance.
I see the idea of restoring data, but doest it help to restore users passwords?

As the admin you can set the passwords for users and can set the passwords for the new users to the same as the old ones.

I don’t know, does that answer your question?

If you were thinking of copying some credential config file or something like that, then I don’t know :pray: