Update failing on truenas official app
"Exception: Cannot remove old storage config while it is still in use. Please migrate to the new storage config first before upgrading"
v1.143.0_1.9.30 > v1.143.1_1.10.2
233 Replies
:wave: Hey @ONI,
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_01GY0DAKGXDEHE263BCAYEGFJA
Checklist
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.You have to use the new data structure
and disabel it in Immich
humm
shit this looks hard ugh
Ill try to review this later is the rsync run in one of the containters or in truenas shell?
must be truenas shell I take it
Yes
might need to add sudo before the rsync
And it varies depending on your setup
Btw if you need help, ping me, I can assist
ok thanks I might do that
did this update just come out that is needing us to migrate?
TrueNAS change
The latest update deprecated the old storage
but you had the opportunity to migrate for multiple months
ah got yah I never noticed that humm ok thx
Yeah no worries, now you're just forced to migrate
Btw, if the migration has been done without issue you can /close this ticket 🙂
Ok will try it today
Oh ok, no worries, it's just that I wanted to know if it was already done or not
If you have any questions/issues, you can ask them
"If you were using ixVolume (dataset created automatically by the system) for Immich data storage, the path to the data should be /mnt/.ix-apps/app_mounts/immich/. You have to use this path instead of /mnt/tank/immich/ in the rsync command above, for example:"
How do I know if im using this? Im using the app from the truenas chart



it isnt clear where pgData goes?
rsync -av /mnt/tank/immich/library/ /mnt/tank/immich/data/library/
rsync -av /mnt/tank/immich/upload/ /mnt/tank/immich/data/upload/
rsync -av /mnt/tank/immich/thumbs/ /mnt/tank/immich/data/thumbs/
rsync -av /mnt/tank/immich/profile/ /mnt/tank/immich/data/profile/
rsync -av /mnt/tank/immich/video/ /mnt/tank/immich/data/encoded-video/
rsync -av /mnt/tank/immich/backups/ /mnt/tank/immich/data/backups/
then /mnt/tank/immich/pgData would go to /mnt/tank/immich/data/pgData?
Doesnt data and pgData have to be their own dataset? or can pgData be inside the data dataset?

should I just make a new top level dataset? Immich2 ? kinda unclear here
I think its set up copying data now
man rsync takes forever on 600 gb ugh
you were already using a dedicated dataset for pgData, so there is no need to move it
Ad you said data and pgData have to be their own separate dataset
in the end (after you'll remove all other datasets) you should have
Immich (Parent, used only for "order")
data (containing: backups, library, upload, encoded-video, profile, thumbs)
pgData (like you already have now, that contains the database)
So for you case, there is no need to rsync pgData
huh I dont need to rsync pgData?
what I have atm

rsync -av /mnt/Files/Immich/library/ /mnt/Files/Immich2/data/library/
rsync -av /mnt/Files/Immich/upload/ /mnt/Files/Immich2/data/upload/
rsync -av /mnt/Files/Immich/thumbs/ /mnt/Files/Immich2/data/thumbs/
rsync -av /mnt/Files/Immich/profile/ /mnt/Files/Immich2/data/profile/
rsync -av /mnt/Files/Immich/video/ /mnt/Files/Immich2/data/encoded-video/
rsync -av /mnt/Files/Immich/backups/ /mnt/Files/Immich2/data/backups/
rsync -av /mnt/Files/Immich/pgData/ /mnt/Files/Immich2/pgData/
I think I ran the first one now to do the rest
can I open multiple shells and run all these at once or not recommened?Well if you create a new dataset, yes then you need to rsync it
Can do multiple shells
I just used sudo mv "original path" "new path" went quick enough for me.
but won't necessary speed up
In the truenas shell
Well you can if you like the risk
As if anything goes wrong then it's harder to recover
also is there a way to verify
rsync -av /mnt/Files/Immich/library/ /mnt/Files/Immich2/data/library/
if this fully transfered or to recopy and not paste if anything is there already for each file?
I left it and went to bed and idk if it all copied looking like it didntI have backups. As everyone should so there wasn't much risk.
I have it snapshotted but backing up immich is too complex for me atm
run it again
it will only copy non copied files
Good for you but I rather be safe
is it ok to just copy pgData then if all is good competely delete immich dataset later working only with immich2
Yes
but only once everything is good
you can even rename immich2 to immich
yep yep ok. and pdData has netdata as user and all that
didnt think of that will do after the dust settles
you could have even reused the immich dataset for your commands, but well... too late now
Yes, pgData should have these

I see leave pgdata, and add data/ in immich
group docker humm ok
It's not used (as you can see with the acces mode) but that's how TrueNAS scripts set it by default
looking at this I dont even have enough space to double copy all this do I?
Well
Might be close
BUT

you could avoid rsyncing video and thumbs
those can be regenerated by Immich
they are in library?
video I mean thumbs is yah generated
they're not, but they're generated based on library (or upload , if you don't have the storage template on) content
Soooo, as long as you have the originals, it's fine
rm -rf /mnt/Files/Immich2/data/thumbs/
I copied some so this is good to wipe that folder yah?Hummb
naj
wait
delete only the uuid folders inside
this way you won't need to recreate the folder and the .immich file inside it
if they've already been rsynced
how do I do that?
press "tab" at the end of the path
it should suggest what's inside it
well inside thumbs

both of these paths u mean?
yes
well delete thumbs
ok will delete them
we will create the folder again after that
you'll have to do it for encoded-video anyway

ok done will copy the rest but not thumbs and video
To create the encoded-video and thumbs folder it's easy
just cd into data
then

need to add myself as owner here first I guess
oh no
just prepend all your commands with "sudo"
ugh I see
the guide should be updated (pr is already made) to reflect that
that was a oopsie on my side when I first wrote it
no worries makes sense
ok copying the library now everything else is copyied this will probably take a hour
be back in like 30m
Still going...
Yeah, it takes times, no problem
is this like a big update or just they finally depricated the storage type on this update?
TrueNAS deprecated the old storage config on 1.143 update I think
ah humm ok
Not Immich fault here
And it's made to simplify setup/avoid user issues
how high till I should be worried? 80?

TrueNAS will throw warning
But as you'll later on delete the old data, you'll reclaim space no worries
ok
It'll slow things down if you go above a certain space amount, but it should still works (as long as it's not 98/99%)

nice
So everything has been rsynced?
I think so, ill probably run all the others but thumbs and video again to be double sure then try to start up the app following the guide
all the other rsync besides library take like 1 min
Oh yeah
Before you should create thumbs and encoded-video folder, if not already done
ok will do this
well I meant before following the rest of the guide
But yeah
yah
If you want I can guide you through it, if you prefer
Or double check what you do, this way you're sure you don't mess up smth
Oh well
You were on 1.143.0
So this should be straightforward
"just install immich again"
or point it to your new datasets
done
So rsync -av /mnt/Files/Immich/video/ /mnt/Files/Immich2/data/encoded-video/ dont need to do this or make encoded-video folder?
don't do the rsync
but youve done this
right?
oh shit i made it already right
k
so ready to go now

data

pgData


not sure why one says root then wheel humm
Mmmh, it should work, but

Make it look like this
and then click save

these are both userid and group 999
yep, that is fine
That's how Automatic permissiosn sets it
it changes too this when I type it but its the same

and only owner has any access so it's just to follow the "defaults"
ok
Now you can install immich
or modify the one that you already have
ok ill modify it
should I change the drives to HDDs?
they are not ssds even tho I have that option checked?
Yes, the default is SSD because it's recommended to use these (both By TrueNAS and Immich) for the database
so set to hdd then?
But selecting HDD optimize some db stuff for HDD, so yes, select it
does it matter to check enable acl for these paths
Don't, as we already set them
Enabling is used to set them from the app config I think (I never used the option)
and dont check automatic perms because we did that
correct
Ye

where is all the other storages like library
NO
that is the point of the new structure, everything is nested into data
so you have to select "data" not "upload"
Data Storage (aka Upload Location)
oh I see kinda my bad

It's because in Immich official docker docs it's called Upload location
machine learning temp?
yep, can be set to a dataset also, but it holds the model, so don't really necessary to save it
as it can be redownloaded

Noo?
Wait
were these your defaults?
yah
well its what I had
it was working fine tho
You come from an oooold version
change it to 568
on both
dedicated "apps" user, it's a bit more secure
got yah
(and it's the now default for almost all apps)
uh maybe half a year ago not that old
maybe a bit more idk
has been changed around that
but was 0 from beginning until x months ago



What is your system?
Like cpu/gpu?
and ram
hummmmmmmm
how can I find out in shell?
Truenas Dashboard
should have all informations on that

wait you're on 24.10
idk I just always hit update
on everything
give immich a bit more ram 8192 instead of 4096
ok sure
I'll show you smth just after then
I didnt realize I was limiting ram so much actually....
That's the default
Immich recommends at 6gb for optimal. Giving it more is fine also, as it wont use it all unless it needs it
ok ill save and see if it works
what is labels config for?
I wish I knew
It ain't used by Immich
But it's in the apps template for TrueNAS apps, that's why it's there
starting
click on the third button to see the logs
next to the server line on the workloads widget

"Workloads" on the bottom right of your image
there is the "server" line
once it's say starting
click on the third icon

oh its up?
Yup
no thumbs
should I update or regenerate them first
Can you try to download one or multiple images/video (random time point)
Click on them then upper right corner 3dots button, then download
(we will worry for that a bit after)
they seem to be downloading fine
Ok so update your app first
ohhh it seems to be updating
Then on Truenas
Click on system > update
There it will load a list of "train"
You can select the Fangtooth one, to update to the latest stable version
oh why should I update to fangtooth from eletric eel?
wont that kill some of my apps or smth?
Well, to use the latest stable version
No, you're on a good EE version
So this should work fine and you won't loose anyhting

and because it added new functions/bug fixes: https://www.truenas.com/docs/scale/25.04/gettingstarted/scalereleasenotes/
25.04 (Fangtooth) Version Notes
Highlights, change log, and known issues for TrueNAS 25.04 release versions.
FT is just a more up to date version of TNS?
Yes, there is a major version in april (.04) and in october (.10)
So you can set a reminder as in 1-2 month you could switch to the latest which will be 25.10
do u think my apps will break?

You're on 24.10.2.4
which is above 24.10.2.2
And if it was going to break your app, you wouldn't have been able to be this up to date on Immich
humm ok ill run the update soon
and switch ugh main branches
then I can update immich again or?
And with 25.10 TrueNAS should switch to a better train system, where you'll be able to select "critical, basic, or enthusiast" profile
for immich in general or?
I think the default will be basic and this way it will propose major versions without you changing it
No, for TrueNAS versions themselves
ohhh snap
You can update Immich now, and TrueNAS after
Or the otherway around
both should work fine
they last update broke a few of my apps like shoko server and it was a pain
that*
they got ride of half the apps or whatever it was
Yes, they switch from k8s to docker
so a lot of apps had to be converted, but now they're on par with what was there before (and even have more apps)
ok so I need to now regenerate all thumbs and transcode all videos?
or just slowly run everything over time
this is a local ui for mine? humm
Well, it asks you to put your IP or domain for your Immich
then it redirects to it
huh interesting
saved in your web browser, so no data is sent to Immich
got yah ok
I will run these then monitor and see if all looks good then later delete that immich data set
Yeah, it's great to make sure people go where we want them to go in the UI
then remane immich2 to immich, update the app, restart it
to rename Immich, there is a zfs command
ah haha makes sense
Thanks so much for your help! I loving immich and donated as well great stuff
and you'll have to stop Immich app, and edit it after that
so glad to be free of google photos and my 2.99/m bill
Yeah
Well you don't really spare a lot of money with selfhosting
but you learn stuff and you know where your data is
haha well with photos videos and storage its nice
jellyfin, immich ect
not complaining
Yeah definitely, but servers uses energy, disk aren't cheap, and you need backups so even more disk
And I agree, I use Immich since the day I discovered it
And I like helping people here to make their experience also great
I also try to contribute, but I'm not an expert in code so I do the little thing I know haha
Very cool!
to rename, ping me here or in the #truenas channel, if you want me to assist on that
Ok will do
Thanks!

you think the diff in size is the videos folder
I have ran video transcode videos maybe I should try all again?
it seems to be working perfectly
Did you have snapshtot enabled on your previous datasets?
should have yah
This might expplain it then
humm
ok yah maybe
Ie you uploaded a video of x gb
then it made a transcode
then you deleted videos
you still have a snapshot of video + transcode stored
humm ok usually dont delete stuff tho but couldbe
cd into your libray (old) and do a du-sh in there
and into /data/library
can i stop immich and rsync the video dir?
then du -sh there also
ah ok
I would not rsync the video one
lets see
ok
if a video hasn't been transcoded, it means that there was no need (like you changed transcode settings maybe)
You can run the transcode job again on "missing" maybe it missed some
btw updated to fangtooth very nice
no problems
how do u choose which train dontsee that option tho
will be only on goldeye (so next version)
ahh got yah
or Halfmoon, I can't rememeber exactly
not worth updating to that now?

let me try the other dir
Goldeye is in Release candidate, so it's more stable than BETA, but not as stable as a "official" release
So I would wait a few weeks
gotcha

ok so should be good then yah
Yes
Maybe you stopped the process of transcoding video
ok ill delete the old volume soon
when you updated
yah could be
So rerun the job on at least missing maybe
either the app or TrueNAS
ok
To migrate to 2.0 I can just hit the update button on true Nas when it see it yah?
Yes!
All recent changes were made to make the app ready for "stable" now it is just a formality, to make it more official (while it also brought some changes)
I see ok
great
And from what I've read from the notes, the breaking changes would introduce a major version change (so go from 2 to 3 for example)
But It might be possible that changes are made on the TrueNAS that are independant of Immich (I hope not, but I can't promise it will never happen)
If you have other question in the future about TrueNAS (or Immich on TrueNAS), you can ask them in the #truenas channel btw (like ping me for the renaming of the dataset if you need/want to)
At the same time, as the initial issue is resolved here you can /close this ticket
Ok I'll close it thanks so much for all ur help
Renaming I just stop the app, rename the data set, fix the path on app, restart?
Should be that yeah
zfs rename to rename
but oyu have to be in /mnt
then use full path
Uhh can't do it in ui?
nah
Maybe ?
I'll check got yah thanks!
so in /mnt you do
zfs rename MyPoool/apps/immich2 MyPoool/apps/immich
you obviously adapt the path
Ok great

sudo?

nice sudo worked