USER vs LOGNAME environment variables.
search cancel

USER vs LOGNAME environment variables.

book

Article ID: 37575

calendar_today

Updated On:

Products

CA Workload Automation AE - Business Agents (AutoSys) CA Workload Automation AE - Scheduler (AutoSys) Workload Automation Agent

Issue/Introduction

Question:

When running a Job on AIX, what's the difference between the following Environment Variables: 

* USER 
* LOGNAME ?

 

Answer:

 

LOGNAME is the user you are logged in as
USER is the user ID that you are working under.

Initially they are both the same, so if you login as root and do not su to some other user, they would both be root. But if you su to say 'autosys' then your LOGNAME would still be root but your USER would be autosys.

Environment

Release: ATSYHA99000-11.3.6-Workload Automation AE-High Availability Option
Component: