Since update to v8.2.1 backups fail with "Too many empty directories"
-
@girish said in Since update to v8.2.1 backups fail with "Too many empty directories":
you can disable immich backups and then the system backup will succeed.
Yeah, that's the workaround i ended up with for now.
But i would really like to get my Immich start updating again (without compromising on the backup process). It's already 3 versions behind.
@girish said in Since update to v8.2.1 backups fail with "Too many empty directories":
Which paths inside immich are they in?
find /mnt/immich/i -type d -empty /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/c7 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/96 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/01 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/09 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/36 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/2c /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/52 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/70 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/a3 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/93 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/33 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/0b /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/b7 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/9c /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/7d /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/3e /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/7c /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/d9 /mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/82/82 ...
-
@jagan said in Since update to v8.2.1 backups fail with "Too many empty directories":
Absolutely no idea how to proceed.
Those files are images (png). They should not be executable. You can go to the Web Terminal and run something like this:
find /app/data/public/wp-content/plugins/updraftplus -type f -exec chmod a-x {} +
Do this for other places which have 'x' bit on files as well. Generally, /app/data should not have any executable files (unless you have some scripts there).
-
-
@shrey can you run the Migration job in the end of the jobs section within Immich? https://immich.app/docs/administration/jobs-workers#jobs
At least on my instance it purged most of the empty dirs. This seems to be a one-time housekeeping job. Not quite sure though why this is not run by default in Immich and needs to be manually triggered.
-
@nebulon said in Since update to v8.2.1 backups fail with "Too many empty directories":
@shrey can you run the Migration job in the end of the jobs section within Immich? https://immich.app/docs/administration/jobs-workers#jobs
Tried that.
But on my Immich instance (v1.123.0), it seems to have no effect on the concerned empty directoriesroot@apps:~# find /mnt/immich/i -type d -empty | wc -l 56587
-
@nebulon said in Since update to v8.2.1 backups fail with "Too many empty directories":
so are all those empty dirs within the upload folder in your case?
Except for :
/mnt/immich/i/typesense
all of the paths seems to be:
/mnt/immich/i/upload/upload/b4fe288d-66ef-42ac-b74a-14ec12220a71/../..
@nebulon said in Since update to v8.2.1 backups fail with "Too many empty directories":
Also did you happen to change the data layout at some point in the past?
I think i migrated the app storage from local disk to a volume, around 5 months ago.
-
Ah then this looks like an upstream bug https://github.com/immich-app/immich/issues/9202 with the discussion at https://github.com/immich-app/immich/discussions/9204 so looks like their strategy is that the user has to manually purge those.
-
@SebGG this is normal behavior starting from 8.2 . we put this check in place to prevent backup or app data corruption .
-
Too many empty folders. This means that something suspect is going on with the app . When you create too many empty dirs, you run out of inodes over time and this leads to fs corruption. Since empty dirs don't show up in du listings, people wonder why fs is becoming fullish when files are not taking space
-
Too many executables. This is a security issue if data files are executable. In most cases, this is because user used a tarball which had incorrect permissions inside it . Or the mount permissions or wrong.
So, the backup failure is a way for end users to check on both the things above.
-