Linux - Environment variable

About

Management

Set

Shell

They are set generally with the shell. See Bash - (Environment) Variable

PAM

pam permits also an admin to set environment variable: See pam-env

The file used to set the environment variable are the below one:

  • /etc/security/pam_env.conf: Default configuration file - When someone logs in, this file is read and the environment variables are set according.
  • /etc/environment: Default environment file - simple KEY=VAL pairs on separate lines
  • $HOME/.pam_environment: User specific environment file

Get the env of a process

Start with a clean environment

clean env

Powered by ComboStrap