Computing.Net > Forums > Solaris > su - user -c = doesn't use env!

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

su - user -c = doesn't use env!

Reply to Message Icon

Name: Jodie
Date: November 27, 2001 at 09:35:53 Pacific
Comment:

I have a script which has a command like this:
su - mqm -c "cd $HOME/scripts;./startmqm.ksh"
However, when this command executes, the value of $HOME is that of the user that executed the "su" command, not of user "mqm". Is this the way command resolution has always worked for "su"? I know that switching to single quotes will resolve the problem, but this command used to work as written, so the change is confusing.




Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Solaris Forum Home


Sponsored links

Ads by Google


Results for: su - user -c = doesn't use env!

get the home directory after su www.computing.net/answers/solaris/get-the-home-directory-after-su/5035.html

Button | doesn't work on Blade1000 www.computing.net/answers/solaris/button-doesnt-work-on-blade1000/1563.html

display lock doesn't accept passwor www.computing.net/answers/solaris/display-lock-doesnt-accept-passwor/4183.html