Variable
|
Mod
|
Firmware
|
Description
|
Type
|
Origin
|
---|
ACTION
|
18
|
4.85 - 5.25
|
The action to perform for mdev.
|
Text
|
busybox
|
auto_resume
|
4
|
7.04 - 8.00
|
Controls how the shell interacts with the user and job control.
|
Text
|
bash
|
BASH
|
4
|
7.04 - 8.00
|
The full pathname used to execute the current instance of Bash.
|
Text
|
bash
|
BASHOPTS
|
4
|
7.04 - 8.00
|
Colon-separated list of enabled shell options maintained by shopt.
|
Text
|
bash
|
BASHPID
|
4
|
7.04 - 8.00
|
Expands to the process ID of the current Bash process.
|
Text
|
bash
|
BASH_ALIASES
|
4
|
7.04 - 8.00
|
An associative array of aliases as maintained by alias.
|
Text
|
bash
|
BASH_ARGC
|
4
|
7.04 - 8.00
|
An array of the number of parameters in each frame of the bash stack.
|
Text
|
bash
|
BASH_ARGV
|
4
|
7.04 - 8.00
|
An array of the parameters in each frame of the bash stack.
|
Text
|
bash
|
BASH_CMDS
|
4
|
7.04 - 8.00
|
An array of the builtin Bash-Commands.
|
Text
|
bash
|
BASH_COMMAND
|
4
|
7.04 - 8.00
|
The command currently being executed.
|
Text
|
bash
|
BASH_COMPAT
|
4
|
7.04 - 8.00
|
The value to set the shell's compatibility level.
|
Text
|
bash
|
BASH_ENV
|
4
|
7.04 - 8.00
|
The path where Bash startup scripts are located.
|
Text
|
bash
|
BASH_EXECUTION_STRING
|
4
|
7.04 - 8.00
|
The command argument to the 'bash -c' invocation option.
|
Text
|
bash
|
BASH_LINENO
|
4
|
7.04 - 8.00
|
An array of line numbers in source files.
|
Text
|
bash
|
BASH_LOADABLES_PATH
|
4
|
7.14 - 8.00
|
Array of directories to search for loadable builtins maintained by enable.
|
Text
|
bash
|
BASH_REMATCH
|
4
|
7.04 - 8.00
|
An array assigned by the '=~' binary operator to the '[[' conditional command.
|
Text
|
bash
|
BASH_SOURCE
|
4
|
7.04 - 8.00
|
An array of source filenames of functions named in FUNCNAME.
|
Text
|
bash
|
BASH_SUBSHELL
|
4
|
7.04 - 8.00
|
Bash nesting depth. 0 = not a subshell.
|
Text
|
bash
|
BASH_VERSINFO
|
4
|
7.04 - 8.00
|
Readonly array of version informations for this instance of Bash.
|
Text
|
bash
|
BASH_VERSION
|
4
|
7.04 - 8.00
|
The version number of the current instance of Bash.
|
Text
|
bash
|
BASH_XTRACEFD
|
4
|
7.04 - 8.00
|
File descriptor number for trace output.
|
Text
|
bash
|
BC_ENV_ARGS
|
|
|
TODO
|
|
|
bootchart_init
|
|
|
TODO
|
|
|
CDPATH
|
4
|
7.04 - 8.00
|
The search path for the cd command.
|
Text
|
bash
|
CHARSET
|
|
|
Decoded MIME charset for reformime, defaults to build option.
|
|
|
CHILD_MAX
|
4
|
7.04 - 8.00
|
Set the number of exited child status values for the shell.
|
Text
|
bash
|
COLUMNS
|
4
|
7.04 - 8.00
|
The number of characters per line on the console window.
|
Text
|
bash
|
COMPREPLY
|
4
|
7.04 - 8.00
|
An array of possible completions generated by the programmable completion facility.
|
Text
|
bash
|
COMP_CWORD
|
4
|
7.04 - 8.00
|
An index into COMP_WORDS of the word containing the current cursor position.
|
Text
|
bash
|
COMP_KEY
|
4
|
7.04 - 8.00
|
The key used to invoke the current completion function.
|
Text
|
bash
|
COMP_LINE
|
4
|
7.04 - 8.00
|
The current command line.
|
Text
|
bash
|
COMP_POINT
|
4
|
7.04 - 8.00
|
The index of the cursor position relative to the beginning of the current command.
|
Text
|
bash
|
COMP_TYPE
|
4
|
7.04 - 8.00
|
Set to an integer value corresponding to the type of completion attempt.
|
Text
|
bash
|
COMP_WORDBREAKS
|
4
|
7.04 - 8.00
|
Characters that Readline treats as word separators when performing word completion.
|
Text
|
bash
|
COMP_WORDS
|
4
|
7.04 - 8.00
|
An array of the individual words in the current command line.
|
Text
|
bash
|
CONSOLE
|
163
|
1.63 - 8.00
|
The console tty used by this Shell.
|
Text
|
busybox
|
console (linenv)
|
122
|
1.120 - 8.00
|
The console tty used by this Shell.
|
Text
|
busybox
|
CONTENT_TYPE (linenv)
|
|
|
Decoded MIME Content-Type for reformime, defaults to 'text/plain'.
|
|
|
COPROC
|
4
|
7.04 - 8.00
|
An array of file descriptors for I/O of an unnamed coprocess.
|
Text
|
bash
|
DATAFILE
|
|
|
TODO
|
|
|
DEVNAME
|
|
|
TODO
|
|
|
DEVPATH
|
18
|
4.85 - 5.25
|
The sysfs device path for mdev.
|
Text
|
busybox
|
DIRSTACK
|
4
|
7.04 - 8.00
|
An array of the current contents of the directory stack.
|
Text
|
bash
|
EDITOR (linenv)
|
|
|
The preferred text editor if set (ie: /usr/bin/nano).
|
|
|
EMACS
|
1
|
7.04 - 7.13
|
Set if bash is running in an Emacs shell buffer to disable line editing.
|
Text
|
bash
|
ENCODING
|
|
|
Decoded MIME Content-Transfer-Encoding for reformime, defaults to '7bit'.
|
|
|
ENV
|
|
|
Path to a profile script for ash.
|
|
|
EUID
|
4
|
7.04 - 8.00
|
The numeric effective user id of the current user.
|
Text
|
bash
|
EXECIGNORE
|
4
|
7.14 - 8.00
|
Patterns of filenames to be ignored by command search using PATH.
|
Text
|
bash
|
EXINIT
|
133
|
4.57 - 8.00
|
Variable to customize vi.
|
Text
|
busybox
|
FIGNORE
|
4
|
7.04 - 8.00
|
Suffixes to ignore when performing filename completion.
|
Text
|
bash
|
FILENAME
|
106
|
4.85 - 8.00
|
Delivery filename for popmaildir connect helper program or target filename for reformime helper.
|
Text
|
busybox
|
FIRMWARE
|
17
|
4.85 - 5.25
|
The firmware to load for mdev.
|
Text
|
busybox
|
freq_drift_ppm
|
|
|
TODO
|
|
|
FSCK_FORCE_ALL_PARALLEL
|
|
|
TODO
|
|
|
FSCK_MAX_INST
|
|
|
TODO
|
|
|
FSTAB_FILE
|
|
|
TODO
|
|
|
FUNCNAME
|
4
|
7.04 - 8.00
|
Array of names of all shell functions currently in the execution call stack.
|
Text
|
bash
|
FUNCNEST
|
4
|
7.04 - 8.00
|
The maximum function nesting level. 0 = no limit.
|
Text
|
bash
|
GETCONF_DIR
|
4
|
7.04 - 8.00
|
Optional directory where getconf is located to query system variables.
|
Text
|
glibc
|
GETOPT_COMPATIBLE
|
108
|
4.85 - 8.00
|
Compatiblity tweak for getopt.
|
Text
|
busybox
|
GID
|
106
|
5.07 - 8.00
|
The group id of the user who owns this Shell.
|
Text
|
busybox
|
GLOBIGNORE
|
4
|
7.04 - 8.00
|
Patterns defining the set of filenames to be ignored by filename expansion.
|
Text
|
bash
|
GROUPS
|
4
|
7.04 - 8.00
|
An array of groups of which the current user is a member.
|
Text
|
bash
|
histchars
|
4
|
7.04 - 8.00
|
Up to 3 chars which control history expansion, quick substitution, and tokenization.
|
Text
|
bash
|
HISTCMD
|
4
|
7.04 - 8.00
|
The history number, or index in the history list, of the current command.
|
Text
|
bash
|
HISTCONTROL
|
4
|
7.04 - 8.00
|
List of values controlling how commands are saved on the history list.
|
Text
|
bash
|
HISTFILE
|
4
|
7.04 - 8.00
|
The name of the file to which the command history is saved.
|
Text
|
bash
|
HISTFILESIZE
|
4
|
7.04 - 8.00
|
The maximum number of lines contained in the history file.
|
Text
|
bash
|
HISTIGNORE
|
4
|
7.04 - 8.00
|
List of patterns masking command lines which should be saved on the history list.
|
Text
|
bash
|
HISTSIZE
|
4
|
7.04 - 8.00
|
The maximum number of commands to remember on the history list.
|
Text
|
bash
|
HISTTIMEFORMAT
|
4
|
7.04 - 8.00
|
Optional format string for the time displayed by the history builtin.
|
Text
|
bash
|
HOME (linenv)
|
163
|
1.63 - 8.00
|
The home directory of this Shell.
|
Text
|
busybox, uClibc, glibc, bash, musl
|
HOSTFILE
|
4
|
7.04 - 8.00
|
A file in the same format as '/etc/hosts' for hostname completion.
|
Text
|
bash
|
HOSTNAME
|
4
|
7.04 - 8.00
|
The hostname of this machine.
|
Text
|
bash
|
hostname_completion_file
|
4
|
7.04 - 8.00
|
Old name of the HOSTFILE variable.
|
Text
|
bash
|
HOSTTYPE
|
4
|
7.04 - 8.00
|
A string describing the machine Bash is running on.
|
Text
|
bash
|
HUSH_VERSION
|
|
|
TODO
|
|
|
IFS
|
11
|
6.98 - 8.00
|
The character used as the internal field separator.
|
Text
|
glibc, bash
|
IGNOREEOF
|
4
|
7.04 - 8.00
|
Controls the action of the shell on receipt of an 'EOF' character.
|
Text
|
bash
|
ignoreeof
|
4
|
7.04 - 8.00
|
Controls the action of the shell on receipt of an 'EOF' character.
|
Text
|
bash
|
INSIDE_EMACS
|
4
|
7.14 - 8.00
|
Emacs 'version,comint' if bash is running inside an Emacs subshell.
|
Text
|
bash
|
interface (linenv)
|
|
|
TODO
|
|
|
LANG
|
134
|
4.61 - 8.00
|
The language of this Shell to select the Locale.
|
Text
|
uClibc, busybox, glibc, bash, musl
|
LC_ALL
|
134
|
4.61 - 8.00
|
Forced Locale of this Shell for applications.
|
Text
|
uClibc, busybox, glibc, bash, musl
|
LC_COLLATE
|
4
|
7.04 - 8.00
|
The collation order used when sorting the results of filename expansion.
|
Text
|
bash
|
LC_CTYPE
|
52
|
6.30 - 8.00
|
The character set used to display and input text.
|
Text
|
busybox, glibc, bash, musl
|
LC_MESSAGES
|
4
|
7.04 - 8.00
|
The Locale used to translate double-quoted strings preceded by a '$'.
|
Text
|
bash
|
LC_NUMERIC
|
4
|
7.04 - 8.00
|
The Locale used for number formatting.
|
Text
|
bash
|
LC_TIME
|
4
|
7.04 - 8.00
|
The Locale used for date and time formatting.
|
Text
|
bash
|
LD_BIND_NOW
|
30
|
7.19 - 8.00
|
Causes the dynamic linker to resolve all symbols at program startup.
|
Text
|
uClibc
|
LD_LIBRARY_PATH
|
25
|
7.19 - 8.00
|
List of directories to search for Shared-Libraries before the standard locations.
|
Text
|
musl
|
LD_PRELOAD
|
25
|
7.19 - 8.00
|
List of objects which should be preloaded by the dynamic linker.
|
Text
|
musl
|
LINES
|
4
|
7.04 - 8.00
|
The number of text lines on the console window.
|
Text
|
bash
|
LOGIN_GID
|
|
|
TODO
|
|
|
LOGIN_PRE_SUID_SCRIPT
|
|
|
TODO
|
|
|
LOGIN_SHELL
|
|
|
TODO
|
|
|
LOGIN_TIMEOUT
|
28
|
7.61 - 8.00
|
TODO
|
Text
|
busybox
|
LOGIN_TTY
|
|
|
TODO
|
|
|
LOGIN_UID
|
|
|
TODO
|
|
|
LOGIN_USER
|
|
|
TODO
|
|
|
LOGNAME
|
163
|
1.63 - 8.00
|
Similar to USER, some programs prefer to read this variable.
|
Text
|
busybox, uClibc, musl
|
LS_COLORS
|
4
|
4.14 - 4.26
|
Colours to use for ls --color.
|
Text
|
busybox
|
MACHTYPE
|
4
|
7.04 - 8.00
|
Describes the system type on which Bash is executing, in the standard GNU format.
|
Text
|
bash
|
MAIL
|
4
|
7.04 - 8.00
|
Optional filename or directory name to poll for mail.
|
Text
|
bash
|
MAILCHECK
|
4
|
7.04 - 8.00
|
How often (in seconds) that the shell should check for mail.
|
Text
|
bash
|
MAILPATH
|
4
|
7.04 - 8.00
|
A list of filenames which the shell periodically checks for new mail.
|
Text
|
bash
|
MANDATORY_MANPATH
|
|
|
TODO
|
|
|
MANPAGER
|
|
|
TODO
|
|
|
MAPFILE
|
4
|
7.04 - 8.00
|
An array to hold the text read by the mapfile builtin.
|
Text
|
bash
|
offset
|
58
|
4.14 - 7.19
|
Offset of a busybox ntpd sync.
|
Text
|
busybox
|
OLDPWD (linenv)
|
4
|
7.04 - 8.00
|
The previous working directory of this Shell.
|
Text
|
bash
|
OPTARG
|
4
|
7.04 - 8.00
|
The value of the last option argument processed by the getopts builtin.
|
Text
|
bash
|
OPTERR
|
4
|
7.04 - 8.00
|
1= Display error messages generated by builtin getopts.
|
Text
|
bash
|
OPTIND
|
4
|
7.04 - 8.00
|
The index of the last option argument processed by the getopts builtin.
|
Text
|
bash
|
OSTYPE
|
4
|
7.04 - 8.00
|
A string describing the operating system Bash is running on.
|
Text
|
bash
|
PAGER (linenv)
|
|
|
The preferred pager if set (ie: /usr/bin/less).
|
|
|
PATH (linenv)
|
148
|
1.63 - 8.00
|
The path to search for commands of this Shell.
|
Text
|
busybox, uClibc, glibc
|
PATH_INFO (linenv)
|
|
|
TODO
|
|
|
PIPESTATUS
|
4
|
7.04 - 8.00
|
An array of exit status values from most recent foreground pipeline.
|
Text
|
bash
|
poll_interval
|
|
|
TODO
|
|
|
POSIXLY_CORRECT
|
163
|
1.63 - 8.00
|
If present: Try to behave according to the POSIX standard.
|
Text
|
uClibc, busybox, glibc, bash
|
POSIX_PEDANTIC
|
4
|
7.04 - 8.00
|
If present: Try to behave according to the POSIX standard.
|
Text
|
bash
|
PPID
|
4
|
7.04 - 8.00
|
The process ID of the shell's parent process.
|
Text
|
bash
|
PRINTER
|
|
|
TODO
|
|
|
PROMPT_COMMAND
|
4
|
7.04 - 8.00
|
Optional command to execute before the printing of each primary prompt (PS1).
|
Text
|
bash
|
PROMPT_DIRTRIM
|
4
|
7.04 - 8.00
|
Optional number of directory components when expanding the 'w' and 'W' prompt string escapes
|
Text
|
bash
|
PROTO (linenv)
|
7
|
7.29 - 8.00
|
TODO
|
Text
|
busybox
|
PS0
|
4
|
7.14 - 8.00
|
Prompt for interactive shells printed between reading and executing a command.
|
Text
|
bash
|
PS1
|
5
|
1.63 - 8.00
|
The primary prompt string.
|
Text
|
busybox, bash
|
PS2
|
5
|
1.63 - 8.00
|
The secondary prompt string.
|
Text
|
busybox, bash
|
PS3
|
4
|
7.04 - 8.00
|
Optional prompt for the select command.
|
Text
|
bash
|
PS4
|
4
|
7.04 - 8.00
|
The prompt printed before the command line is echoed when the '-x' option is set.
|
Text
|
bash
|
PWD (linenv)
|
163
|
1.63 - 8.00
|
The current working directory of this Shell.
|
Text
|
busybox, uClibc, glibc, musl
|
QUERY_STRING
|
|
|
TODO
|
|
|
RANDOM
|
3
|
7.04 - 7.57
|
Generates a random integer (0 - 32767) each time this parameter is referenced.
|
Text
|
bash
|
READLINE_LINE
|
4
|
7.04 - 8.00
|
The contents of the Readline line buffer, for use with 'bind -x'.
|
Text
|
bash
|
READLINE_POINT
|
4
|
7.04 - 8.00
|
The position of the insertion point in the Readline line buffer, for use with 'bind -x'.
|
Text
|
bash
|
REMOTE_ADDR (linenv)
|
|
|
TODO
|
|
|
REMOTE_PORT (linenv)
|
|
|
TODO
|
|
|
REMOTE_USER
|
|
|
TODO
|
|
|
REPLY
|
|
|
The default variable for the read builtin.
|
|
|
REQUEST_METHOD (linenv)
|
|
|
TODO
|
|
|
REQUEST_URI
|
|
|
TODO
|
|
|
RLENGTH
|
1
|
4.85 - 4.89
|
Stores the length of the search string/pattern for awk.
|
Text
|
busybox
|
RSTART
|
1
|
4.85 - 4.89
|
Stores the starting location of the search string/pattern for awk.
|
Text
|
busybox
|
RUNLEVEL (linenv)
|
134
|
4.57 - 8.00
|
The current system runlevel.
|
Text
|
busybox
|
SCRIPT_FILENAME
|
|
|
TODO
|
|
|
SCRIPT_NAME (linenv)
|
|
|
TODO
|
|
|
SECONDS
|
3
|
7.04 - 7.57
|
The number of seconds since the shell was started.
|
Text
|
bash
|
SEQNUM
|
18
|
4.85 - 5.25
|
The sequence number for mdev.
|
Text
|
busybox
|
SHELL (linenv)
|
162
|
1.63 - 8.00
|
The absolute path of this Shell.
|
Text
|
busybox
|
SHELLOPTS
|
4
|
7.04 - 8.00
|
A colon-separated list of enabled shell options maintained by the set builtin.
|
Text
|
bash
|
SHLVL (linenv)
|
4
|
7.04 - 8.00
|
The number of shell levels running above this Shell.
|
Text
|
bash
|
SMTPHOST
|
|
|
TODO
|
|
|
stratum
|
|
|
TODO
|
|
|
SUBSYSTEM
|
17
|
4.85 - 5.25
|
The sybsystem to use for mdev.
|
Text
|
busybox
|
SUSHELL
|
|
|
TODO
|
|
|
sushell
|
|
|
TODO
|
|
|
SVDIR
|
4
|
7.14 - 7.19
|
Overrides the services directory /var/service (for sv/runsv).
|
Text
|
busybox
|
SVWAIT
|
4
|
7.14 - 7.19
|
Overrides the 7s to wait for a command to run (for sv/runsv).
|
Text
|
busybox
|
TCPCONCURRENCY (linenv)
|
7
|
7.29 - 8.00
|
TODO
|
Text
|
busybox
|
TCPORIGDSTADDR
|
7
|
7.29 - 8.00
|
TODO
|
Text
|
busybox
|
TERM (linenv)
|
163
|
1.63 - 8.00
|
The terminal emulation used by this Shell.
|
Text
|
busybox
|
TERMCAP
|
4
|
7.04 - 8.00
|
Termcap description, set by a terminal emulator to provide the terminal's characteristics.
|
Text
|
bash
|
TEXTDOMAIN
|
4
|
7.04 - 8.00
|
The name of the current Locale.
|
Text
|
bash
|
TEXTDOMAINDIR
|
4
|
7.04 - 8.00
|
The absolute pathname of the directory storing Locales.
|
Text
|
bash
|
TIME
|
|
|
Optional default format for busybox time (-v,-p,-f override this).
|
|
|
TMOUT
|
4
|
7.04 - 8.00
|
Optional default timeout for the read builtin. 0 = no timeout.
|
Text
|
bash
|
TMPDIR
|
11
|
6.98 - 8.00
|
Optional path where temporary files for the Shell are created.
|
Text
|
glibc, busybox, bash
|
TZ (linenv)
|
68
|
4.14 - 8.00
|
The time zone used by this Shell.
|
Text
|
busybox, bash
|
UID
|
106
|
5.07 - 8.00
|
The unique id of the user who owns this Shell.
|
Text
|
busybox
|
USER (linenv)
|
162
|
1.63 - 8.00
|
The user who owns this Shell.
|
Text
|
busybox
|
VISUAL
|
|
|
TODO
|
|
|
174 Linux variables
|
---|