Results 1 to 10 of 22
Im running Fedor12 on virtualbox for the first time. Im having problems using sudo. It returns that "Tsquad is not in the sudoers file. This incident will be reported."
Tsquad ...
- 01-15-2010 #1Just Joined!
- Join Date
- Jan 2010
- Posts
- 80
Fedora 12 sudo help
Im running Fedor12 on virtualbox for the first time. Im having problems using sudo. It returns that "Tsquad is not in the sudoers file. This incident will be reported."
Tsquad is the only user on that VM, i dont get why its doing this. I use sudo in ubuntu all the time with no problems, this is my first time with fedora tho.
- 01-15-2010 #2
Ubuntu uses sudo by default, while Fedora doesn't.
So you need to add yourself in the sudoers file.
Configuring SUDO
Basically, it says to type in terminal:
and below the line root ALL=(ALL) ALLCode:su --login -c 'visudo'
add the line
Code:tsquad ALL=(ALL) ALL
- 01-16-2010 #3
This will make you an "Administrator", using your password. I feel that it will make your system less secure, as you will now have two accounts that have root access. Ubuntu gets around this by not having a root account.
If you just want to be able to run commands with root privileges, this can be done using the su -c prefix, and then surrounding the command with single quotes.
Code:su -c 'yum install mplayer'
Paul
Please do not send Private Messages to me with requests for help. I will not reply.
- 01-16-2010 #4Just Joined!
- Join Date
- Jan 2010
- Posts
- 80
- 01-16-2010 #5
It doesn't take the place of sudo. It is a way to run a command with root privileges, on systems that have a root account. It will ask for the password after you enter the command. It will want the root password.
When sudo is enabled, you will use your own user password.Paul
Please do not send Private Messages to me with requests for help. I will not reply.
- 01-16-2010 #6
i disagree that it is any less secure, unless your user or root password are not very strong it shouldn't matter either way
you can configure sudo to ask for root password instead of user password if you like, the problem with su - c is that every time you do it it asks for password, if you are executing a bunch of commands in a row this is annoying, sudo has a timeout where it lets you execute stuff without being prompted over and over, but then again, if you need to execute lots as root, just su - or sudo su - then logout the root
- 01-16-2010 #7
I never said it was better, just another way. Ubuntu's popularity has skewed people's expectations on how to do things with root privileges. I enabled sudo for my account on my Fedora 12 install. I disliked it and removed it. I prefer the su -c method, or just using su. Since my account wasn't intended to be a root account, I did use a less secure password. And, I have it automatically logging me in at boot. I know, not good if you really want to be secure!

There is a reason that regular Linux users are not automatically granted administration rights, like windows does. Since it was developed as a multi-user system, you don't want everybody mucking around with the system.
This is less important on a single-user system, yet it is always important to use and practice secure procedures.Last edited by waterhead; 01-16-2010 at 12:42 PM. Reason: corrected su command
Paul
Please do not send Private Messages to me with requests for help. I will not reply.
- 01-16-2010 #8
This is what I was trying for, but didn't realize that it was possible.
I found info on doing this on the Archlinux wiki. After adding your user to the sudoers file, you add another line in the section that contain all of the "Defaults" parameters:
Now when you use sudo, it will want the root password. I think that this is acceptable, as it keeps the separation of root and user. It also should feel familiar to Ubuntu users.Code:Defaults rootpw
I might suggest this method in the future, to users with the same problem. Anyone see any drawbacks to this?Paul
Please do not send Private Messages to me with requests for help. I will not reply.
- 01-16-2010 #9
I don't really see any, as long as you have a nice strong root password it should be fine. Even having a weaker password for regular user still only compromises your own files.
- 01-17-2010 #10Just Joined!
- Join Date
- Jan 2010
- Posts
- 80
This is great info guys, thanks alot.
Im looking to get the most out of linux knowledge wise. Now out of these ways, are there any that will go the same for other distros as well?
waterhead: If i were to do what you said and make it so that sudo asks for my root account pw and not my user account pw, what is my root pw then? The only pw i remember setting up is the one for my user Tsquad. Would they be the same? If thats the case, how can i go about changing the root pw so they are not the same.


Reply With Quote
