Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Apps | Demo | Docs | Install
  1. Cloudron Forum
  2. Immich
  3. Storage management in Immich?

Storage management in Immich?

Scheduled Pinned Locked Moved Unsolved Immich
44 Posts 8 Posters 2.7k Views 8 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • perelinP Offline
    perelinP Offline
    perelin
    wrote last edited by
    #33

    So, after some exchanges in the Immich Discord I managed to switch my existing Immich Photo Library to an external volume on a Hetzner Storage Box by copying the files (./upload/*) and setting the IMMICH_MEDIA_LOCATION to a mounted storage volume in /media/
    Immich started up again and displayed all my photos.
    BUT: it seems I cant upload new photos 😕 Not sure why, the /media/ mounted volume (Hetzner Storage Box) seems to have full permissions. Here is the Immich log when trying to upload a file:

    May 20 09:21:41 [Nest] 61 - 05/20/2025, 7:21:41 AM ERROR [Api:ErrorInterceptor~7wmg4ktf] Unknown error: Error: EPERM: operation not permitted, utime '/media/FSN1-BX1401/photos/immich/upload/bf2f33b8-b8b4-4f5d-9619-62e462afa3fd/a7/d2/a7d2dc05-0b07-4aca-977f-193026f26430.HEIC'
    May 20 09:21:41 Error: EPERM: operation not permitted, utime '/media/FSN1-BX1401/photos/immich/upload/bf2f33b8-b8b4-4f5d-9619-62e462afa3fd/a7/d2/a7d2dc05-0b07-4aca-977f-193026f26430.HEIC'
    May 20 09:21:41 at async Object.utimes (node:internal/fs/promises:1127:10)
    May 20 09:21:41 at async AssetMediaService.create (/usr/src/app/dist/services/asset-media.service.js:293:9)
    May 20 09:21:41 at async AssetMediaService.uploadAsset (/usr/src/app/dist/services/asset-media.service.js💯27)
    May 20 09:21:41 at async AssetMediaController.uploadAsset (/usr/src/app/dist/controllers/asset-media.controller.js:40:29)

    Any ideas how to debug this?

    1 Reply Last reply
    1
    • nebulonN Away
      nebulonN Away
      nebulon
      Staff
      wrote last edited by
      #34

      Immich runs as the cloudron user within the container. If you open a webterminal into the app, can you check if that user has write permissions to the /media/... volume?

      1 Reply Last reply
      2
      • perelinP Offline
        perelinP Offline
        perelin
        wrote last edited by
        #35

        Yes, tried that - basic permissions look good. It seem to be an issue with Immich trying to use utime to change timestamps on the mounted share which seem to be an issue somehow for the cloudron user. Some testing on my box shows:

        Creating a testfile (touch .test) on the mounted share and then trying to change the timestamp

        • works for root (-> touch -t 202501010000 .test)
        • does not work for cloudron (-> sudo -u cloudron touch -t 202501010000 .test)

        Not sure how to continue.

        1 Reply Last reply
        1
        • nebulonN Away
          nebulonN Away
          nebulon
          Staff
          wrote last edited by
          #36

          For a start, how did you mount the storage box? both SSHFS and CIFS are quite particular about users and permissions. One reason why we don't support moving the main app directory onto such mount points...

          1 Reply Last reply
          1
          • perelinP Offline
            perelinP Offline
            perelin
            wrote last edited by
            #37

            I mounted it with the Cloudron build in mount option in the UI. Are there other options? I guess editing fstab by hand will be overwritten at some point 🙂

            Here is the output of the mountcommand from the console.

            root@81deeb68-0628-45ff-bf4c-0e9e294e7935:/media/FSN1-BX1401# mount | grep FSN1-BX1401
            //u452885.your-storagebox.de/backup on /media/FSN1-BX1401 type cifs (rw,relatime,vers=3.1.1,cache=strict,username=u452885,uid=808,forceuid,gid=808,forcegid,addr=2a01:04f8:2b03:0981:0000:0000:0000:0002,file_mode=0666,dir_mode=0777,iocharset=utf8,seal,soft,nounix,serverino,mapposix,rsize=4194304,wsize=4194304,bsize=1048576,retrans=1,echo_interval=60,actimeo=1,closetimeo=1)
            
            1 Reply Last reply
            1
            • nebulonN Away
              nebulonN Away
              nebulon
              Staff
              wrote last edited by
              #38

              right, so the issue is, CIFS with hetzner only knows one uid which is set there in the mount option. This means there are no real user IDs....does it work if you give all users? Although it is still unclear why you can write but not change mtime attribute via touch as cloudron user, if I understand correctly.

              I guess that needs more investigation on how to maybe workaround that...

              perelinP 1 Reply Last reply
              2
              • nebulonN nebulon

                right, so the issue is, CIFS with hetzner only knows one uid which is set there in the mount option. This means there are no real user IDs....does it work if you give all users? Although it is still unclear why you can write but not change mtime attribute via touch as cloudron user, if I understand correctly.

                I guess that needs more investigation on how to maybe workaround that...

                perelinP Offline
                perelinP Offline
                perelin
                wrote last edited by perelin
                #39

                @nebulon said in Storage management in Immich?:

                does it work if you give all users?

                Not sure what you mean here. Mounting the share with other options? I had the impression I can not do that by myself since its managed by Cloudron.

                Would love to make this work. If you tell me what to try Im happy put some time in 🙂

                1 Reply Last reply
                1
                • nebulonN Away
                  nebulonN Away
                  nebulon
                  Staff
                  wrote last edited by nebulon
                  #40

                  Ah sorry, that was unclear. What I meant was, if you chmod a+rw -R the folder structure? This should give all users read/write access. Maybe that works around the single user CIFS permissions.

                  1 Reply Last reply
                  1
                  • perelinP Offline
                    perelinP Offline
                    perelin
                    wrote last edited by
                    #41

                    Ah, got it. Tried, didnt do anything. But the whole mounted share already had like 777 permissions throughout:

                    drwxrwxrwx 2 808 808 0 May 21 08:56 immich/
                    
                    1 Reply Last reply
                    0
                    • nebulonN Away
                      nebulonN Away
                      nebulon
                      Staff
                      wrote last edited by
                      #42

                      oh right 😕 well you will hit other side-effects then with apps if the filesystem is not actually support those features. This is one of the reasons, we only allow to move the app itself onto very specific filesystems like xfs and ext4. Not sure what can be done if CIFS with hetzner does not allow this. Or maybe you can investigate if you setup the mountpoint manually on the system with other mount options?

                      1 Reply Last reply
                      0
                      • perelinP Offline
                        perelinP Offline
                        perelin
                        wrote last edited by
                        #43

                        Yup, I guess I will experiment a bit with the mount options available. Will report back here if I find something that works, thx!

                        1 Reply Last reply
                        1
                        • perelinP Offline
                          perelinP Offline
                          perelin
                          wrote last edited by
                          #44

                          Footnote: sadly Immich already decided to not support setups where utime is not availble: https://github.com/immich-app/immich/issues/14005

                          1 Reply Last reply
                          1
                          Reply
                          • Reply as topic
                          Log in to reply
                          • Oldest to Newest
                          • Newest to Oldest
                          • Most Votes


                          • Login

                          • Don't have an account? Register

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • Bookmarks
                          • Search