Problem with bind mount
I am running immich using portainer the compose file is unaltered:
_
volumes:
- ${UPLOADLOCATION}:/usr/src/app
The env table is
_
UPLOADLOCATION=/mnt/photos-immich
I get a series of these errors and the server cannot start:
[Nest] 7 - 01/27/2025, 8:36:43 PM ERROR [Microservices:StorageService] Failed to read upload/encoded-video/.immich: Error: ENOENT: no such file or directory, open 'upload/encoded-video/.immich'
The /mnt/photos-immich is mounted and being used by other containers in the same instance of portainer.
Any help would be appreciated.
29 Replies
:wave: Hey @Lutetium,
Thanks for reaching out to us. Please carefully read this message and follow the recommended actions. This will help us be more effective in our support effort and leave more time for building Immich :immich:.
References
- Container Logs:
docker compose logs
docs
- Container Status: docker ps -a
docs
- Reverse Proxy: https://immich.app/docs/administration/reverse-proxy
- Code Formatting https://support.discord.com/hc/en-us/articles/210298617-Markdown-Text-101-Chat-Formatting-Bold-Italic-Underline#h_01GY0DAKGXDEHE263BCAYEGFJAChecklist
I have...
1. :blue_square: verified I'm on the latest release(note that mobile app releases may take some time).
2. :blue_square: read applicable release notes.
3. :blue_square: reviewed the FAQs for known issues.
4. :blue_square: reviewed Github for known issues.
5. :blue_square: tried accessing Immich via local ip (without a custom reverse proxy).
6. :blue_square: uploaded the relevant information (see below).
7. :blue_square: tried an incognito window, disabled extensions, cleared mobile app cache, logged out and back in, different browsers, etc. as applicable
(an item can be marked as "complete" by reacting with the appropriate number)
Information
In order to be able to effectively help you, we need you to provide clear information to show what the problem is. The exact details needed vary per case, but here is a list of things to consider:
- Your docker-compose.yml and .env files.
- Logs from all the containers and their status (see above).
- All the troubleshooting steps you've tried so far.
- Any recent changes you've made to Immich or your system.
- Details about your system (both software/OS and hardware).
- Details about your storage (filesystems, type of disks, output of commands like
fdisk -l
and df -h
).
- The version of the Immich server, mobile app, and other relevant pieces.
- Any other information that you think might be relevant.
Please paste files and logs with proper code formatting, and especially avoid blurry screenshots.
Without the right information we can't work out what the problem is. Help us help you ;)
If this ticket can be closed you can use the /close
command, and re-open it later if needed.GitHub
immich-app immich · Discussions
Explore the GitHub Discussions forum for immich-app immich. Discuss code, ask questions & collaborate with the developer community.
FAQ | Immich
User
GitHub
Issues · immich-app/immich
High performance self-hosted photo and video management solution. - Issues · immich-app/immich
Im using the default docker compose file, the only modification to the env file is the UPLOAD location - the error included it the error stopping the server from running, if the UPLOAD location is set back to "./Library" everything works fine. I can see the mnt/photos-immich file fine on the host and that location is working fine for other containers on the same server. Ive tried moving the location of the mount and renaming to see if there were any issues - i just cannot get immach to see that location at all
${UPLOAD_LOCATION}:/usr/src/app/upload
is the correct form
you can't just willy nilly rename that
"If the UPLOAD location is set back to "./Library" everything works fine"
If you want to change the upload location then you need to cp -a
the folders to the new location, or start fresh
You can't change it after initial startup
(without also moving the files)i blow the containers away, delete the volumes, change the env file, pull new images and start all the containers. Is that not how to do this?
Sure but you still need to use
${UPLOAD_LOCATION}:/usr/src/app/upload
yes - that hasnt changed at all - im using the default compose file
Please post your full compose and env
Did you blast the database folder as well?
because it's neither a container nor a volume
Hmmm - I am not sure then - I get rid of the volumes, destroy the containers and delete the images. Is that not destroying the database?
no
Is the database on the host?
Yes
DB_DATA_LOCATION
Wow - ok thanks - ill take a look - i thought that was part of a volume?
No, the . in
./library
and ./database
is "current folder" so it's wherever the compose file isYou just saved me weeks of frustration! Thank you so much!
Always happy to help
Its the only container that I use that does this. For anyone who may have this issue - since i am using portainer - the files that need to be deleted for a complete reset are under /data/compose/. There is a folder in there (mine was called "15") that will need top be deleted.
It's because the other containers you use don't care about the data 😛
If they were in volumes you are one
docker compose down -v
away from deleting everything everI'm glad I found this, as I've been fighting the same problem for a couple of weeks
So here's a question...why is it when I have a working container. If I upgrade to the next version of immich, I can't simply stop the stack, repull the image, and restart? I get these Nest errors and it can't find the database.
Or mildly...what is the right way to upgrade the stack from within Portainer?
I just force recreate from portainer
What is your compose/env?
it's just the standard one off the Immich website. The only difference I made to it was to add a volume pointing to my pictures folder....
- /home/solarczar/Pictures:/mnt/old_photos
env...
UPLOAD_LOCATION=/home/solarczar/Pictures/rev_011625
DB_DATA_LOCATION=/home/solarczar/immich_dbase
IMMICH_VERSION=release
DB_PASSWORD=password
DB_USERNAME=postgres
DB_DATABASE_NAME=immich
Early days of Immich, I'd just stop the stack, update the stack - selecting re-pull the image, and all was good. Now if I do that, I get Nest errors, delete the stack, delete the DB, and restart, reload all my pics.
I'm looking through the /data/compose folder and not sure which one is to be deleted on my side. Do the numbers reference a tie back
Are you mounting that whole folder as an external library?
Looks like you have nested mounts which is always a bad, bad, bad idea
I guess that's the right definition. I had trouble pointing Immich at the files downloaded from Google Photos. This is the direction I landed after much confusion
Ok, I don't know what that means exactly, but happy to read up
This directory:
UPLOAD_LOCATION=/home/solarczar/Pictures/rev_011625
is inside of this directory: /home/solarczar/Pictures:/mnt/old_photos
You can't do that
And also not the other way aroundAhh, didn't know that
imagine you create a new thumbnail
It goes in
/home/solarczar/Pictures/rev_011625
external library sees a new picture!
it creates a new thumbnail
it goes in /home/solarczar/Pictures/rev_011625
You get the idea.Yes I do. thanks.
Thanks for the assist...I'm running smooth as glass now.