root 用户修改文件提示无权限 chmod: changing permissions of ‘authorized_keys’: Operation not permitted

使用 lsattr 命令查看文件的属性,使用 chattr 命令的修改文件的属性。解决修改文件提示无权限:

chattr -i <file>
chattr 命令的详解参考链接【3】。

参考链接:

1、https://serverfault.com/questions/60711/chown-operation-not-permitted-for-root

2、https://www.webhostingtalk.com/showthread.php?t=569413

3、chattr 和 lsattr 命令详解

posted @ 2023-02-09 14:21  imzhi  阅读(218)  评论(0编辑  收藏  举报