[SOLVED] Admin is not allowed to run sudo on localhost. This incident will be reported.
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Admin is not allowed to run sudo on localhost. This incident will be reported.
hi all,
i am facing the issue with sudo commands, as i have added myself into sudoers. but now this error is occuring.
Admin is not allowed to run sudo on localhost. This incident will be reported.
Admin is not allowed to run sudo on localhost. This incident will be reported.
nitsss
Oh Boy are you in big trouble now ... I hope your mom don't find out too...
ensure you're in the group of sudo, or add yourself to a wheel group that is sometimes in sudo, create a group called wheel, or sudo then add yourself to that group ensure it is in the sudoers file,
you can also have it so that you do not have to use a password if you did not know that, just type sudo <command> press enter
Code:
## Uncomment to allow members of group wheel to execute any command
# wheel ALL=(ALL) ALL
## Same thing without a password
#(percent mark)wheel ALL=(ALL) NOPASSWD: ALL
or this will get a user w/ no password needed
Code:
user-name ALL=(ALL) NOPASSWD: ALL
if you want password needed then
Code:
user-name ALL=(ALL) ALL
if you put your user name into a group that is in sudoers then just add yourself to that group instead
and make sure sudo is installed
i m using CentOs 6.
After adding the Admin user in visudo file, when i m running sudo command below is the result.
[Admin@localhost ~]$ sudo apt-get update
[sudo] password for Admin:
sudo: apt-get: command not found
...
PLEASE tell me you're not trying to implement the abomination that is Ubuntu's root policy on CentOS!
Leave that crap where it belongs, [in the trash] on Ubuntu, don't let it infect the rest of the Linux world. Sudo is a very powerful tool for allowing a SPECIFIC user to run a SPECIFIC task without having to get out the root password. It was never designed to give a user complete administrative privileges using their normal user password. There already IS a user who can do that, it's called root.
This sudo abuse championed by Ubuntu does not make things better or safer, it compromises security in order to make Linux more Windows-like, so it's not as "scary" for new users. Do yourself a favor and learn how to PROPERLY administer a Linux system, don't try to turn CentOS into another Ubuntu.
Last edited by suicidaleggroll; 12-29-2015 at 08:56 AM.
PLEASE tell me you're not trying to implement the abomination that is Ubuntu's root policy on CentOS!
Leave that crap where it belongs, [in the trash] on Ubuntu, don't let it infect the rest of the Linux world. Sudo is a very powerful tool for allowing a SPECIFIC user to run a SPECIFIC task without having to get out the root password. It was never designed to give a user complete administrative privileges using their normal user password. There already IS a user who can do that, it's called root.
This sudo abuse triggered by Ubuntu does not make things better or safer, it compromises security in order to make Linux more Windows-like, so it's not as "scary" for new users. Do yourself a favor and learn how to PROPERLY administer a Linux system, don't try to turn CentOS into another Ubuntu.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.