Chapter 1,2 - Installing Red Hat Enterprise Linux, Using Essential Tools Flashcards

1
Q

What is Linux?

A

Linux is a free operating system. That means that the source code of all programs is available for free. However, some enterprise Linux distributions are sold as commercial products, with bundled support and maintenance, which is the case for RHEL 8

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What are the two free alternatives to Redhat?

A

CentOS 8

Fedora

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is a Repository?

A

A repository is the installation source used for installing software. If you are using free software such as CentOS, correct repositories are automatically setup, and no further action is required. If you are using Red Hat Enterprise Linux with a subscription, you’ll need to use the Subscription Manager software to get
access to repositories.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the default file system RHEL 8 uses?

A

RHEL 8 by default uses the XFS file system. This file system cannot be shrunk; it can only be expanded. Therefore, it is sometimes a better choice to use Ext4.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is a Shell?

A

The shell is the default working environment for a Linux administrator. It is the environment where users and administrators enter commands that are executed by
the operating system.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Which is the most common shell used?

A

Different shells for Linux are available, but Bash is the most common shell.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What are the 3 basic parts of a command?

A

the command, its options, and its arguments.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What are the 3 different kind of commands?

A

Aliases - An alias is a command that a user can define as needed
Internal Commands - An internal command is a command that is a part of the shell itself and, as such,
doesn’t have to be loaded from disk separately
External Commands - An external command is a command that exists as an executable file on the disk of the computer

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Where are the external commands looked at when executed?

A

the $PATH variable.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

To find out which exact command the shell is using and from where is it being loaded?

A

which command

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What are the I/O redirection file descriptor numbers?

A

NAME - FILE DESCRIPTOR
STDIN - 0
STDOUT - 1
STDERR - 2

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

How do you redirect STDERR to the same destination as STDOUT?

A

2>&1

eg. ls whuhiu > errout 2>&1

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is a device file in Linux?

A

A device file on Linux is a file that is used to access specific hardware. eg.
HDD - /dev/sda, the console of your server is known as /dev/console or /dev/tty1

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Which command to show a list of all commands in the Bash history?

A

history

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

How to execute a command with a specific number from history?

A

!number

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

How to execute the last command that starts with “sometext”?

A

!sometext

17
Q

which command to clear the current history?

A

history -c

18
Q

How to remove the complete Bash history?

A

type “history -w” immediately after using “history -c”

19
Q

What are the vi or vim editor options?

A

vim Command = Explanation
/text = Searches for text from the current cursor position forward.
?text = Searches for text from the current cursor position backward.
^ = Goes to the first position in the current line.
$ = Goes to the last position in the current line.
!ls = Adds the output of ls (or any other command) in the current file.
:%s/old/new/g =Replaces all occurrences of old with new.

20
Q

Which is the option to delete a line in vi or vim editor?

A

:dd

21
Q

What does the environment configuration file “/etc/profile” contain?

A

This is the generic file that is processed by all users upon login

22
Q

What does the environment configuration file “/etc/bashrc” contain?

A

This file is processed when subshells are started

23
Q

What does the environment configuration file “~/.bash_profile” contain?

A

In this file, user-specific login shell variables can be defined

24
Q

What does the environment configuration file “~/.bashrc” contain?

A

In this user-specific file, subshell variables can be defined

25
Q

What is a login shell and what is a sub shell?

A

A login shell is the first shell that is opened for a user after the user has logged in. From the login shell, a user may run scripts, which will start a subshell of that
login shell.

26
Q

what is the use of “/etc/motd” and “/etc/issue”?

A

Messages in /etc/motd display after a user has successfully logged in to a shell. Another way to send information to users is by using /etc/issue. The contents of this file display before the user logs in.

27
Q

Which command to use to find information in man pages or search the man pages?

A

you can search the mandb database by using

“apropos” or “man -k”

28
Q

What are the different categorizations of man pages?

A

1: Executable programs or shell commands
5: File formats and conventions
8: System administration commands

29
Q

Which command to use to update the mandb database?

A

mandb