0

EDIT: I forgot to add /mnt/storage has been mounted using mergerfs (pooling 2 drives which are formatted as ext4)

I am running Lubuntu 22.04.2 and have run the following commands (note the user radarr belongs to the group media):

sudo setfacl -Rm  u:radarr:rwx /mnt/storage/Films
sudo setfacl -dRm u:radarr:rwx /mnt/storage/Films
sudo setfacl -Rm  g:media:rwx  /mnt/storage/Films
sudo setfacl -dRm g:media:rwx  /mnt/storage/Films

EDIT: this is the output of getfacl /mnt /mnt/storage /mnt/storage/Films:

getfacl: Removing leading '/' from absolute path names
# file: mnt
# owner: root
# group: root
user::rwx
group::r-x
other::r-x

file: mnt/storage

owner: ali

group: root

user::rwx user:sonarr:rwx user:radarr:r-x group::rwx group:media:r-x mask::rwx other::r-x

file: mnt/storage/Films

owner: ali

group: ali

user::rwx user:radarr:rwx group::rwx group:media:rwx mask::rwx other::r-x default:user::rwx default:user:radarr:rwx default:group::rwx default:group:media:rwx default:mask::rwx default:other::r-x

However, when I test write permissions using:

sudo -u radarr test -w /mnt/storage/Films; echo "$?"

this returns 1 instead of 0, even after rebooting, so I think I have misunderstood something. Is there an additional command required that I have missed?

ali
  • 1
  • What is /mnt/storage? How is it mounted? Also, please [edit] your question and add the output of getfacl /mnt /mnt/storage. – terdon May 02 '23 at 15:42
  • The user radarr probably does not have execution (search) permission for /mnt and/or /mnt/storage: sudo -u radarr bash -c 'test -x /mnt; echo $?; test -x /mnt/storage; echo $?' – Hauke Laging May 02 '23 at 15:50

1 Answers1

0

This was an oversight on my part: I had failed to include the option posix_acl=true when calling mergerfs in /etc/fstab. Adding this option and rebooting has fixed the issue.

ali
  • 1