I wanted to set ACL for a directory. For that it is important that the device should be mounted as acl on that directory.
But I do not want to add the acl mount in /etc/fstab. So I am tempoararily mounting the device to some temporary directory as acl and setting ACL and then unmounting it. Then, I'm mounting it to the original directory.
The code is below:
tmp="/tmp1/backup"
orig="/mnt1/backup"
dev="/dev/sda2"
mkdir -p $tmp
mkdir -p $orig
mount -o acl $dev $tmp
mkdir -p $tmp/stdsymp
chgrp 557 $tmp/stdsymp
setfacl -m g:599:r $tmp/stdsymp
umount $tmp
mount $dev $orig
ll /mnt/backup shows
drwxr-xr-x 2 root _nokfsuimanage 4096 Sep 8 09:37 stdsymp
The group is being changed, but ACL is not set for the directory. Where is the problem?