New server, same domain?

So my nextcloud server exploded and like a dumb dumb my database & config backups were out of date.

I still have access to the drives for a while and am copying over all the files to a new (managed) nextcloud server.

What will happen if I change the IP in the DNS for the domain to the new server?

E.g. cloud.domain.com points to 1.2.3.4 old server which no longer works, so I change this to 5.6.7.8 - the new server.

The files are the same (or content of the files at least, possibly not the mtime), but none of the user accounts can be transferred. The SSL certs aren’t the same either of course.

95% of our 150 user accounts are basically read-only accounts, they have a quota of 0B and are given read access to some files. The other 5% are our team accounts that have read+write access to all the same files on the admin user account, and generally don’t store their own files.

What will happen in the Desktop client if I changed the DNS?

I imagine first an authentication (and possibly SSL) error, but if that is resolved with new credentials, how will the clients behave?

Most of them have complex selective sync options, and some will likely have new files added since the old server went kaput. But for the most part, everyone already has the majority of files downloaded.

There’s about 2.7 TB of data.

Would it be better to just start from scratch and ask everyone to delete their connection and use a new one on a different domain?

Hopefully i have understand you.

You have copied 2.7 TB from one outdated nextcloud instance to a new instance?

The problem is the fact that you must differ between the data and the database. In the database all users, shares, … are saved.

You can read backup and restore for the correct way for migration. You must backup and restore data and database.

If you only migrate the data and not the database you must re-create all users and also the shares, … You can re-scan all files but e.g. the shares still does not exists.

New server, same domain?

That is possible. But i think only with down-time.

1 Like

I can’t do a proper backup and restore unfortunately, so I must recreate users and shares. I’m doing this with rclone, with the new server set up as a webdav destination. So I’m not just copying the files from hdd to hdd, but going through nextcloud on the new end.

This won’t cause any trouble with nextcloud itself, but I worry how the clients will see it.

I guess users will just remove their connection, and then add the new one (with their new user account) at the same folder location as the old one (if this can even be done).

Yes. But perhaps they share folders or files with other people. All shares are lost. And they can not re-create with the same url.

Next time the correct way is “backup” on the first server und “restore” on the second server.