Migrate from snap install to manual install

snap

#1

I’d like to convert my snap install to a manual install and migrate all my users/data/files.
Is this possible?

I setup a Nextcloud server using the snap package thinking it would be an easier setup. Now I’m stuck with locked file error messages, no way to add files locally using “sudo -u www-data php occ files:scan” command, and can’t do any server side troubleshooting because of the snap install (non of the command people recommend seem to work on a snap install).

Maybe I should just copy of of the raw files and start over from scratch.


#2

do you have a second server to test your “restore”? (vmware, virtualbox, cloud, etc.)

by just copying the file you’ll loose all “meta data” (shared links, shared with other user and so on.)

otherwise you would have to backup the database as well. and if you use the database for file locking might restore your trouble as well.

nextcloud backup/restore is described here: https://www.c-rieger.de/nextcloud-backup-and-restore/
easyway to setup nextcloud (manually): https://github.com/ReinerNippes/nextcloud13


#3

There are some cli-utilities included in Nextcloud-snap: https://github.com/nextcloud/nextcloud-snap/wiki/Included-CLI-utilities
Try this command:
sudo nextcloud.occ files:scan

Probably you can follow the backup and restore guide here, but for backing up you need to use the nextcloud-snap cli-utilities:
https://docs.nextcloud.com/server/13/admin_manual/maintenance/index.html


#4

Since I only had one other user so far who had used it with me, I just decided to copy the folders of files we had uploaded to a safe place. Then I uninstalled the snap version, and installed the full version. Then I just copied the files over and ran the:
“sudo -u www-data php /var/www/html/nextcloud/occ files:scan --all”, I can already tell that this version performs much better on my Ubuntu 18.0.4 server :slight_smile: