Linux学习笔记 --- xxx is not in the sudoers file

xiaoxiao2021-02-28  96

在Centos下没使用root用户的时候,操作root用户权限可操作的文件的时候。需要使用sudo命令,

但是当你使用的时候sudo mv, cp等命令的时候会报错,出现以下提示信息:

解决方案是切换到root用户,输入

visudo

找到root ALL=(ALL) ALL,在下面添加一行

xxx ALL=(ALL) ALL 其中xxx是你要加入的用户名称

保存退出,下次再使用sudo的时候就可以了。

转载请注明原文地址: https://www.6miu.com/read-50741.html

最新回复(0)