Linux/UNIX environment variables

Home » Questions» General

Linux/UNIX list of common environment variables

Environment variables are a variable key pair stored in the shell's environment space. Here is a list of common environment variables:

Variable Description
HISTFILE The name of the file in which command history is saved
HISTFILESIZE The maximum number of lines contained in the history file
HOSTNAME The system's host name
LD_LIBRARY_PATH It is a colon-separated set of directories where libraries should be searched for
PS1 Your default (first) shell prompt
USER Current logged in user's name.
PATH Colon separated list of directories to search for binaries.
DISPLAY Network name of the X11 display to connect to, if available.
SHELL The current shell.
TERM The name of the user's terminal. Used to determine the capabilities of the terminal.
TERMCAP Database entry of the terminal escape codes to perform various terminal functions.
OSTYPE Type of operating system.
MACHTYPE The CPU architecture that the system is running on.
EDITOR The user's preferred text editor.
PAGER The user's preferred text pager.
MANPATH Colon separated list of directories to search for manual pages.

Tips & Tricks | Email