Migrating Users and Data

I was not able to resolve this matter: Internal Server Error after Upgrade to 11.0.1 - #3 by sawyer_t

So I tried to install a new instance of Nextcloud, and that seems to work fine. So now I need to migrate users and their data to the new installation. I only found advice on how to migrate a whole instance; can anyone please give some advice on how to migrate users and their data to a new instance?

Thank you!

  • Create a database backup on the old instance
  • Shut down the new instance
  • Copy the data directory across from the old instance
  • Restore the database backup to the new instance (ensure you take a backup of the new instance DB before this)
  • Restart the new instance

It should be identical to before. You can also copy across themes and apps if you added any manually (via download and unzip into the relevant dirs)

Hi Jason… I’d like to migrate from a TruNAS NC Plugin to a fresh install in a Jail that allows updating OS and NC without danger of crashing. The DATA is already existing on a “cloud” folder on the TrueNAS system. Terabytes are already in there.

Does the procedure you outlined above work on my scenario? It’s a BSD 12.2 install, and works nicely. Haven’t instaled any users or data…

Have however already made the “Mount Points” and verified that the data appears in Nextcloud/Data …

Help !

data restored… but to a different db name… what now ? Can I specify which db to use?

Hi Jason… Please give me some additional advice…

root@localhost [(none)]> show databases;
±-------------------------------+
| Database |
±-------------------------------+
| information_schema |
| mysql |
| nextcloud | <= the existing db
| p49oz3bg | <= the db I wanted to use
| performance_schema |
| sys |
±--------------------------------+
6 rows in set (0.01 sec)

I thought the restore from the other instance would populate nextcloud. Instead it just created a clone of itself. I should have known. Ugh! Is this fixable ?

Can I copy the config.php from the NC instance that uses the database (p49oz3bg) I want to use and just change the IP address… ?

This all started because of an upgrade that stopped because files could not be moved into place… Failed upgrade from 22.1.0 to 22.2.0

Yes, normally it should be enough to change the db-name in the config.php file.

This topic was automatically closed after 16 hours. New replies are no longer allowed.