How do I: Import snap created "nextcloud.export" into the Docker AIO using web-UI

Most all detail is in the title.

I’ve got a snap install, and have done a backup using “nextcloud.export” - I get a “backup/export” directory which appears to have all the data and DB in it.

I’ve got a new install - Docker from NC and I want to put that “export” into it.

I thought using the web UI, putting that backup directory in a folder called “borg” and doing a “restore” in the Web UI would do it.

But nope.
I get this in the logs.

A ‘borg’ directory was found but could not find the borg archive.
Only the files/folders below have been found in the borg directory.


The archive and most importantly the config file must be positioned directly in the ‘borg’ subfolder.

I suspect there is a post somewhere that would enlighten me, but my search-foo is weak and I’ve been unable to find anything.


Hi, indeed is the export of the snap not compatible with AIOs “import”.

However see this: all-in-one/ at main · nextcloud/all-in-one · GitHub

That sucks!
Ugh. Makes my head hurt.
Thanks for the info tho. :slight_smile:

One more question:
The Snap was 24.0.7
The AIO claims to be 3.1.0

Will those two be compatible to do the file+db migration?

Did you check the guide already? There are exact instructions regarding this :slight_smile:

I did, and they say they have to be the same - but 24.0.7 seems like a completely different version numbering scheme than 3.1.0 - so either 3.1.0 is really something like 30.1.0, or trying to compare 3.1.0 to 24.0.7 doesn’t make any sense anyway - that’s why I asked.

Ah, I see now - you point the version lookup at the git - so what’s running in docker should match what’s in git (provided it’s up to date, which it is.) [I’m no docker guy, so that was confusing.]

Ok, well, it looks to be the same version - but one is MySQL and AIO wants PSQL. I guess I get to see how much the users want their old data, or since it’s a test build, if we just start over. It just gets more complicated…

This is why when you look further down you will need to migrate to postgresql first. Just read the whole document first! :slight_smile:

There’s a syntax problem:

occ db:convert-type --all-apps --password "$PG_PASSWORD" pgsql "$PG_USER" "$PG_DATABASE"

Command occ not found.
No idea what occ is, or what it should be.

sudo nextcloud.occ ...

In your case most likely…

I did find that.
But still no joy.

sudo nextcloud.occ db:convert-type --all-apps --password “$PG_PASSWORD” pgsql “$PG_USER” “$PG_DATABASE”
Creating schema in new database

In Connection.php line 139:

Failed to connect to the database: An exception occurred in the driver: could not find driver

Do I need to install psql and create the DB inside the snap too? That’s what that looks like to me - in my wild guess.

Ah I see. This is something I did not anticipate. So it seems like a database migration with the snap is not possible since it is read only (you cannot install the php-psql extension). Thanks for testing anyways!

I am now thinking about ways to make this possible somehow but this will take a while.

To be clear then, we’re SOL, in migrating to AIO?

I am not sure what SOL means. Your only options for now are the first and the 3rd as the 2nd doesnt work with the snap.

SOL=$hit out of luck. :slight_smile:
The third might work.

Is the migration tool part of the Ubuntu 22.04 snap env?

You can install it. See User migration - Apps - App Store - Nextcloud

I’ll note in the docs for now that the 2nd option is unfortunately not possible when coming from snap: adjust migration docs by szaimen · Pull Request #1462 · nextcloud/all-in-one · GitHub

I also created a feature request to document how to allow to migrate the files and database for snap instances: allow to migrate the files and the database from nextcloud snap to aio · Discussion #1463 · nextcloud/all-in-one · GitHub