LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise
User Name
Password
Linux - Enterprise This forum is for all items relating to using Linux in the Enterprise.

Notices


Reply
  Search this Thread
Old 12-20-2012, 04:49 AM   #16
wstewart
Member
 
Registered: Dec 2012
Location: Tampa, FL
Distribution: Slackware, FreeBSD, CentOS
Posts: 41

Rep: Reputation: 1

Interesting. Didn't know that. I had a look at the man page earlier but I didn't see su unless it's just a combination of the s and u options.

Last edited by wstewart; 12-20-2012 at 04:55 AM.
 
Old 12-20-2012, 04:55 AM   #17
wstewart
Member
 
Registered: Dec 2012
Location: Tampa, FL
Distribution: Slackware, FreeBSD, CentOS
Posts: 41

Rep: Reputation: 1
I think I see what you're getting at. sudo su just starts a shell as root and reads the .bashrc or whatever shell you're using but not .profile. I still don't see su in the sudo man page but I'm guessing it's similar to running su just with sudo before it. Either way it's very useful knowledge.
 
Old 12-20-2012, 08:28 PM   #18
solarisguy
Member
 
Registered: Aug 2010
Location: Seattle
Distribution: CentOS, RHEL, Oracle Enterprise Linux, Solaris, BSD
Posts: 64

Rep: Reputation: 21
Quote:
Originally Posted by wstewart View Post
I think I see what you're getting at. sudo su just starts a shell as root and reads the .bashrc or whatever shell you're using but not .profile. I still don't see su in the sudo man page but I'm guessing it's similar to running su just with sudo before it. Either way it's very useful knowledge.
"sudo su -" will also adopt root's environment on successful privilege elevation.
 
  


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
Can't boot Wary Puppy Linux anymore, login: root (automatic login) theADOLESCENT Linux - Newbie 9 09-16-2012 06:13 PM
Unable to login using root after changing root password using passwd command rodimail SUSE / openSUSE 3 12-27-2011 10:34 PM
Adding root privaliges to user accounts or auto login as root Val-Ent Linux - General 15 03-02-2010 04:27 PM
Gnome: Cannot login as default user, sends back to login, works as root Danny-T Linux - Newbie 2 05-27-2006 03:44 AM
I have re-installed MK 9.2 but cannot login as user, login as root works. bobinglis Mandriva 2 02-22-2004 11:39 AM

LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise

All times are GMT -5. The time now is 08:24 PM.

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