我试图弄清楚为什么 ls 命令的输出发生了变化。我的意思是文件的组权限。
我创建了一个名为“file”的文件并更改了它的所有者和组:
[root@training group3]# touch file
[root@training group3]# ls -la file
-rw-r--r--. 1 root root 0 Sep 8 15:29 file
[root@training group3]# chown uczen file
[root@training group3]# chgrp group3 file
[root@training group3]# ls -la file
-rw-r--r--. 1 uczen group3 0 Sep 8 15:29 file
[root@training group3]# getfacl file
# file: file
# owner: uczen
# group: group3
user::rw-
group::r--
other::r--
Run Code Online (Sandbox Code Playgroud)
然后我为用户“ula”添加了额外的 rwx 权限:
[root@training group3]# setfacl -m u:ula:rwx file
[root@training group3]# getfacl file
# file: file
# owner: …
Run Code Online (Sandbox Code Playgroud)