Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 11-18-2012, 02:45 AM   #1
LQ Newbie
Registered: Mar 2012
Posts: 9

Rep: Reputation: Disabled
login in root account automatically

Hi guys. I've got Ubuntu, and 99% of my commands require sudo. i would like to save me this time and just login automatically through root account, i prefer without user/password at start, but if its not posiible its also OK, its a vmware, so i ca always just hit "suspend".
so, how do i set the default account as root?
Old 11-18-2012, 03:08 AM   #2
LQ Guru
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 679Reputation: 679Reputation: 679Reputation: 679Reputation: 679Reputation: 679
The root account is locked in Ubuntu. You can run "sudo bash" in leu of "su -" if you need to run consecutive commands as root. Don't even consider running the desktop as root.
Old 11-18-2012, 03:24 AM   #3
Senior Member
Registered: Jul 2012
Location: Grenoble, Fr.
Distribution: Sun Solaris, RHEL, Ubuntu, Debian 6.0
Posts: 1,800
Blog Entries: 4

Rep: Reputation: 286Reputation: 286Reputation: 286
Now a days, direct root or admin login isn't supported (not only in Linux but in Windows too), but you can login using your user account, and then you can switch to root/admin.
You can then run commands using sudo. For example:
sudo <command_name>
Further you can do following to switch to root user and to get root privilages.
sudo su - root

Last edited by shivaa; 11-18-2012 at 03:28 AM.
Old 11-18-2012, 06:18 AM   #4
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4870Reputation: 4870Reputation: 4870Reputation: 4870Reputation: 4870Reputation: 4870Reputation: 4870Reputation: 4870Reputation: 4870Reputation: 4870Reputation: 4870
The correct way to get a root shell with sudo is
sudo -i
Logging in to the GUI as root is neither supported nor recommended or reasonable and usually something only demanded by inexperienced admins that are not aware of the security risks of doing that.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 account login oluwasijibomi Fedora 9 08-31-2009 08:02 AM
Root Account Disabled (not smart) Can not root LOGIN mitchellray Slackware 12 06-30-2009 01:52 PM
Auto-login (root account) sammykrupa Linux - Newbie 3 07-31-2005 12:27 AM
root account cann't login ringerxyz Linux - Newbie 7 02-02-2005 07:53 PM
can't login into root account eye Red Hat 5 11-21-2003 09:30 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:50 PM.

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