Question: order of profiles

Dirk Moolman DirkM
Tue Jun 19 01:16:17 PDT 2007


I just found a page on the web, that says:

"When a user logs in, environment variables are set from various places.
That includes /etc/profile (for all users).
Then all the files in the /etc/profile.d directory.
Then +AH4-/.bash_profile, then +AH4-/.bashrc."


I tested this, by placing a variable in all 3 places, for a specific
user, and then by echo'ing the variable, and removing it form 1 script
at a time, to see in which order the scripts are being read.   And my
test shows a different result to the web page - that they are being read
in the order:

1. /etc/profile.d
2. /etc/profile
3. +AH4-/.profile (in this case I do not have the .bash_profile or .bashrc
scripts

 
Can someone confirm that my test results are correct ?






Dirk Moolman
Database and Unix Administrator
Agility Technologies (HealthCorp)



"People demand freedom of speech as a compensation for the freedom of
thought which they seldom use." 




*** Disclaimer ***

The information contained in this e-mail is confidential and legally privileged and is intended solely for the addressee and to others who have the authority to receive it. Access to this e-mail by anyone else is unauthorized and as such, any disclosure, copying, distribution or any action taken or omitted in reliance on it is unlawful. If you have received this e-mail in error, please notify the sender immediately.

The views expressed in this e-mail are the views of the individual sender and should in no way be construed as the views of the Company.

The Company is not liable to ensure that outgoing e-mails are virus-free.

The Company is not liable, should information or data, for whatever reason, be corrupted or fail to reach its intended addressee.

The Company is not liable for any loss or damage of whatsoever nature and howsoever arising resulting from the opening or the use of the information in this e-mail, including its attachments and links.

The sender of this e-mail is subject to and bound by the terms and conditions of Company+IBk-s Electronic Communications Usage Policy.



More information about the Linux-users mailing list