Kostis Mentzelos wrote:
> I believe that su user -c command throws away the environment
Changes some of the environment. For example $HOME will point to the
new user home. The command will be executed with the new user's shell
as defined in /etc/passwd. Retains most of the exported variables from
the previous user id.
> su - user -c command executes the user .profile
Set's the environment according to the new 'user' id's environment,
depending on the shell used, it's not necessarily going to be .profile.
Exported variables from the previous id are lost.
--
Until later, Geoffrey Registered Linux User #108567
AT&T Certified UNIX System Programmer - 1995