解决方案:
首需要切换到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、输入“:w”(保存文件)
6、输入“:q”(退出)

这样就把自己加入了sudo组,可以使用sudo命令了。

is not in the sudoers file 解决(转)的更多相关文章

  1. 【linux】xx is not in the sudoers file 解决办法

    原帖地址:http://blog.sina.com.cn/s/blog_4ef045ab0100j59t.html 我用的是redhat5.4,在一般用户下执行sudo命令提示llhtiger is ...

  2. Linux下is not in the sudoers file解决方法

    最近在学习linux,在某个用户(xxx)下使用sudo的时候,提示以下错误:xxx is not in the sudoers file. This incident will be reporte ...

  3. Linux中“is not in the sudoers file”解决方法

    当在终端执行sudo命令时,系统提示"hadoop is not in the sudoers file": 其实就是没有权限进行sudo,解决方法如下(这里假设用户名是cuser ...

  4. Linux sudo 错误:XXX is not in the sudoers file 解决办法

    最近在学习linux,在某个用户(xxx)下使用sudo的时候,提示以下错误:xxx is not in the sudoers file. This incident will be reporte ...

  5. 关于Ubuntu下is not in the sudoers file解决方法

    当我在postgres用户下去执行sudo vim demo.sql需要用管理员权限运行时,并且输入本用户的密码,但是输入之后提示如下: postgers is not in the sudoers ...

  6. [RedHat]“is not in the sudoers file”解决方法

    当在终端执行sudo命令时,系统提示“luckchengis not in the sudoers file”: $ sudo ls Password: luckcheng is not in the ...

  7. 用户不在sudoers文件中怎么办,ziheng is not in the sudoers file解决方法

    sudo是linux系统中,用来执行需要权限命令,但是一些朋友使用sudo时,出现下面的错误“ziheng is not in the sudoers file. This incident will ...

  8. [转]Linux下is not in the sudoers file解决方法

    来源: http://jingyan.baidu.com/article/2a1383284bb3e8074a134f2d.html 当我们使用sudo命令切换用户的时候可能会遇到提示以下错误:xxx ...

  9. is not in the sudoers file解决方法

    用sudo时提示"xxx is not in the sudoers file. This incident will be reported.其中XXX是你的用户名,也就是你的用户名没有权 ...

  10. Ubuntu技巧之 is not in the sudoers file解决方法

    转自:http://www.linuxidc.com/Linux/2010-12/30386.htm 1)进入到root用户下. 2)添加文件的写权限.也就是输入命令"chmod u+w / ...

随机推荐

  1. python 获取对象信息

    当我们拿到一个对象的引用时,如何知道这个对象是什么类型.有哪些方法呢? 使用type() 首先,我们来判断对象类型,使用type()函数: 基本类型都可以用type()判断: >>> ...

  2. UIDynamic(一)

    UIDynamic(一) 前言 最近看了一下UIDynamic,UIDynamic是13年WWDC出的技术.其实本人一直热衷于比较有趣的动画,特别是带物理力学的动画,感觉物理力学就是动画的灵魂,一直想 ...

  3. IEnumerable和IEnumerator 详解

    初学C#的时候,老是被IEnumerable.IEnumerator.ICollection等这样的接口弄的糊里糊涂,我觉得有必要切底的弄清楚IEnumerable和IEnumerator的本质. 下 ...

  4. 【转】安装Ubuntu 15.10后要做的事

    Ubuntu 15.10发布了,带来了很多新特性,同样也依然带着很多不习惯的东西,所以装完系统后还要进行一系列的优化. 1.删除libreoffice libreoffice虽然是开源的,但是Java ...

  5. 授予普通域用户远程桌面连接DC/客户端权限

    普通域用户通过远程桌面登录DC: 1)将该用户加入到 Remote Desktop Users 组中

  6. shell重定向调试信息

    shell重定向调试信息 fulinux ******************************************************************************* ...

  7. [010]Try块和异常处理

    Throw表达式和try块的定义如下: 1. throw 表达式,错误检测部分使用这种表达式来说明遇到了不可处理的错误.可以说,throw 引发了异常条件. 2. try 块,错误处理部分使用它来处理 ...

  8. 文件和目录之link、unlink、remove和rename函数

    任何一个文件可以有多个目录项指向其i节点.创建一个指向现有文件的链接的方法是使用link函数. #include <unistd.h> int link( const char *exis ...

  9. 文件I/O之/dev/fd

    较新的系统都提供名为/dev/fd的目录,其目录项是名为0.1.2等的文件.打开文件/dev/fd/n等效于复制描述符n(假定描述符n是打开的). 在下列函数调用中: fd = open( " ...

  10. 在iOS上自动检测内存泄露

    手机设备的内存是一个共享资源.应用程序可能会不当的耗尽内存.崩溃,或者遭遇大幅度的性能降低. Facebook iOS客户端有很多功能,并且它们共享同一块内存空间.如果任何特定的功能消耗过多的内存,就 ...