Chapter 1 - Exploring Linux Command-Line Tools Flashcards
what is the shell?
1-4
a program that accepts and interprets text-mode commands and provides an interface to the system
what are shell environment variables?
1-4
placeholders for data that may be useful to many programs
in linux, what is the most popular shell?
1-5
bash
there are 2 types of default shells: the default interactive shell and the default system shell. explain the difference between the 2 by describing their functions
1-5
default interactive shell - user uses this to enter commands, run programs from the command line, run shell scripts
default system shell - used by Linux to run system shell scripts
tell me the difference between internal and external commands
1-6
internal - also known as built-in commands, allow you to perform common tasks like changing the directory, timing an operation, setting options, and terminating the shell
external - commands that are not built-in
what happens when you type a command that is not recognized by the shell as one of its internal commands?
1-8
the shell checks its path to find a program by that name to execute it
you have hit Ctrl+R to begin a backward search. what do you hit to terminate the search?
1-10
Ctrl+G
how do you retrieve the last command in your shell history?
1-11
type !!
how do you retrieve the last 500 commands entered?
1-11
type history
bash configuration files are actually bash ____ ____
1-13
shell scripts
which environment variable provides the shell with a directory list to search when you’re entering command or program names?
1-14
$PATH
you can’t remember the exact name of a command to look up. the man utility has an option to help you out. what is that option?
1-15
the -k option
your Linux is missing its whatis database. what do you do?
1-15
type makewhatis at the prompt
there are file descriptors for standard input, output, and error. what are they?
1-17
input - 0
output - 1
error - 2
what keystroke corresponds to an end-of-file marker?
1-19
Ctrl+D
what is the | symbol for?
1-19
for redirecting a program’s output to another program’s input
tell me the syntax for xargs command for building a command from its standard input
1-20
xargs [options] [command [initial-arguments]]
the cat command is used for combining files, but its also commonly used for what?
1-22
to display the contents of a short file to STDOUT