Questions and CORRECT Answers
What do you not have in a borne derivitive shell? - CORRECT ANSWER - Tab complete,
history,
What is a daemon? - CORRECT ANSWER - Orphan process. Orphaned children are
immediately adopted by init.
What is a non-interactive Shell? - CORRECT ANSWER - Commands are run without user
interaction.
Example: An automated process that does not require input or output that someone will see as it
runs.
Example: a Script that scans storage media looking for potential PII that is executed by cron in
the middle of the night and creates a log file.
What is an interactive shell? - CORRECT ANSWER - Commands are run with user-
interaction from keyboard.
Example: The Shell can prompt the user to enter input, and the user can see the output.
What file are user accounts declared in? - CORRECT ANSWER -
What is a login shell? - CORRECT ANSWER - Means that the shell is run as part of the
login of the user to the system. Typically used to do configuration that a user needs to establish
the environment.
What is a non-login shell? - CORRECT ANSWER - Any other shell run by the user after
logging on, or which is run by any automated process which is not coupled to a logged in user.
,What is a shell in Linux? - CORRECT ANSWER - Interface (buffer) between user and
kernel (OS)
Interprets user commands
Not part of the kernel (OS), but interacts with the kernel to execute programs, create files, etc.
What are common Linux Shells? - CORRECT ANSWER - /bin/sh - Bourne Shell
/bin/bash - Bourne Again Shell
/bin/ksh - Korn Shell
/bin/dash - DASH (Debian Almquist Shell)
/bin/csh - C shell
/bin/tcsh - Tee See Shell
/bin/zsh - Z shell
What are the two BASH modes? - CORRECT ANSWER - Normal user ($); root (#)
What are Bash Aliases? - CORRECT ANSWER - Aliases allow a string to be substituted
for a word when it is used as the first word of a simple command. The shell maintains a list of
aliases that may be set and unset with the alias and unalias builtin commands.
What is a function in Bash? - CORRECT ANSWER - Think of a function as a small script
within a script within a script. It's a small chunk of code which you may call multiple times
within your script.
What is Command substitution in BASH? - CORRECT ANSWER - reassigns the output
of a command or even multiple commands; it literally plugs the command output into another
context.
, What file is concerned wether or not your in an interactive shell? - CORRECT ANSWER -
/bash.bashrc
- CORRECT ANSWER - .profile
path variable - CORRECT ANSWER - etc/profile
Can put aliases in? - CORRECT ANSWER - all of them
Whats the first files that run in - CORRECT ANSWER - etc/skel
What files are in etc/skel - CORRECT ANSWER - Directory containing default files
Whats the last file that runs for root user? - CORRECT ANSWER - (runs for all users)
.bashrc
- CORRECT ANSWER - .bash_logout
before .profile runs for a user and not root user which two files does it look for? - CORRECT
ANSWER -.
How do you update the man database? - CORRECT ANSWER - man db
How do commands and arguments differ in linux? - CORRECT ANSWER - Use the
forward slash
everything in linux is a file (first and formost)
everything is space dellimated read except for pipes and colons