xxx is not in sudoers file 解决(转)
解决方案:
首需要切换到root身份
$su -
(注意有- ,这和su是不同的,在用命令"su"的时候只是切换到root,但没有把root的环境变量传过去,还是当前用户的环境变量,用"su -"命令将环境变量也一起带过去,就象和root登录一样)
然后
$visudo //切记,此处没有vi和sudo之间没有空格
1、移动光标,到最后一行
2、按a,进入append模式
3、输入
your_user_name ALL=(ALL) ALL
4、按Esc
5、输入“:wq”(保存文件)
这样就把自己加入了sudo组,可以使用sudo命令了。
如图:

xxx is not in sudoers file 解决(转)的更多相关文章
- Linux sudo 错误:XXX is not in the sudoers file 解决办法
最近在学习linux,在某个用户(xxx)下使用sudo的时候,提示以下错误:xxx is not in the sudoers file. This incident will be reporte ...
- 【linux】xx is not in the sudoers file 解决办法
原帖地址:http://blog.sina.com.cn/s/blog_4ef045ab0100j59t.html 我用的是redhat5.4,在一般用户下执行sudo命令提示llhtiger is ...
- Linux下is not in the sudoers file解决方法
最近在学习linux,在某个用户(xxx)下使用sudo的时候,提示以下错误:xxx is not in the sudoers file. This incident will be reporte ...
- 关于Ubuntu下is not in the sudoers file解决方法
当我在postgres用户下去执行sudo vim demo.sql需要用管理员权限运行时,并且输入本用户的密码,但是输入之后提示如下: postgers is not in the sudoers ...
- Linux中“is not in the sudoers file”解决方法
当在终端执行sudo命令时,系统提示"hadoop is not in the sudoers file": 其实就是没有权限进行sudo,解决方法如下(这里假设用户名是cuser ...
- [转]Linux下is not in the sudoers file解决方法
来源: http://jingyan.baidu.com/article/2a1383284bb3e8074a134f2d.html 当我们使用sudo命令切换用户的时候可能会遇到提示以下错误:xxx ...
- is not in the sudoers file解决方法
用sudo时提示"xxx is not in the sudoers file. This incident will be reported.其中XXX是你的用户名,也就是你的用户名没有权 ...
- [RedHat]“is not in the sudoers file”解决方法
当在终端执行sudo命令时,系统提示“luckchengis not in the sudoers file”: $ sudo ls Password: luckcheng is not in the ...
- 用户不在sudoers文件中怎么办,ziheng is not in the sudoers file解决方法
sudo是linux系统中,用来执行需要权限命令,但是一些朋友使用sudo时,出现下面的错误“ziheng is not in the sudoers file. This incident will ...
随机推荐
- 数据结构(六)查找---多路查找树(B树)
B 树 B树与B+树 一:定义 B树(B-树)是一种平衡的多路查找树.-3树和2--4树都是B树的特例.节点最大的孩子数组称为B树的阶(order),因此,-3树是3阶B树,--4树是4阶B树. 二: ...
- Linux记录-Linux Swap分区虚拟内存相关解决方案
Swap用途:Swap意思是交换分区,通常我们说的虚拟内存,是从硬盘中划分出的一个分区.当物理内存不够用的时候,内核就会释放缓存区(buffers/cache)里一些长时间不用的程序,然后将这些程序临 ...
- Kanboard简单的可视化任务板,项目管理
采用docker安装 简单快捷 下载 docker pull kanboard/kanboard:latest 运行 docker run -d --name kanboard -p 10080:80 ...
- Spring RMI (Spring 远程方法调用)【原】
所需jar包...? 不纠结,一股脑儿全导! 源码地址:http://pan.baidu.com/s/1jG8eOmy 先放结构图如下,客户端和服务端都在一个项目中.也可以把服务端的xxx导成j ...
- spring中用到了哪些设计模式
spring中用到了哪些设计模式?(顺丰) spring中常用的设计模式达到九种,我们举例说明: 第一种:简单工厂 又叫做静态工厂方法(StaticFactory Method)模式,但不属于23种G ...
- Ubuntu18.04下vim的tab缩进设置为4个空格
在/etc/vim/vimrc最后添加如下内容 set ts = 4 set exbandtab set autoindent
- collocation
a collocation is two or more words that often go together. These combination just sound "right& ...
- JavaScript之不规则Table转化为可定点索引td节点的网格矩阵【插件】
由于解析课程表的缘故,有如下需求: 1. 将任意表格解析成独立的单元格矩阵[本次博文的缘由] 2. 根据矩阵坐标,确定任意一格的节点 /* 表格-->网格化 标记表格的位置及其对应的节点 * ...
- ajax大并发问题
今天在对项目做性能分析时发现,js代码中同时发出的多个异步请求耗时很长,查看服务器处理 时间发现,每个请求的响应都在毫秒级,但是页面请求的响应时间却在1秒左右,百思不得其解,后来仔细测试发现,这个并发 ...
- linux挂载硬盘以及卸载硬盘
1.在vmware添加硬盘 2.输入fdisk -l 查看新增加的硬盘 3.分区初始化 4.指定文件系统 5.修改fstab文件 fstab: 6.刷新验证 mount -a 挂载定义在/etc/fs ...