Linux:user is not in the sudoers file. This incident will be reported 解决方法

学习自:user is not in the sudoers file. This incident will be reported 解决方法_一路奔跑94的博客-CSDN博客

1、原因

没有在权限文件中说明该用户具有sudo权限

2、解决步骤

1)以root身份去/etc/sudoers文件中,编辑

vi /etc/sudoers

2)在root ALL=(ALL) ALL之下添加一行

xxx ALL =(ALL) ALL

3)保存退出,:wq!

4)再切换为该用户,即可sudo执行之前的命令了

posted @   ShineLe  阅读(425)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· PowerShell开发游戏 · 打蜜蜂
· 在鹅厂做java开发是什么体验
· 百万级群聊的设计实践
· WPF到Web的无缝过渡:英雄联盟客户端的OpenSilver迁移实战
· 永远不要相信用户的输入:从 SQL 注入攻防看输入验证的重要性
点击右上角即可分享
微信分享提示