Linux 103 - Chapter 1 Flashcards Preview

Linux 103 > Linux 103 - Chapter 1 > Flashcards

Flashcards in Linux 103 - Chapter 1 Deck (12):
1

In Bash, inserting 1>&2 after a command redirects

Standard output to standard error

2

What characters can be combined with a separator string in order to read from the current input source until the separator string, which is on a separate line and without any trailing spaces, is reached?

<

3

What command will print to standard out only the lines that do not begin with # in the file foobar?

/bin/grep -v ^# foobar

4

Which command sets the Bash variable named TEST with the content FOO?

TEST="FOO"

5

When given the following command line.

echo "foo bar" | tee bar | cat

What output is created?

foo bar

6

Give two examples of valid stream redirection operators within Bash? (Two answers)

< ; >>

7

Which command shows the definition of a given shell command?

type

8

Which shell built-in command can be used to create a shortcut or pseudonym for a longer command in a shell such as Bash?

alias

9

Which command line redirection character instructs the shell to read from the current input source until a specific word, on a separate line and without and trailing spaces, is reached?

<

10

Which file, located in the user home directory, is used to store the Bash history?

.bash_history

11

Which shell redirection will write standard output and standard error output to a file named filename?

> filename 2>&1

12

Which Bash environment variable defines in which file the user history is stored when exiting a Bash process? (Specify ONLY the variable name.)

HISTFILE