Database restore when switching OS is not working
Hi. I recently switched from macos to ubuntu. to do this, i copied over all of my upload_location folder to the new machine, and did a database dump from the mac, and then restored it on the ubuntu. This didnt work though, because when i go to login, i get the initial first login sign up page. Attached are screenshots of me backing up the databse, and the restore. for the restore command, i took a screenshot at the beggining and end. I will also attach my compose and env files.
19 Replies
Do you know the architecture of both OS?
both are amd64?
Ah. I actually have no idea. I will figure out and tell u soon
Which machine model is your macbook?
and which machine are you running Ubuntu on?
So the Mac is an intel. So from Google I think x86_64
The ubuntu is running on an old hp computer
The old HP computer is 64 or 32 bit?
So I ran uname -i and got x86_64
Ok so both are on the same arch which is good
If you create a new instance of Immich on the MacOS as well and perform the database recovery, does it has the same issue?
So it didn’t work on the Mac either
Hmm, and you are using the same command listed in the document right?
Ya. Copy pasted
I’m going to try to reupload. And then make a new backup and will lyk what happens
Okay, we will need to take a look again at the command and the process
Thank you
So. When I restore on Mac. My login comes back. But the server has no images.

Can you delete the stack and volumes again, then only start postgres, run the restore, and then bring up the rest of the stack?
You can also unzip the backup and open the file. You will be able to see what data is being restored
Either there are no assets in the backup, or the backup is failing to restore because of some error, which can probably be fixed with a fresh database. Immich adds the schema automatically when the immich server starts up.
So. The data is there in the sql file. I just unzipped it and opened it and i see all my albums and assets

I’m not exactly sure how to start just the database. I’ve been googling and have tried “docker compose up -d immich_postgres” and that hasn’t worked for me
I get a no such service error
Ok. I had to use database. Did not know what a service was. So I’m trying it now
So I deleted everything with docker compose down -v. And then I started only the database. Restored it using the command from the docs. And then turned everything else on. And that worked! All my images are being displayed now
Doing that worked on the Ubuntu machine as well
Hooray! Thank you for testing
Great! Maybe we should add a note to the docs