- 论坛徽章:
- 0
|
在安装ltib For freescale iMX35时,出现这样的问题:
password for ltib:
This means you don't have sudo permission to execute rpm commands as root
without a password. This is needed for this build script to operate correctly.
To configure this, as root using the command "/usr/sbin/visudo",
and add the following line in the User privilege section:
ltib ALL = NOPASSWD: /bin/rpm, /opt/freescale/ltib/usr/bin/rpm
或者:
xxx is not in the sudoers file
用sudo时提示"xxx is not in the sudoers file. This incident will
be reported.其中XXX是你的用户名,也就是你的用户名没有权限使用
sudo,我们只要修改一下/etc/sudoers文件就行了。下面是修改方法:
解决方法:
1)进入超级用户模式。也就是输入"su -",系统会让你输入超级用户密码,
输入密码后就进入了超级用户模式。(当然,你也可以直接用root用)
2)添加文件的写权限。也就是输入命令"chmod u+w /etc/sudoers"。
3)编辑/etc/sudoers文件。也就是输入命令"vim /etc/sudoers",输
入"i"进入编辑模式,找到这一 行:"root ALL=(ALL) ALL"在起下面添
加"xxx ALL=(ALL) ALL"(这里的xxx是你的用户名),然后保存(就是先按
一 下Esc键,然后输入":wq")退出。
4)撤销文件的写权限。也就是输入命令"chmod u-w /etc/sudoers"。
本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u3/105630/showart_2089894.html |
|