Migration guide and tools to migrate an old nextcloud instance to a managed hetzner storage share instance. As you can't just copy the database due to the limited permissions on the managed host, we have to migrate data manually:
- Files
- Users
- Shares
- Deleted files
- File versions
- Any other file metadata that is storen in the nextcloud DB and not in the files
- Maybe other stuff that we not aware of (feel free to add/edit by sending a PR)
- You need root access to the old nextcloud instance (Maybe you can also achieve it without by using the OCC Web app)
Before important your shares to the new instance, make sure that you have imported all users and files before.
- Install the app Share Listing to be able to list all shares on the command line. (Make sure to run
occusing the right user/permissions) - Login to your old instance and run
./occ sharing:listto get a json file including all shares
- create script to create shares y reading the json and send commmand to API https://docs.nextcloud.com/server/16/developer_manual/client_apis/OCS/ocs-share-api.html