Migrating from ownCloud to Nextcloud

Hey everyone,

The support was a little vague on the Nextcloud site.

Here are some more specific directions:

:smile:

  1. First you want to make a copy/backup of your Owncloud folder.

sudo cp -r /var/www/owncloud /var/www/owncloud.old

  1. Then remove everything inside your owncloud folder.

sudo rm -rf /var/www/owncloud/*
sudo rm -rf /var/www/owncloud/.*

  1. The reason we made a backup of the Owncloud folder was to make sure we still
    have the config and data, so cp that in to the owncloud folder again

sudo cp -r /var/www/owncloud.old/config /var/www/owncloud/
sudo cp -r /var/www/owncloud.old/data /var/www/owncloud/
sudo cp /var/www/owncloud.old/.htaccess /var/www/owncloud/
sudo cp /var/www/owncloud.old/.user.ini /var/www/owncloud/

  1. Install Nextcloud

We are going to download nextcloud, make sure you get the latest release

cd /temp
wget https://download.nextcloud.com/server/releases/nextcloud-9.0.50.tar.bz2

  1. Extract the tar ball and move it to Apache’s web root.

tar -vxjf nextcloud-9.0.50.tar.bz2
cd nextcloud
mv * /var/www/owncloud/

  1. Change the permissions while in the owncloud directory(it now has newcloud files inside of it):

wwwrun:www * -R or chown www-data

  1. The last thing we will need to do is the upgrade to Nextcloud.

cd /var/www/owncloud
sudo -u www-data php occ upgrade

And that should be it! open up your browser and enter your IP/FQDN to confirm it works!

I did copy most of this information from:
https://techknight.eu/2016/06/15/migrate-owncloud-nextcloud-linux/

and

They were good posts, but missing some commands. Hopefully this helps!

Cheers,

Mack