How to get root shell in Ubuntu GNU/Linux

advertisement logo

 

A lot of my friends has been asking me about this very question, “how to get root shell in Ubuntu”. Naturally I would ask them to use the “sudo” command as it suffice to execute any task restricted to root only. It is explicit, and it is safer than using root account, that’s why ubuntu never prompted root password during installation.

However for some reasons, some people would prefer a full root shell instead of using “sudo” command. And here is how to obtain root shell access in Ubuntu GNU/Linux.

Method 1

From Desktop, launch the “Terminal” application, accesible through clicking Applications->Accesories->Terminal.

Execute this command,

mypapit@enterprise:~$ sudo -s
Password:

Enter your user password, and then you’ll get the root shell “#”.

Method 2

Same as method 1 but execute this command,

mypapit@enterprise:~$ sudo su
Password:

Enter your user password, and then you’ll get the root shell “#”.

So there you go, that’s how to get root shell access within your Ubuntu GNU/Linux. But as for me, I think I can settle with the sudo command, as I haven’t found a situation where I need to use the root shell explicitly.

Good luck !


Share this post

Keep updated with the latest posts, be a part of over 1,000 subscribers! : email iconSubscribe to your email

11 smashing comments for this post.

  1. Planet Malaysia Said:

    You are not encourage to login as root…..

  2. reddit.com: web 2.0 reddit - newest submissions Said:

    [...] How to get root shell in Ubuntu GNU/Linux (blog.mypapit.net) [...]

  3. Alan Said:

    3rd way:

    sudo bash

  4. shell ubuntu - Web - WebCrawler Said:

    [...] Now Searching: Google, Yahoo! Search, Windows Live, Ask.com, And More Are you looking for? No Suggestions Found. Recent Searches shell ubuntu Clear All View Hide SetRecentSearchesView(); Results: 1 – 20 of 77 (About Results) 1|2|3|4 Next > 1. How to control text scrolling when using ls in the shell – Ubuntu… How to control text scrolling when using ls in the shell Absolute Beginner Talk. ubuntuforums.org/showthread.php?p=3357504 [Found on Google, Yahoo! Search, Ask.com] 2. Shell Linux Shop & Save on Computer Software. Store Ratings. Consumer Reviews. Sponsored by: http://www.Dealtime.com/computersoftware [Found on Ads by Yahoo!] 3. Keyboard Shortcuts for Bash ( Command Shell for Ubuntu, Debian ….. 35 Responses to “Keyboard Shortcuts for Bash ( Command Shell for Ubuntu, Debian, Suse, Redhat, Linux, etc)”. Ctrl + W erase word before cursor Â…. lot of fun … http://www.howtogeek.com/howto/ubuntu/keyboard-shortcuts-... [Found on Google, Yahoo! Search, Ask.com] 4. Text* Snippets: How to set a static IP in Ubuntu from the shell [... How to set a static IP in Ubuntu from the shell in ubuntu linux networking " ... Use Sun Java in Ubuntu Breezy in java ubuntu ... textsnippets.com/posts/show/319 [Found on Yahoo! Search, Ask.com] 5. Shell Linux Shop for shell linux and save. Sponsored by: http://www.Shopica.com [Found on Ads by Yahoo!] 6. Digg – Completely Transparent Shell on your Ubuntu desktop with …. Completely Transparent Shell on your Ubuntu desktop with Compiz Fusion. This is HOT!! have your terminal right on top of your wallpaper (screenshots … digg.com/linux_unix/Completely_Transparent_Shell_o… [Found on Google, Yahoo! Search] 7. Learning the shell | Ubuntu Linux Learning the shell. Submitted by Friedrich on Fri, 2005-08-26 14:18. You have your Ubuntu up and running. The GUI is working fine, but you are getting tired … http://www.ubuntux.org/learning-the-shell [Found on Google] 8. How to get root shell in Ubuntu GNU/Linux : mypapit gnu/linux blo… A lot of my friends has been asking me about this very question, “how to get root shell in Ubuntu”. Naturally I would ask them to use the “sudo” command as … blog.mypapit.net/2006/03/how-to-get-root-shell-in-… [Found on Google] 9. Shell – Ubuntu Wiki Ubuntu Wiki. Search: Login. Ubuntu. Community. Support. Partners. Wiki … Shell. This page … © 2007 Canonical Ltd. Ubuntu, Kubuntu, Edubuntu, Xubuntu … https://wiki.ubuntu.com/Shell [Found on Yahoo! Search] 10. Ubuntu Blog Ubuntonista’s weblog featuring a series of articles with tips, tweaks and tips for Ubuntu users. … are, then then, again, Ubuntu seems to attract a middle … ubuntu.wordpress.com/ [Found on Yahoo! Search] 11. Ubuntu — psh interactive shell with the power of perl … But, the Perl Shell will use Perl syntax and … For other support information, see the Ubuntu support page. … packages.ubuntu.com/edgy/shells/psh [Found on Yahoo! Search] 12. Need a Highspeed Linux Shell Account? We’ve got you covered. We have 10 public linux shell servers, over 1,000 vanity virtual hosts, and a cutting edge network. Experience the fusion of experience and innovation. Sponsored by: http://www.kire.net [Found on Ads by Yahoo!] 13. The Robotic Shell: Ubuntu and Beryl I just tried out the new version of Ubuntu Linux: 6.10. I also checked out an install script called envy, which automatically configures your NVIDIA card. … krobotics.blogspot.com/2006/12/ubuntu-and-beryl.ht… [Found on Google] 14. shell + Ubuntu – SWiK Ubuntu Unleashed: Howto: Completely Transparent Shell on your Ubuntu desktop with Compiz Fusion. Tuesday, August 28, 2007 … swik.net/shell+Ubuntu [Found on Google] 15. Only Ubuntu Linux: Bash Shell Keyboard Shortcuts For Linux Users Ctrl + D – Exit the current shell … Mount Network File systems (NFS,Samba) in Ubuntu … Install Popular Applications in Ubuntu Feisty Fawn… onlyubuntu.blogspot.com/2007/03/bash-shell-keyboar… [Found on Yahoo! Search] 16. Keyboard Shortcuts for Bash ( Command Shell for Ubuntu, Debian, …. Keyboard Shortcuts for Bash ( Command Shell for Ubuntu, Debian, Suse, Redhat, Linux, … The default shell on most Linux operating systems is … http://www.errorforum.com/linux-unix-error/2175-keyboard-... [Found on Ask.com] 17. Shell Linux Shop & Save on Computer Software. Store Ratings. Consumer Reviews. Sponsored by: http://www.Shopping.com/computersoftware [Found on Ads by Yahoo!] 18. Linux shell and music files [linux] [ubuntu] to linux shell ubuntu by dirtyaffairs on Mon May 14 03:39:15 EDT 2007 … linux bash shell subversion debian server administration ubuntu control svn … snippets.dzone.com/posts/show/4008 [Found on Yahoo! Search] 19. Error – Keyboard Shortcuts for Bash ( Command Shell for Ubuntu, …. Keyboard Shortcuts for Bash ( Command Shell for Ubuntu, Debian, Suse, Redhat, Linux … The default shell on most Linux operating systems is … http://www.errorforum.com/linux-unix-error/3199-keyboard-... [Found on Ask.com] 20. Ubuntu — csh Shell with C-like syntax, standard login shell on BSD systems … For other support information, see the Ubuntu support page. … packages.ubuntu.com/feisty/shells/csh [Found on Yahoo! Search] 1|2|3|4 Next > Web |Images |Audio |Video |News |Yellow Pages |White Pages function NewVerticalQuery(verticalLinkId, qkwId, qcat, rfcid, rfcp, qcoll) { var inputqkw = document.getElementById(qkwId); if (inputqkw) { // if there is no query, then don’t try to requery based on a blank space // the result will always be ‘no results found’ if (inputqkw.value == “”) { ToggleVerticalTab(qcat, verticalLinkId); } else { location.href = ‘http://www.webcrawler.com/webcrawler/ws/redir/_iceUrlFlag=11?_IceUrl=true&qcat=‘ + qcat + ‘&qkw=’+ encodeURIComponent(inputqkw.value)+ ‘&rfcid=’ + rfcid + ‘&rfcp=’ + rfcp + ‘&qcoll=’ + qcoll; } } } [...]

  5. get root ubuntu - Google Search Said:

    [...] [...]

  6. Apo Said:

    Very nice :-) first hit at google and it helps…
    needed the root shell for installing vmware tools :-)

  7. nirmal Said:

    can anyone tell that how can a program is compiled and run using ubuntu 8.04?

  8. zahurul Said:

    we can use

    sudo -i

    then just put ur password..

    thanks

  9. p.l.dave Said:

    thank you google for help in search for quistion and thanku very much for answer from
    websit.
    again thanku.

    P.L. Dave.

  10. val Said:

    Thank you, very useful *thumbsup*

    I tried to echo-append something to /etc/ca-certificates.conf using sudo and got “permission denied”.

  11. Prags Said:

    same here.Even i got permission denied. How to overcome it?

Leave a Comment

Subscribe by email

Enter your Email