Linux中出现 xxx is not in the sudoers file.This incident will be reported.
1.问题
xxx is not in the sudoers file.This incident will be reported.
2.分析
该问题的根本原因是由于Linux的超级用户权限是由sudo动态赋予的,在新增的用户不会默认赋予sudo权力,因此若需要该用户有sudo的权限,需要根据一定的规则进行赋予。
3.解决方法
以下两种方法都是基于现有的用户能够获取root权限进行,不管是root用户本身还是用户A(用户A能够使用sudo)
3.1 手动修改
1.赋予sudoer文件写权限
sudo chmod u+w /etc/sudoers
2.编辑sudoers文件,给对应的用户添加sudo权限
sudo vi /etc/sudoers
找到如下并参照书写,这里以给用户A添加sudo权限:
root ALL=(ALL:ALL) ALL
添加
A ALL=(ALL:ALL) ALL
3.撤销sudoers的写权限(否则异常)
sudo chmod u-w /etc/sudoers
Linux中出现 xxx is not in the sudoers file.This incident will be reported.相关推荐
- 【sudo错误】xxx is not in the sudoers file.This incident will be reported解决
文章目录 1.问题 2.分析 3.解决方法 3.1 手动修改 3.2 命令方式修改--sudo visudo 4.扩展说明 1.问题 xxx is not in the sudoers file.Th ...
- Ubuntu报“xxx is not in the sudoers file.This incident will be reported” 错误解决方法
Ubuntu下普通用户用sudo执行命令时报"xxx is not in the sudoers file.This incident will be reported"错误,解决 ...
- xxx is not in the sudoers file. This incident will be reported.解決方法
我们通常都是以普通用户登录linux, 在执行sudo时候会遇到 xxx is not in the sudoers file. This incident will be reported. 解决 ...
- xxx is not in the sudoers file.This incident will be reported错误
普通用户用sudo执行命令时报"xxx is not in the sudoers file.This incident will be reported"错误,解决方法就是在/e ...
- xxx is not in the sudoers file.This incident will be reported.的解决方法
xxx is not in the sudoers file.This incident will be reported.的解决方法 参考文章: (1)xxx is not in the sudoe ...
- xxx is not in the sudoers file. This incident will be reported.
sudo,用其他用户的身份执行命令. 运行该命令时,系统首先检查/etc/sudoers,判断该用户是否有执行sudo的权限,在确定有执行权限后,要求输入自己的密码(当前用户),如果密码正确,会以ro ...
- centos/Linux 解决使用sudo命令时xxx is not in the sudoers file.This incident will be reported
解决方法 切换到root用户: su 然后在root用户下输入命令: chmod u+w /etc/sudoers vim /etc/sudoers 在vim编辑器界面输入/root查询到这一行: r ...
- CentOS下添加Root权限用户‘超级用户’方法(xxx is not in the sudoers file.This incident will be reported.的解决方法)
文章目录 1.添加普通用户 2.添加sudo文件的写权限 3.编辑sudoers文件 4.撤销sudoers文件写权限 1.添加普通用户 [root@server ~]# useradd fxd // ...
- xxx is not in the sudoers file.This incident will be reported.
1.切换到root用户,运行visudo命令 visudo 2.打开的配置文件,找到这行 root ALL=(ALL) ALL,在他下面添加xxx ALL=(ALL) ALL (这里的xxx是你的用户 ...
- 【转载】xxx is not in the sudoers file.This incident will be reported.的解决方法
1.切换到root用户下,怎么切换就不用说了吧,不会的自己百度去. 2.添加sudo文件的写权限,命令是: chmod u+w /etc/sudoers 3.编辑sudoers文件 vi /etc/s ...
最新文章
- 爆肝800000秒想出低成本无人驾驶测距
- 斐波那契数列 || 猴子吃桃问题 用递归实现
- C中的危险函数(缓冲区溢出)
- PHP中的Trait方法
- java高级----Thread之CyclicBarrier的使用
- java推送数据给安卓,java – 如何从Firebase推送通知中获取数据并将其显示在Android Activity中?...
- 可视化webpart基础开发——TreeView控件读取文档库中的所有文件夹和文件(递归方法读取) ....
- java 中文域名转码_转换java方法
- 工信部发布《区块链 数据格式规范》标准(PPT全文)
- 使用Express开发小说API接口服务1.0(二)
- 带你了解敏捷和DevOps的发布策略
- 设计模式笔记零:设计模式简介
- Windows 10修改环境变量方法
- amos调节变量怎么画_AMOS 中验证性因素分析(CFA)
- 互联网之“死”:为什么开发者会排斥新技术?
- ssh图示+hibernate图示
- 爬取网易云音乐某个歌手的全部歌曲的歌词
- 【bug记录】Vue项目执行报错处理:You may need an appropriate loader to handle this file type.
- BigGAN代码解读(gpt3.5帮助)——生成器部分
- ubuntu 安装依赖包时出现The following packages have unmet dependencies: