this post was submitted on 24 Feb 2025
133 points (99.3% liked)

Selfhosted

42858 readers
523 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 2 years ago
MODERATORS
 

Hi fellow self-hoster.

Almost one year ago i did experiment with Immich and found, at the time, that it was not up to pair to what i was expecting from it. Basically my use case was slightly different from the Immich user experience.

After all this time i decided to give it another go and i am amazed! It has grown a lot, it now has all the features i need and where lacking at the time.

So, in just a few hours i set it up and configured my external libraries, backup, storage template and OIDC authentication with authelia. All works.

Great kudos to the devs which are doing an amazing work.

I have documented all the steps of the process with the link on top of this post, hope it can be useful for someone.

you are viewing a single comment's thread
view the rest of the comments
[–] Ulrich@feddit.org 2 points 1 day ago (3 children)

How did you do external backups?

[–] Lem453@lemmy.ca 2 points 1 day ago (1 children)

I used to use a docker container that makes db dumps of the database and drops it into the same persistent storage folder the main application uses. I use this for everything in docker that had a db.

Immich as recently integrated this into the app itself so its no longer needed.

All my docker persistent data is in a top level folder called dockerdata.

In that I have sub folders like immich which get mounted as volumes in the docker apps.

So now I have only 1 folder to backup for everything. I use zfs snapshots to backup locally (zfs auto shot) and borgmatic for remote backups (borgbase).

All my dockers all compose files that are in git.

I can restore he entire server by restoring 1 data folder and 1 compose file per stack.

[–] Ulrich@feddit.org 1 points 1 day ago (2 children)

I don't understand how that's helpful. If something is corrupted or my house burns down, a local backup is going to go with it. That's why I asked for external backups.

[–] Shimitar@downonthestreet.eu 0 points 8 hours ago

I have three tiers of backup. Never heard or the 3,2,1 rule?

3 backups 2 locations 1 offsite

I backup one time on an external disk connected to the server. A second time to another disk, connected on an OpenWRT router located in the patio. A third copy is uploaded to my VPS in the cloud.

not all three are symmetrical due to disk sizes. But critical data is always backed up on all three. Daily backups.

Restic do deduplication and encryption too, so actual data usage is really minimal and all is kept safe.

[–] Lem453@lemmy.ca 1 points 1 day ago

Borgbase is remote

[–] Shimitar@downonthestreet.eu 1 points 1 day ago

I backup with restic the database backups done by immich, not the database itself, and the Library/library folder which contains the actual images and videos.

[–] clmbmb@lemmy.dbzer0.com 0 points 1 day ago (1 children)

Did you read the whole post? If so, did you go to his/her website?

[–] Ulrich@feddit.org 1 points 1 day ago (1 children)

Yeah I just didn't understand it.

[–] bdonvr@thelemmy.club 3 points 1 day ago (1 children)

If anyone's interested, here's my Immich backup script. You setup rclone to use an S3 storage service like BackBlaze which is quite cheap. I also use a crypt which means RClone will encrypt and decrypt all files to/from the server. S3 configuration and crypt setup.

Then set this up as a cron job. With the "BACKUP_DIR" option when you delete a photo it will get moved to the "deleted" folder. You can go into your S3 provider's lifecycle settings and have these get deleted after a number of days. I do 10 days. Or you can skip that and they'll be gone forever.

#!/bin/bash
SRC_PATH="/path/to/immich/library"
DEST_REMOTE="b2crypt:immich-photos/backup"
BACKUP_DIR="b2crypt:immich-photos/deleted"
RCLONE_OPTIONS="--copy-links --update --delete-during --backup-dir=$BACKUP_DIR --suffix `TZ='America/New_York' date +%Y-%m-%d`.bak --verbose"
rclone sync $SRC_PATH $DEST_REMOTE $RCLONE_OPTIONS

[–] Ulrich@feddit.org 0 points 1 day ago (3 children)

Yeah, I don't know what any of these words mean. I just want to click "export" and back all the data up to a flash drive. Is that too much to ask?

[–] Shimitar@downonthestreet.eu 1 points 8 hours ago (1 children)

I think it is. It doesn't take much to understand which folders needs to be backed up. They are also pretty clear on the immich website on how to backup the database itself. No, just an "export" wouldn't be good enough since the files themselves do not include the metadata.

[–] Ulrich@feddit.org 1 points 5 hours ago

I think it is.

Why is that?

They are also pretty clear on the immich website on how to backup the database itself

Yeah I'm pretty tired of hearing things are "pretty clear" or "not that complicated" and then being directed to an absolute word salad of technical terms no one without a computer science degree would understand.

No, just an "export" wouldn't be good enough since the files themselves do not include the metadata.

They could...add them?

[–] bdonvr@thelemmy.club 1 points 1 day ago (1 children)

Well yeah you could go on the site and select whatever photos and hit download I suppose.

[–] Ulrich@feddit.org 0 points 1 day ago (1 children)

There's no way to do that for your entire library. Also I assume that would not retain the Immich-specific metadata like the ML object tags and the "people" tagged in the photos.

[–] bdonvr@thelemmy.club 1 points 1 day ago (1 children)

You should have a backup solution for your server that should cover this, without that you should probably stick with managed photo backup services.

[–] Ulrich@feddit.org 0 points 1 day ago (1 children)

You should have a backup solution for your server that should cover this

Thats...why I'm asking?

managed photo backup services

...is that not what Immich is?

[–] bdonvr@thelemmy.club 2 points 1 day ago (1 children)

Are you paying for Immich somewhere? Then you'd have to trust the administrator to back your data up. I had assumed you were self hosting and by managed services I meant like Google Photos, or indeed someone else's Immich setup.

[–] Ulrich@feddit.org 0 points 1 day ago (1 children)

Are you paying for Immich somewhere?

No.

by managed services I meant like Google Photos

Not doing that for reasons that shouldn't need explaining.

[–] bdonvr@thelemmy.club 1 points 1 day ago (1 children)

If you're self hosting then you could just copy all the files from your server onto an external drive. I have to say that's not a great backup solution though, and you should learn more about administration of Linux servers so that when things break you can fix them. I wouldn't rely on it as a safe solution to your photos otherwise.

[–] Ulrich@feddit.org 0 points 1 day ago* (last edited 1 day ago) (3 children)

I'm not looking to become a sysadmin, thanks. I just want somewhere to safely store and organize my private photos.

I don't know how to access the filesystem and copying the library folders would not back up the metadata.

A great backup solution would be what I mentioned elsewhere. Just put a button to export it to a flash drive or an encrypted file server.

[–] shiftymccool@programming.dev 0 points 10 hours ago

I'm not looking to become a sysadmin

"I want to be an F1 racer but I don't wanna learn to drive"

That's what I heard you say

[–] bdonvr@thelemmy.club 2 points 1 day ago (1 children)

I'm not looking to become a sysadmin

And that's fine and understandable. But I don't think that Immich is for you. It's not consumer-grade software. It's a piece of Linux server software that requires occasional maintenance and administration. We haven't seen a breaking update in a while but Immich does occasionally release updates where things will break if you don't dig in to the config files and reconfigure it.

[–] Ulrich@feddit.org 0 points 1 day ago

If they implemented a proper backup system I wouldn't have to worry about it breaking. That's why I want it.

There's nothing else I need to access the backend for.

[–] ozeki@mastodon.gamedev.place 0 points 1 day ago (1 children)

@Ulrich @bdonvr It will indeed be hard to use Immich without some technical knowledge at the moment. The documentation explicitly warns that the software is changing fast and might break a few things.

I'm sure that some day they will have a paid hosted tier that will de-risk the technical aspects such as backups and resilience but thats not here yet.

Perhaps you could take a look at Ente Photos for a non-Google, privacy friendly (and encrypted) photo hosting solution.
https://ente.io/

[–] Ulrich@feddit.org 1 points 5 hours ago

I obviously have "some technical knowledge" as I was able to launch a server and install Immich. I just don't understand why everyone seems entirely opposed to making things easier.

[–] catloaf@lemm.ee 0 points 1 day ago (1 children)

One rclone command isn't much more complicated than one button.

[–] Ulrich@feddit.org 0 points 1 day ago (2 children)

Reading the comment I replied to, it appears to be much much more complicated. And I don't understand how anyone can claim otherwise.

[–] Shimitar@downonthestreet.eu 1 points 8 hours ago

You need to backup exactly two folders, which i have also pointed out in another commend and in the wiki.

However you back those folder up, it's up to you.

[–] catloaf@lemm.ee 0 points 1 day ago (1 children)

Key word is "appears". Choose your source and destination, run rclone. That's it. No harder than going to the page, clicking export, picking a folder, save. It's really not hard at all, give it a try.

[–] Ulrich@feddit.org 0 points 1 day ago* (last edited 19 hours ago) (1 children)

Choose your source and destination, run rclone. That's it.

This tells me absolutely nothing about how to do that. Source for what? Destination for what? Choose them where? What is rclone? Where do I get it? How do I run it? What does it do?

All questions that don't need to be answered before clicking a button in the UI.

E: That was very much not it, and they asked me to Google the rest of it.

[–] catloaf@lemm.ee 0 points 1 day ago (1 children)

The source and destination for the data we're discussing? Only you know where you're keeping it and where you're backing it up to, so you'll have to fill in those blanks yourself. The remainder of your questions can be answered with a cursory Google search (or other search engine of your choice).

[–] Ulrich@feddit.org 0 points 1 day ago* (last edited 1 day ago) (1 children)

I have no idea where that data is. Immich does.

Telling me to Google it is unhelpful and rude and further backs up my point that it is more complicated. If there is a button, I don't need to research anything, I just click it.

[–] catloaf@lemm.ee 0 points 1 day ago (1 children)

Immich is not magic. You were the one that set up and configured it. If you are unable to remember, I'm sure you could examine your configuration.

I am unable to provide any more information about rclone bevause I have never used it myself, but I am damn sure that if I did even the barest amount of effort to learn it on my own that I could find all the information I need and more, instead of expecting the information to be spit into my mouth like a baby bird.

[–] Ulrich@feddit.org -1 points 1 day ago (1 children)

I did not ask for magic. I asked for a button to export my data. Unless you consider that to be magical?

if I did even the barest amount of effort to learn it on my own that I could find all the information

I'm sure you could. And I'm sure I could. The problem is knowing what to do with that information. As it is, it might as well all be fucking hieroglyphics to me. I don't understand it.

You seem to be unable to comprehend that everyone is not a sysadmin. I do, however, know how to click buttons in a UI.

[–] catloaf@lemm.ee 1 points 1 day ago (1 children)

I am happy to hold your hand through administering your server, but my support rates start at $120/hr.

[–] Ulrich@feddit.org 0 points 1 day ago

Once again, not what I asked for. If you don't have anything helpful to contribute, please feel free to stop replying to me.