Solved

su - pielm

Posted on 2011-02-18
2
279 Views
Last Modified: 2012-05-11
hi,
what will this commadn do ?
0
Comment
Question by:aashee
2 Comments
 
LVL 11

Accepted Solution

by:
rowansmith earned 250 total points
ID: 34931208
This command will switch to the user named "pielm" the "-" will prevent the running of the users startup scripts (if any).  If you are not root when you run this command then you will be prompted for the password of user pielm.

Try typing "man su" for the su manual page.

Or fllow this link:

http://unixhelp.ed.ac.uk/CGI/man-cgi?su

0
 
LVL 12

Assisted Solution

by:upanwar
upanwar earned 250 total points
ID: 34931424
If you do the su - <user name> then it will bring you in the perticular user's home directory and will load user's environment variable and you.

su - pielm

In short you will become the user pielm with full rights and environment setting of pielm but If you will not include the - then you will just become user pielm, without changing the current directory and environment variable.

like: su pielm

If you executing this command as root then It will not ask for password but if you are executing this as a not root user then it will prompt for password.

If we simply type su or su - with a non root user, it means we are trying to become root and it will prompt us for password.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Using 'screen' for session sharing, The Simple Edition Step 1: user starts session with command: screen Step 2: other user (logged in with same user account) connects with command: screen -x Done. Both users are connected to the same CLI sessio…
Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now