现在的位置: 首页运维|APPServer>正文
is not in the sudoers file. This incident will be reported
发表于486 天前 运维|APPServer 暂无评论 ⁄ 被围观 +

出现xxx is not in the sudoers file. This incident will be reported的错误,原来是linux默认没有开启sudo权限。

解决方法:

#su -
#chmod u+w /etc/sudoers
#visudo
在root ALL=(ALL) ALLZ下 添加xxx ALL=(ALL) ALL 然后按esc键,再输入:wq!保存退出
#chmod u-w /etc/sudoers

问题解决!

禁止ssh root登录方法:

#vi /etc/ssh/sshd_config

#PermitRootLogin yes
取消注释并改为
PermitRootLogin no

保持推出,重启下sshd服务即可。

给我留言


/ 快捷键:Ctrl+Enter
不想听你唠叨×