LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   root operations under normal user (https://www.linuxquestions.org/questions/linux-newbie-8/root-operations-under-normal-user-380160/)

phsythax 11-05-2005 06:49 AM

root operations under normal user
 
im logged in as a normal user, i want to install a program (requiring root) i know the root password, but how can i install the program under root without logging out from my normal account and then into root?

i once saw something about a command that would alow me to do root operations from a normal user terminal something like"**** root <passwordhere>"

i tried this:
"[magnus@BlahBlah ~]$ login
login: root
Password:
Error sending status request (Operation not permitted)

Login incorrect
[magnus@BlahBlah ~]$"

as you can see, didnt work.

links, hints, commands, all would be preciated :)

Nylex 11-05-2005 06:52 AM

Not too sure if this is what you mean, but you can open a terminal and type "su" (without quotes) and then your root password when prompted.

phsythax 11-05-2005 06:54 AM

that was exactley what i ment, thx for the fast anser :)

Haiyadragon 11-05-2005 07:30 AM

There's also something called sudo. It allows you to execute commands with root privileges with your own password. So you can do 'sudo vi /etc/fstab' and edit fstab as root. I find it better to work with.

phsythax 11-05-2005 07:42 AM

sounds like an hacking tool.. how can it work if it doesnt even have to use the root password?

reddazz 11-05-2005 08:02 AM

Quote:

Originally posted by phsythax
sounds like an hacking tool.. how can it work if it doesnt even have to use the root password?
Sudo is quite good and secure actually. The idea is that you give some users certain privileges, e.g. to mount cdrom drives instead of doing it as root. Obviously you need to make sure you give the user "reasonable privileges" and not be able to run everything as root.

Haiyadragon 11-08-2005 04:50 PM

Ubuntu doesn't even have a root user by default. It allows the first user (others can be configured ofcourse) to do everything through sudo. I now do the same on Slackware. It works quite nice.

It also allows me to give other users the abilty to reboot or shutdown.

purelithium 11-08-2005 05:21 PM

Quote:

Originally posted by phsythax
sounds like an hacking tool.. how can it work if it doesnt even have to use the root password?
That's hilarious!

reddazz 11-08-2005 08:14 PM

Quote:

Originally posted by Haiyadragon
Ubuntu doesn't even have a root user by default. It allows the first user (others can be configured ofcourse) to do everything through sudo. I now do the same on Slackware. It works quite nice.

It also allows me to give other users the abilty to reboot or shutdown.

The problem with Ubuntus way of using sudo is that if someone gets hold of your password, then can wreck havoc on your system because it gives the normal user all root privileges.

Hangdog42 11-08-2005 08:58 PM

Quote:

Originally posted by reddazz
The problem with Ubuntus way of using sudo is that if someone gets hold of your password, then can wreck havoc on your system because it gives the normal user all root privileges.
Good grief, I thought I was the only one bothered by the way Ubuntu handles root. I mean I like Ubuntu, and it has worked well on a couple of friends machines but I really don't see how running everything through sudo actually improves security at all. Besides, using sudo in that manner strikes me as a gross abuse of sudo.

chrism01 11-09-2005 12:45 AM

Incidentally, none of the cmds you allow via sudo should include an editor, as most editors allow you to shell out, as the current user ie root(!)

reddazz 11-09-2005 03:19 AM

Quote:

Originally posted by Hangdog42
Good grief, I thought I was the only one bothered by the way Ubuntu handles root. I mean I like Ubuntu, and it has worked well on a couple of friends machines but I really don't see how running everything through sudo actually improves security at all. Besides, using sudo in that manner strikes me as a gross abuse of sudo.
Yeah, its a good distro, but their use of sudo is why I don't recommend it to many people. Anyway most hardcore Linux users I know tend to move on to Debian or enable the root account properly.


All times are GMT -5. The time now is 06:17 PM.