Objective 5: Troubleshooting System Resources

Sometimes the problems we need to troubleshoot aren't with hardware or with specific applications; the problems are with the system itself. A console message of a garbled terminal console or a wrong user home directory means there is something wrong with the system and not with an application per se.

Environment Variables and Shells

Many applications use variables to modify their behavior. Some variables have local scope (meaning they are visible only in the current instance of the shell), while others have global scope (meaning they are visible in the current shell and in child shells). These latter variables are called environment variables. A local variable can be made an environment variable via the export command.

To view your current variables and their settings, issue the set or env command.

Some common variables are shown in table Table 32-2.

Table 32-2. Common Variables Environment




Determines which editor is invoked by programs requiring user interaction


Determines which language to use (e.g., en_US.UTF-8, en_US, etc.)


Determines which program to use to page through files (e.g., more, less, etc.)


Colon-separated list of directories to search for executable file names


Character(s) to use for the command prompt


Current shell


Determines which terminal type is in use (e.g., vt100, linux, etc.)


Current user ID


Current username

While bash is the ...

Get LPI Linux Certification in a Nutshell, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.