050-720 · Question #347
How do you activate an ACL when mounting a file system manually?
The correct answer is C. mount -o acl /dev/hda5 /data. See the full explanation below for the reasoning.
Question
How do you activate an ACL when mounting a file system manually?
Options
- Amount --acl /dev/hda5 /data
- Bmount -f acl /dev/hda5 /data
- Cmount -o acl /dev/hda5 /data
- Dmount --use-acl /dev/hda5 /data
How the community answered
(61 responses)- A2% (1)
- B10% (6)
- C84% (51)
- D5% (3)
Community Discussion
5C is the one you want here. The mount command uses -o to pass filesystem options, so "mount -o acl /dev/hda5 /data" tells the kernel to enable POSIX access control lists on that partition when it gets mounted. My supervisor walked me through this when we were setting up a shared project folder, and he drilled it in that -o is always your gateway for extra mount options like acl, ro, noexec, and so on. The other flags in those choices (-f, --acl, --use-acl) are not real mount options and will just throw an error.
C is correct. The mount command uses -o to pass filesystem options, so "-o acl" tells the kernel to enable POSIX ACL support on that mount point, which is the same mechanism you use for other options like noexec, ro, or relatime.
Good call on that, and worth adding that the -o acl flag only survives until the next reboot unless you also add it to /etc/fstab, which my senior had me figure out the hard way when all our ACL settings disappeared after a restart.
C is right, mount -o passes mount options. Did you know acl vs noacl can be set in fstab too?
Right, and worth flagging for exam purposes that on modern distros ext4 often compiles acl in as a default mount option, so you only need the explicit fstab entry when you are overriding a non-default filesystem or when the grader expects you to demonstrate awareness of inherited versus explicit option scope.