What is /etc/profile used for?#If you have been using Linux for a while you are probably familiar with the .profile or .bash_profile files in your home directory. These files are used to set environmental items for a users shell.
Items such as umask, and variables such as PS1 or PATH are appropriate to set in .profile or .bash_profile.
The /etc/profile file is not very different however it is used to set system wide environmental variables on ALL users shells. The variables are sometimes the same ones that are in the .bash_profile, however this file is used to set an initial PATH or PS1 for all shell users of the system.