LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This 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


Reply
  Search this Thread
Old 02-01-2013, 12:13 AM   #1
NM04
Member
 
Registered: Jan 2011
Distribution: Back Track,Fedora,centos
Posts: 240

Rep: Reputation: 14
Question need to have ubuntu 12.10 root privilege


hi all,
i have installed ubuntu 12.10 on VMware 9.0.
1) how do i switch to root user ? I tried 'su' it prompts for the password i gave the pass which i assigned initially then also it is not giving me root privilege.
 
Old 02-01-2013, 12:33 AM   #2
ChooseLife
Member
 
Registered: May 2007
Distribution: Ubuntu, RHEL, Slackware
Posts: 49

Rep: Reputation: 17
try
sudo su -

su asks you for root's password, sudo asks for the user's password
 
Old 02-01-2013, 12:38 AM   #3
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,356

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
As above, its quirk of Ubuntu (sigh ..) that it disables the root acct and assigns full privileges via sudo to the first user acct created at install time.
Definitely not Std *nix procedure.
 
Old 02-01-2013, 01:03 AM   #4
ChooseLife
Member
 
Registered: May 2007
Distribution: Ubuntu, RHEL, Slackware
Posts: 49

Rep: Reputation: 17
Quote:
Originally Posted by chrism01 View Post
As above, its quirk of Ubuntu (sigh ..) that it disables the root acct and assigns full privileges via sudo to the first user acct created at install time.
Definitely not Std *nix procedure.
[pov]You know, it was a huge pet peeve of mine at first, until I realized that by doing so Ubuntu's probably done more for the "use a non-root account for daily work (on a desktop Linux)" principle than a decade of preaching within the community... [/pov]
 
Old 02-01-2013, 01:44 AM   #5
descendant_command
Senior Member
 
Registered: Mar 2012
Posts: 1,876

Rep: Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643
*cough*
 
Old 02-01-2013, 01:46 AM   #6
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,356

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
I'm not convinced ... If someone is daft enough to run all day as root, they'll run all day as 'sudo su -', which is the same thing (effectively).
YMMV
 
Old 02-01-2013, 03:35 AM   #7
ChooseLife
Member
 
Registered: May 2007
Distribution: Ubuntu, RHEL, Slackware
Posts: 49

Rep: Reputation: 17
Quote:
Originally Posted by chrism01 View Post
I'm not convinced ...
Yeah, this is highly subjective, just sharing an opinion because for a long time I felt strongly opposite.

Quote:
Originally Posted by chrism01 View Post
If someone is daft enough to run all day as root, they'll run all day as 'sudo su -', which is the same thing (effectively).
I think the demographics that is protected by this method would not know where to enter "sudo su -" to begin with... Just like they don't know why they should bother creating additional accounts during/after setup when root seems to work just fine.

Last edited by ChooseLife; 02-01-2013 at 03:37 AM.
 
Old 02-01-2013, 04:05 AM   #8
abhijitkarkhanis
LQ Newbie
 
Registered: Dec 2012
Posts: 12

Rep: Reputation: Disabled
Hey,

Its seems to be you want to unlock root user in ubuntu to do this follow below instructions.

In the terminal type
sudo passwd root
(now set the password to root whatever you want)

Now if you want graphical for just logout and select other user option to login by root
and if you want to use root user on terminal follow normal su- command.

That's it !!!
 
Old 03-04-2013, 06:40 AM   #9
NM04
Member
 
Registered: Jan 2011
Distribution: Back Track,Fedora,centos
Posts: 240

Original Poster
Rep: Reputation: 14
Thumbs up

Thanks everyone for valuable inputs. I did the task using "sudo".

Quote:
Originally Posted by chrism01 View Post
As above, its quirk of Ubuntu (sigh ..) that it disables the root acct and assigns full privileges via sudo to the first user acct created at install time.
Definitely not Std *nix procedure.
I didn't know this,thanks for sharing. I think its because security reasons, wherever ubuntu is used as server, even if it gets hacked the attacker will never be able to have root access.

cheers,
nm
 
Old 03-04-2013, 06:52 AM   #10
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,356

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
No, they know its Ubuntu, so they try to crack the 1st user's passwd (all of them if needed...)
Using a real root is theoretically better, because they have to guess BOTH of the correct user's acct name & passwd, then also guess root's passwd (assuming remote root is disabled, which is normal).
With Ubuntu, they don't need to guess root passwd.

IOW, there's a reason *nix has been around since 1970 and only Ubuntu (a very recent distro of Linux) works that way.
(I believe Ubuntu derivatives may do the same).
 
Old 03-04-2013, 08:28 AM   #11
snowday
Senior Member
 
Registered: Feb 2009
Posts: 4,667

Rep: Reputation: 1411Reputation: 1411Reputation: 1411Reputation: 1411Reputation: 1411Reputation: 1411Reputation: 1411Reputation: 1411Reputation: 1411Reputation: 1411
I recommend to use 'sudo' in Ubuntu for one very simple reason: All official Ubuntu help pages and support forums assume you are using 'sudo'. If you use 'sudo' then you won't have any trouble following the documentation.
 
Old 03-14-2013, 04:34 AM   #12
NM04
Member
 
Registered: Jan 2011
Distribution: Back Track,Fedora,centos
Posts: 240

Original Poster
Rep: Reputation: 14
Question

Quote:
Originally Posted by chrism01 View Post
No, they know its Ubuntu, so they try to crack the 1st user's passwd (all of them if needed...)
Using a real root is theoretically better, because they have to guess BOTH of the correct user's acct name & passwd, then also guess root's passwd (assuming remote root is disabled, which is normal).
With Ubuntu, they don't need to guess root passwd.

IOW, there's a reason *nix has been around since 1970 and only Ubuntu (a very recent distro of Linux) works that way.
(I believe Ubuntu derivatives may do the same).
I totally agree with this, in 1st users case they have to crack only pass, but in case of root they have to crack both user name & pass. So, why people prefer ubuntu over other distros, be it a server or anything else, when many others are available ?
 
Old 03-14-2013, 06:27 AM   #13
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886
sudo has its use cases, especially on server environments, because you can give fine grained privileges to people to use applications as root without giving them total control over the machine. The way Ubuntu uses it may be fine for desktop users (in my opinion it is not, but this is a matter of taste, I would think), but is at least questionable on servers that allow password based authentication.
But anyways, on a properly secured server you use key-based athentication anyways, so regardless if an attacker manages to break into the system (which is unlikely unless he somehow gets access to your key) he still has to find out the password needed for root access, regardless if su or sudo is needed.

Quote:
So, why people prefer ubuntu over other distros, be it a server or anything else, when many others are available ?
On desktop systems it is clearly a matter of taste if you prefer a distro that makes it easy for the user with the downside of having impacts on security or if you prefer a distro with more control, with the downside that some people are annoyed that they have to switch to a different user for system maintenance. On a system that is aimed at being purely used with GUI tools (which nowadays is not that hard) the only downside of using su instead of sudo is that you have to keep in mind two passwords.

Why people use Ubuntu in server environments, honestly, I have no clue. I would always prefer a distro that aims to release a new version when it is done, not when a fixed release date is reached. I would think that the high marketshare on desktop systems leads to it being used on servers also.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
root privilege ust Linux - Newbie 4 04-16-2012 11:02 PM
Privilege Escalation - Getting 'root' privilege Rahil Parikh Linux - Security 2 12-02-2010 01:04 AM
[SOLVED] Ubuntu: How do you give sftp root privilege to user? shokemyster Linux - Newbie 17 09-23-2010 12:31 AM
root privilege nagavinodh Linux - Newbie 14 11-16-2009 12:02 PM
Identifying non-administrators w/ root privilege/ Multiple root account in use wjeanpaul Linux - Security 4 05-19-2006 08:55 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:29 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration