Backup and Restore Immich from TrueNAS Scale to Docker using pg_dumpall #10906
ra7bi
started this conversation in
Community Guides
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Backup and Restore Immich from TrueNAS Scale to Docker
This guide will walk you through the steps to backup your Immich database and relevant folders from a TrueNAS Scale environment and restore them to a Docker-based system.
Backup Immich Database and Folders from TrueNAS Scale
SSH into your TrueNAS Scale server:
Get the PostgreSQL pod name:
Look for the pod name that starts with
immich-postgres
.Dump the PostgreSQL database:
Move the dump file to a desired location:
Copy the required folders:
Download the dump file and backupLibrary folder to your local machine:
Use
scp
or any other method to download the dump file and backupLibrary folder to your local machine.Restore Immich Database and Folders on Docker
Copy the backupLibrary folder to your new Docker server:
Use
scp
or any other method to upload the backupLibrary folder to your new Docker server.Download and set up Immich on your Docker server:
Follow the Immich Docker installation guide to download and set up Immich.
Update the
UPLOAD_LOCATION
in your.env
file:Set the
UPLOAD_LOCATION
to point to thebackupLibrary
folder:Check the PostgreSQL version in TrueNAS Scale:
Make sure the version matches with the PostgreSQL version in your Docker setup. If not, update your Docker YAML file to match the PostgreSQL version.
Prepare the dump file:
Notes
<immich-postgres-pod-name>
with the actual PostgreSQL pod name obtained in step 2./home/xxxx
with the actual path where you want to move the dump file./path_to_backupLibrary
with the actual path to thebackupLibrary
folder on your Docker server.sed
andgzip
installed on your local machine for processing the dump file.This guide should help you smoothly backup and restore your Immich database and relevant folders between TrueNAS Scale and any Docker-based system. If you encounter any issues, please refer to the relevant PostgreSQL and Docker documentation for further assistance.
Thanks you
Beta Was this translation helpful? Give feedback.
All reactions