LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 09-23-2009, 12:50 PM   #1
newbiesforever
Senior Member
 
Registered: Apr 2006
Location: Iowa
Distribution: Debian distro family
Posts: 2,378

Rep: Reputation: Disabled
can I unlock the root account?


I've heard that the root account in Ubuntu is locked by default. Can that be undone? I don't go into the root account often, but who are the Ubuntu designers to tell me I can't?--it's my system.
 
Old 09-23-2009, 12:55 PM   #2
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,529

Rep: Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899
Why don't you use sudo ?
However,
Use
Code:
sudo passwd root
take a look at
https://help.ubuntu.com/community/RootSudo
 
Old 09-23-2009, 12:58 PM   #3
newbiesforever
Senior Member
 
Registered: Apr 2006
Location: Iowa
Distribution: Debian distro family
Posts: 2,378

Original Poster
Rep: Reputation: Disabled
It's strictly the principle, you understand. I would use sudo.
 
Old 09-23-2009, 09:53 PM   #4
Crito
Senior Member
 
Registered: Nov 2003
Location: Knoxville, TN
Distribution: Kubuntu 9.04
Posts: 1,168

Rep: Reputation: 53
Mind you I'm a Ubuntu newbie and I haven't done this myself, but from locking and unlocking accounts on other distros I believe the trick is removing the ! or * symbol in the /etc/shadow file.
 
Old 09-24-2009, 01:13 AM   #5
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Ubuntu 12.04, Antix19.3
Posts: 3,794

Rep: Reputation: 282Reputation: 282Reputation: 282
Crito, when doing that you still don't know the root password. And that trick can be done using the -u option in the password command.

This is the default line in Ubuntu Netbook Remix
Code:
root:!:14474:0:99999:7:::
 
Old 09-24-2009, 01:24 AM   #6
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Ubuntu 12.04, Antix19.3
Posts: 3,794

Rep: Reputation: 282Reputation: 282Reputation: 282
newbiesforever, it's their approach to a problem (users forgetting their root password or working as root all the time). If you don't like their approach, fix it with the solution given earlier or use another distro.

It's their freedom to do so and it's your freedom to like it or not

PS a lot of distros nowadays don't allow you to login as root account in the graphical environment.

Last edited by Wim Sturkenboom; 09-24-2009 at 01:35 AM.
 
Old 09-24-2009, 05:21 AM   #7
tommcd
Senior Member
 
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,230

Rep: Reputation: 293Reputation: 293Reputation: 293
Enabling the root account is not recommended in Ubuntu.
https://help.ubuntu.com/community/RootSudo
If you want to use a root terminal in Ubuntu use sudo -i as discussed at the end of that article.
https://help.ubuntu.com/community/Ro...20and%20shells
Many people who enable the root account in Ubuntu run into problems. I suspect that this is likely caused by inexperience with using a root account in linux though, or possibly running the system as root. I have always used sudo in Ubuntu without any problems.
Even telling someone how to enable the root account on the Ubuntu forums will get you severely chastised by the forum moderators.

Last edited by tommcd; 09-24-2009 at 05:36 AM.
 
Old 09-24-2009, 11:49 AM   #8
newbiesforever
Senior Member
 
Registered: Apr 2006
Location: Iowa
Distribution: Debian distro family
Posts: 2,378

Original Poster
Rep: Reputation: Disabled
Quote:
newbiesforever, it's their approach to a problem (users forgetting their root password or working as root all the time).
I think that either Ubuntu overestimates the number of users ignorant enough to work as root all the time (which doesn't include me), or I underestimate it.

Quote:
Originally Posted by Wim Sturkenboom View Post
PS a lot of distros nowadays don't allow you to login as root account in the graphical environment.
Which distros would those be? I haven't noticed that on any of the distros I've used.

Quote:
Originally Posted by tommcd View Post
Even telling someone how to enable the root account on the Ubuntu forums will get you severely chastised by the forum moderators.
That's terrible. You're talking about telling someone how to do something, not recommending that they do it. Ubuntu is the only distro I know of that has forbidden knowledge.

Quote:
Many people who enable the root account in Ubuntu run into problems. I suspect that this is likely caused by inexperience with using a root account in linux though, or possibly running the system as root.
That doesn't suggest that there are any special problems caused by using the root account in Ubuntu as opposed to using it in other distros.

Last edited by newbiesforever; 09-24-2009 at 12:03 PM.
 
Old 09-25-2009, 06:00 AM   #9
tommcd
Senior Member
 
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,230

Rep: Reputation: 293Reputation: 293Reputation: 293
Quote:
Originally Posted by newbiesforever View Post
That's terrible. You're talking about telling someone how to do something, not recommending that they do it. Ubuntu is the only distro I know of that has forbidden knowledge.
I don't agree with that policy either. There have been cases where someone asked how to enable the root account, and some well meaning person then gives them the answer. They are then quite surprised (and justifiably so imo) when they receive an infraction from the Ubuntu forum mods for doing so.

Last edited by tommcd; 09-25-2009 at 06:01 AM.
 
Old 09-25-2009, 06:18 AM   #10
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809

Rep: Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743
Probably anticlimactic, but I approached a Ubuntu rep. at the last SCALE in Los Angeles. He spoke eloquently about how their policy increases security. It was not convincing.

If you enable root as described here, you will still need to put in your user password when attempting to do something requiring admin privileges (eg open Synaptic). This gets confusing in a hurry.

My solution has been to not use Ubuntu or its progeny (too bad, because I really like Mint)....YMMV
 
Old 09-25-2009, 03:49 PM   #11
newbiesforever
Senior Member
 
Registered: Apr 2006
Location: Iowa
Distribution: Debian distro family
Posts: 2,378

Original Poster
Rep: Reputation: Disabled
I hear you. I'll have to find another distro. I need to leave MEPIS, because certain aspects of it aren't up to Ubuntu standards (so far, I've found *two things I need or could benefit from that Ubuntu has but MEPIS doesn't), but I can probably find another distro that has those things but doesn't treat users like a child regarding the root account.

*1. Ubuntu apparently comes with an open-source driver for my wireless access point, making ndiswrapper unnecessary.
2. *MEPIS 8 is missing something that is necessary to use all features of my online classroom. (This is extremely important, because I'm in graduate school.) I'm pretty sure it's something Java-related, but I haven't figured out exactly what. Ubuntu has some of the problem fixed--some of the parts of my online classroom that don't work in MEPIS work in Ubuntu, but not all.

This isn't going to significantly interfere with Ubuntu's winning over newbies everywhere as it seemingly has been doing, because most newbies probably don't care much about this issue. Unless they're like me--people who are, or once were, on the periphery of computer nerdhood. (I was there back in the late eighties and early nineties, when computers were less complicated. Now, far from being any sort of computer nerd, I am a writer and liberal arts student, impatient with computers and generally not interested in how they work.)

Last edited by newbiesforever; 09-25-2009 at 09:02 PM.
 
Old 09-26-2009, 01:53 AM   #12
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Ubuntu 12.04, Antix19.3
Posts: 3,794

Rep: Reputation: 282Reputation: 282Reputation: 282
Quote:
Originally Posted by newbiesforever View Post
I think that either Ubuntu overestimates the number of users ignorant enough to work as root all the time (which doesn't include me), or I underestimate it.
Lots of people coming from a Windows environment (up to XP) don't know about privileged users and unprivileged users. I think that Ubuntu is right in their approach for these users.

Quote:
Originally Posted by newbiesforever View Post
Which distros would those be? I haven't noticed that on any of the distros I've used.
Do a search for can't login as root. I'm not sure which ones, I seem to remember that I encountered it in an older Slackware (10.x).

I don't experience Ubuntu's approach as a disadvantage. The advantage that I see is that 'root' is a known system user and therefore prone to attacks. I however see one major advantage in having a 'root' account and that is that a crashed home partition still allows root to login to a fully functional system because root's home directory is not on the home partition. In Ubuntu one has to go to recovery mode and I'm not sure if that's fully functional (usb and networking come to mind)
 
Old 09-27-2009, 01:35 PM   #13
Crito
Senior Member
 
Registered: Nov 2003
Location: Knoxville, TN
Distribution: Kubuntu 9.04
Posts: 1,168

Rep: Reputation: 53
Enabling root in Ubuntu is even easier than that.

Just press esc during boot and select recovery mode. Then scroll down to shell without networking. That'll drop you into single user mode as root where all you need to do is run the passwd command (no switches/parms required). You won't be prompted for the old password and you won't have to edit /etc/shadow.

EDIT: And I've actually done it myself this time.

Last edited by Crito; 09-27-2009 at 01:41 PM.
 
Old 09-27-2009, 04:17 PM   #14
newbiesforever
Senior Member
 
Registered: Apr 2006
Location: Iowa
Distribution: Debian distro family
Posts: 2,378

Original Poster
Rep: Reputation: Disabled
Thanks. I wonder if any Ubuntu forum moderators will read that and, if so, whether they would even scold a senior LQ member for sharing the forbidden knowledge.
 
Old 09-27-2009, 04:32 PM   #15
catkin
LQ 5k Club
 
Registered: Dec 2008
Location: Tamil Nadu, India
Distribution: Debian
Posts: 8,578
Blog Entries: 31

Rep: Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208
When I first installed ubuntu I messed about using sudo to run commands for at least 30 seconds before running sudo passwd root and the next thing I did was find out how to set up a launcher on the panel for a root terminal. Now I'm in the habit of having a root terminal open pretty much all the time.

So -- ubuntu's root account policy is no reason to ditch ubuntu. There may be other reasons (it's a personal thing) but that's not one of them unless you plain don't like their attitude (or, more politely, design goals).
 
  


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
[Solaris 9] unlock user account noir911 Solaris / OpenSolaris 18 09-08-2009 10:11 PM
Using RHEL 64bit Not sure how to unlock an account mccartjd Linux - Newbie 2 04-24-2008 06:26 AM
Why is my common account can't open Terminal in XFCE4 but root account? notsay Slackware 4 08-18-2007 11:29 PM
is it legitimate and allowed and can be done to make another user account set uid and gid to null 0 to make another root account with different name and possibly not damage the debian system creating and using that new account BenJoBoy Linux - Newbie 12 01-29-2006 10:02 AM
Can unlock screen with root password in my user account - want to change this sm1 Linux - Newbie 2 07-24-2005 05:54 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 06:25 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