Bel*_*dez 7 rhel permissions files
这是 RHEL5 机器上的权限:
[root@server1 belmin]# ls -la | egrep '\.(bash_profile)?$'
drwx------ 9 belmin belmin 4096 Sep 16 14:29 .
drwxr-xr-x 40 root root 4096 Sep 2 15:32 ..
-rw-r--r-- 1 belmin belmin 801 Aug 25 2011 .bash_profile
Run Code Online (Sandbox Code Playgroud)
但是,我在执行mv操作时收到错误消息:
[root@server1 belmin]# mv .bash_profile{,.backup-20140916}
mv: cannot move `.bash_profile' to `.bash_profile.backup-20140916': Operation not permitted
Run Code Online (Sandbox Code Playgroud)
看到了这个类似的问题,但那是关于一个NFS坐骑,这是一个ext3坐骑:
[root@server1 belmin]# df -P .
Filesystem 1024-blocks Used Available Capacity Mounted on
/dev/sda3 28794584 7901184 19430684 29% /
[root@server1 belmin]# mount | grep sda3
/dev/sda3 on / type ext3 (rw)
Run Code Online (Sandbox Code Playgroud)
Selinux 已启用,但我在 syslog 中没有看到任何相关的审核消息。
有什么建议?
Scy*_*aud 10
检查是否设置了不可变标志.bash_profile:
lsattr .bash_profile
Run Code Online (Sandbox Code Playgroud)
您可以使用以下方法删除它:
chattr -i .bash_profile
Run Code Online (Sandbox Code Playgroud)
HTH,干杯