Unable to read NFSv4 ACLs from shell

gordon19284

Dabbler
Joined
Dec 13, 2021
Messages
14
I don't seem to be able to read NFSv4 ACLs from the command line with SCALE. See my screenshot: I have given the user "gordon" recursive "Full Control" ACLs for the "misc_backups" dataset. However, when I go to the shell to view and edit the ACLs for individual files or directories, no ACLs show up. `getfacl` just shows POSIX permissions:

Code:
root@truenas[/mnt/backups]# getfacl misc_backups
# file: misc_backups
# owner: root
# group: root
user::rwx
group::r-x
other::r-x


The ACLs work as expected, but since I can't view or manipulate them from the command line and the GUI doesn't let you edit the ACLs on anything but the dataset directory itself, I can't change the ACLs for any of my files. Is there something I'm missing here?

For the ZFS dataset, I have NFSv4 ACLS enabled with the Passthrough option.

TrueNAS-SCALE-22.02-RC.1-2
 

Attachments

  • truenas_acls.png
    truenas_acls.png
    1.2 MB · Views: 163

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
We generally recommend using the APIs. For interacting with NFSv4 ACLs, you should use nfs4xdr_getfacl and nfs4xdr_setfacl if you must do that through CLI.
 

paper_oasis

Cadet
Joined
Jul 11, 2023
Messages
2
We generally recommend using the APIs. For interacting with NFSv4 ACLs, you should use nfs4xdr_getfacl and nfs4xdr_setfacl if you must do that through CLI.
How does one go about using the API?
When I found that I could use the web UI to modify the ACLs for dataset roots, but couldn't (or at least couldn't figure out a way) to modify files and directories within the dataset, I dropped to SSH and started messing about in there using nfs4xdr_setfacl
But if APIs are the recommended way, how do I get started? Is there some software tool I need to use?
Just linking me to relevant documentation is fine if you'd like.
 
Top