Index

Symbols

& (ampersand) command, 237-238

(backslash) escape character, 433

~/.bash_profile, 43

~/.bashrc, 43

/boot directory, 5657

/dev directory, 56

. (dot), 553, 91

/etc directory, 56

/etc/anacrontab, 278279

/etc/bashrc, 43

/etc/crontab file, managing, 276278

/etc/default/grub, 395

/etc/default/useradd, 132133

/etc/dracut.conf, 412413

/etc/fstab, 332335

NFS share mounting, 520521

Samba share mounting, 521

/etc/group, 136137

/etc/gshadow, 137

/etc/hosts, 191192

/etc/httpd, 464465

/etc/httpd/conf/httpd.conf, 460463

/etc/issue, 43

/etc/login.defs, 133

/etc/logrotate.conf, 298

/etc/motd, 43

/etc/passwd, 89

fields, 128129

modifying, 131

/etc/profile, 43

/etc/shadow

fields, 129130

modifying, 131

/etc/sysconfig/selinux, 476

/etc/systemd/journald.conf, 303

--help option, 4445

/home directory, 56, 58

&& (logical AND), 553, 433

|| (logical OR), 564, 433

/media directory, 56

/mnt directory, 56

/opt directory, 56

$PATH, 553, 33

/proc directory, 56, 372

/ (root) directory, 56

/root directory, 56

/run directory, 56

#! (shebang), 569, 426

/srv directory, 56

/sys directory, 56

/tmp directory, 57

/usr directory, 5758

/usr/share/doc documentation files, 49

/var directory, 5758

/var/log, list of log files, 290

/var/log/messages, 290292

* (wildcard), 573

A

absolute filenames

defined, 553

overview, 6364

accessing respositories, 8

accounts. See group accounts; user accounts

ACLs (access control lists), 156160

changing/viewing settings, 157159

default ACLs, 159160

defined, 553

file system preparation, 157

support for, 156157

advanced permissions, 152156

aliases, 33

alternative port configuration, 447

ampersand (&) command, 237238

anacron

configuring, 278279

defined, 553

AND, 553, 433

Apache servers

configuration files, 460465

content creation, 463464

software requirements, 460

verifying availability, 464

virtual hosts, 465467

Application profile, 553

Application Stream, 553, 220

apropos command, 47

archiving

defined, 554

files

extracting tar files, 73

with tar, 72

arguments

defined, 33

in shell scripts, 428429

asterisk (*) wildcard, 573

at command, 281

defined, 554

task scheduling, 281

atq command, 281

atrm command, 281

attributes

defined, 554

user-extended, 162163

audit log

defined, 554

SELinux messages in, 488490

auditd, 554

authentication

key-based, 114115, 451452

to Samba shares, 518

autofs, 521523

configuring, 522

defined, 554

defining mounts, 522

overview, 521

wildcards in, 523

automount, 521523

configuring, 522

defined, 554

defining mounts, 522

overview, 521

wildcards in, 523

awk command, 9394

B

background processes

defined, 554

running, 236237

types of, 239

backslash () escape character, 433

backups

of ACLs, 157

defined, 554

Bash. See also shell scripting

commands

command-line completion, 39

executing, 33

help with, 4449

history, 3738

I/O redirection, 3435

pipes, 36

syntax, 3233

defined, 554, 32

escaping, 90

bash -x command, 438

bash-completion, 39

Basic Input Output System (BIOS), 554

batch command, 281

bg command, 237, 238

binary, 554

binary notation

for IP addresses, 172

BIOS (Basic Input Output System), 554

blkid command, 331332

Boolean settings for SELinux, 487488

boot loaders, 554

boot process

GRUB 2, 394397

changing configuration, 394395

configuration files, 395396

modifying default options, 396397

steps in, 404405

systemd targets

enabling services, 390391

isolating, 391394

setting default, 394

target units, 389390

tasks of, 388389

types of, 388

viewing, 391393

wants, 390

troubleshooting

accessing boot prompt, 406407

file system issues, 414415

overview, 405

recovering virtual machine access, 416418

re-creating initramfs image, 414

reinstalling GRUB 2, 413414

rescue disk usage, 408413

resetting root password, 416

starting troubleshooting targets, 407408

boot prompt, accessing, 406407

broadcast addresses, 171

BtrFS, 554

bunzip2 command, 74

bzip2 command, 74

C

cache, 555

cache tier, 356

capabilities, 555

case statement, 436437

cat command, 8485

CentOS

defined, 555

installing, 1024

obtaining, 7

Cert Guide environment setup, 910

certificate authority (CA), 555

certificates, 555

chage command, 133134

characters

counting, 8889

escaping, 433

chattr command, 163

chcon command, 481

chgrp command, 148

chmod command, 150152, 155

chown command

group ownership, 148

user ownership, 147148

chrony

defined, 555

time service client configuration, 537538

chroot, 555

chroot /mnt/sysimage command, 409410, 414

chvt command, 105

CIFS (Common Internet File System)

defined, 555

history of, 516517

mounting through fstab, 521

server configuration, 518519

shares

authentication, 518

discovering, 517518, 520

mounting, 518, 520

cloud, 555

command mode (vim), 40

command-line completion, 39

commands

command-line completion, 39

executing, 33

help with, 4449

/usr/share/doc documentation files, 49

--help option, 4445

info command, 4849

man command, 4548

mandb command, 4748

history, 3738

I/O redirection, 3435

LVM management, 353

pipes, 36

syntax, 3233

vim editor, 4041

Common Internet File System. See CIFS (Common Internet File System)

compression

defined, 555

overview, 7374

conditional loops, 432437

case statement, 436437

defined, 555

for loops, 429, 434435

if.then.else construction, 432434

until loops, 435436

while loops, 435436

configuration files

for Apache servers, 460465

GRUB 2, 395396

ifcfg, 189

modifying, 131

rsyslogd, 293, 297

in shell environment, 43

for user management, 132133

connections

defined, 555

devices versus, 180

fixed and dynamic IP addresses for, 189

SSH server options, 450

viewing properties, 182185

viewing status, 181

consoles

defined, 555, 102

local consoles

logging in, 102103

pseudo terminals, 106

switching terminals, 103105

remote access

with Secure Shell, 108110, 112

transferring files, 111112

context labels, 479481

context switches, 556

context types, 481485

defined, 556

finding via man pages, 484485

restoring defaults, 485486

setting, 481484

contexts, 556

Coordinated Universal Time (UTC), 556, 530

copying files

cp command, 6566

scp command, 112

counting words/lines/characters, 8889

cp command, 6566

createrepo command, 208

credentials files, 556

cron

anacron service, 278279

components of, 274

configuration file management, 276278

crond management, 274275

defined, 556

exercise, 280

security, 280

timing, 276

crond, managing, 274275

crontab command, 277

cryptography, 556

cut command, 84, 87

D

daemons, 236

date command, 532

daylight saving time, 530

debugging shell scripts, 438

deduplication, 556

default ACLs, 159160

default boot options, modifying, 396397

default file contexts, restoring, 485486

default ownership, 148149

default permissions, 160161

default routes, 556

default targets, setting, 394

default zones in firewalld, 501

deleting files, 66

dependencies

defined, 556

of units, managing, 263264

dependency hell, 556, 225

destinations

defined, 556

in rsyslogd, 294296

device files, 557, 35

device mappers, 557

devices

connections versus, 180

defined, 557

mounting, 5761, 331332

naming, 351352

df -hT command, 61

df -Th command, 59

dictionary attacks, 446

direct write logging, 288

directories. See also files

defined, 557

in FSH, 5657

home, 132

listing, 6465

managing, 6263

mounting, 5758

ownership

changing groups, 148

changing users, 147148

default ownership, 148149

viewing, 146147

permissions

ACLs, 156160

advanced, 152156

basic, 149152

default, 160161

user-extended attributes, 162163

disabled mode, 557

disabling

root login, 446

SELinux, 478479

disk device types, 315

disk labels, mounting with, 331332

distributions, 557

dmesg

analyzing kernel activity, 371372

defined, 557

dnf command, yum command and, 200

DNS name resolution, 192193

documentation files, 49

dot (.), 553, 91

downloading GPG keys, 206207

dracut command

defined, 557

re-creating initramfs image, 411413, 414

drivers, 371, 374375

checking availability, 379380

dynamic IP addresses, 174, 189

dynamic routes, 557

E

echo command, 43

editing files with vim, 3941

elevated permissions

running tasks with, 125

PolicyKit, 126

su command, 125

sudo command, 126

emergency reset, 108

emergency.target, 388

enabling

modules, 223

SELinux, 475476

services, 390391

enforcing mode, 557

entitlements, 201

env command, 42

environments, 557

EPEL (Extra Packages for Enterprise Linux) repositories, 201

epoch time, 557, 532

escaping

characters, 433

defined, 557

regular expressions, 90

exam preparation, 541544

nondisclosure agreement (NDA), 544

registering for exam, 541542

SELinux coverage, 492

theoretical pre-assessment exam, 545547

tips for taking exam, 542544

verifying readiness, 541

what to bring to exam, 542

examples

/etc/crontab file, 277

/etc/default/grub, 395

/etc/default/useradd, 132133

/etc/dracut.conf, 412413

/etc/fstab, 333

/etc/group, 136

/etc/hosts, 191192

/etc/httpd, 464

/etc/httpd/conf/httpd.conf, 461463

/etc/logrotate.conf, 298

/etc/passwd, 89, 128

/etc/shadow, 129

/etc/sysconfig/selinux, 476

/etc/systemd/journald.conf, 303

/var/log/messages, 291

anacron configuration, 279

analyzing kernel activity, 372

arguments in shell scripts, 428

basic script example, 426

blkid command, 332

case statement, 437

chage command, 134

CIFS share discovery, 517

connection properties, 182185

connection status, 181

context label viewing, 480

counting with wc command, 89

cron job in /etc/cron.d, 278

current environment display, 42

debugging shell scripts, 438

df -hT command, 61

file ownership display, 147

file system formatting with XFS, 326327

filtering with cut command, 87

findmnt command, 5960

firewall configuration, 504

firewalld services, 502

for loops, 434

ftp service file, 503

GPG key downloads, 206207

group ACL changes, 158

hostname configuration, 190191

hostnamectl status command, 373

id command, 124

ifcfg configuration files, 189

if.then.else construction, 433

ip addr show command, 176

ip link show command, 177

ip route show command, 178179

journalctl -o verbose command, 301302

kernel thread viewing, 239240

line anchors, 90

link properties, 70

listing kernel threads, 370

log file viewing from journald, 299300

log file viewing with systemctl status command, 289

logging in with Secure Shell, 110

lsblk command, 349

lsmod command, 376

lspci command, 379380

LVM device naming, 352

modinfo command, 377378

monitoring time synchronization status, 534535

mount command, 5859

mount units, 258

multi-user.target, 389

newgrp command, 149

permissions checking, 158

physical volume verification, 348

ps aux command, 88

ps -ef command, 240241

ps fax command, 241242

pvcreate command, 345

pvdisplay command, 348

read command in shell scripts, 430

regular expression necessity, 8990

repository availability verification, 209

repository file, 204205

RULES section of rsyslog.conf, 294

screen command, 115116

sealert command, 490491

searching man pages, 46

SELinux messages in audit.log, 489

semanage fcontext usage, 483

service units, 257

sestatus command, 477

socket units, 259

ss -lt command, 179

systemctl list-dependencies command, 263264

systemctl show command, 265

systemctl status command, 262

systemctl status crond -l command, 275

systemd mount units for VDO, 360361

systemd targets, 391393

target units, 260

time zone settings, 536537

timedatectl command, 533

tune2fs command, 327328

udevadm monitor command, 375

unit types in systemd, 256

until loops, 436

uptime command, 247

vgdisplay command, 350

volume groups resizing verification, 354

web server availability verification, 464

while loops, 435

yum groups info command, 218

yum groups list command, 217

yum history command, 219

yum info nmap command, 211212

yum install nmap command, 212213

yum list command, 214

yum list kernel command, 215

yum module info command, 223

yum module list command, 221222

yum module list perl command, 223

yum search command, 210

yum update command, 215216

execute permissions, 149152

executing commands, 33

exercises

ACLs (access control lists), 160

advanced permissions, 156

Apache virtual host configuration, 466467

at task scheduling, 281

automount configuration for NFS, 522

bash-completion, 39

basic permission management, 152

connection parameter changes with nmcli, 186

context label setting, 483484

cron task scheduling, 280

directory management, 6263

file management, 6768

file system creation, 327

firewall management with firewall-cmd, 503505

GPT partition creation with gdisk, 321324

GPT partition creation with parted, 325

grep options, 93

group account management, 137

GRUB 2 modifications, 397

head command, 86

history (in Bash), 38

if.then.else construction, 434

info command, 49

input in shell scripts, 431

internal and external commands, 34

I/O redirection and pipes, 3637

isolating targets, 394

journalctl command, 300301

kernel module management, 378

kernel modules with parameters, 380

less command, 85

live log file monitoring, 292

load average management, 248

local time management, 534

logging in with Secure Shell, 109110

logical partition creation, 319320

logical volume resizing, 355356

man -k command, 48

MBR partition creation with fdisk, 316318

module management, 224225

mounting partitions through /etc/fstab, 335

mounts overview, 60

network configuration validation, 177

network connections management with nmcli, 186

network settings verification, 179180

NFS share mounting, 516

NFS share offering, 515

package management with yum, 219

physical volume creation, 346347

positional parameters, 429

preserving systemd journal, 303

process management from command line, 245

pseudo terminals, 106

remote access with public/private keys, 114115

remote access with Secure Shell, 112

repository creation, 208209

rescuing system, 410411

restorecon command, 486

RPM queries, 228229

rsyslog.conf rule changes, 297

Samba server configuration, 519

SELinux Boolean settings, 488

SELinux mode manipulation, 478

SELinux-specific man pages, 485

shell environment management, 44

shell job management, 238

simple shell script creation, 427

SMB share discovery and mounting, 520

SSH security option configuration, 449

Stratis volume management, 358359

swap partition creation, 330

switching terminals, 104

switching user accounts, 127

symbolic links and hard links, 71

tail command, 86

tar, 75

time service client configuration, 538

troubleshooting targets, 408

tuned, 249

unit configuration changes, 266

unit management with systemctl, 261

user account creation, 135

VDO storage management, 361

vim practice, 41

volume group and logical volume creation, 352

web server setup, 463

wildcard automount configuration, 523

exit command, 427

exports, 557

Ext2, 557

Ext3, 557

Ext4

defined, 557

property management, 327329

extended partitions

defined, 557

on MBR, 319320

external commands, 558, 33

Extra Packages for Enterprise Linux (EPEL) repositories, 201

extracting tar files, 73

F

facilities

defined, 558

in rsyslogd, 294296

fdisk command, 315320

Fedora

defined, 558

obtaining, 8

fg command, 237, 238

FHS (Filesystem Hierarchy Standard)

defined, 558

mounts, 5761

overview, 5657

file command, 73

file descriptors, 558

file systems. See also storage

ACL preparation, 157

automount, 521523

configuring, 522

defining mounts, 522

overview, 521

wildcards in, 523

CIFS

authentication, 518

discovering shares, 517518, 520

history of, 516517

mounting shares, 518, 520

mounting through fstab, 521

server configuration, 518519

creating, 325327

defined, 558

mounting, 330335

automating with /etc/fstab, 332335

with device name/UUID/disk label, 331332

manually, 331

NFS

automount configuration, 522

mounting shares, 515516

mounting through fstab, 520521

security, 514

versions, 514515

property management, 327329

troubleshooting, 414415

types of, 326

files. See also directories; text files

absolute and relative fileames, 6364

archiving

extracting tar files, 73

with tar, 72

compressing, 7374

copying

cp command, 6566

scp command, 112

deleting, 66

editing with vim, 3941

links

creating, 6970

hard links, 6869, 71

removing, 7071

symbolic links, 69, 71

listing, 6465

moving, 66

ownership

changing groups, 148

changing users, 147148

default ownership, 148149

viewing, 146147

permissions

ACLs, 156160

advanced, 152156

basic, 149152

default, 160161

user-extended attributes, 162163

synchronizing, 112

transferring securely, 111112

wildcards, 6162

Filesystem Hierarchy Standard. See FHS (Filesystem Hierarchy Standard)

filtering text files

with cut command, 87

with head command, 86

with tail command, 86

find command, 147

finding

context types, 484485

packages, 210211

findmnt command, 5960

firewall-cmd command, 503506

firewalld, 500503

defined, 558

services, 502503

zones, 501

firewalls

defined, 558

firewall-cmd command, 503506

firewalld, 500503

services, 502503

zones, 501

netfilter, 500

viewing configuration, 504

first lines of text files, viewing, 86

fixed IP addresses, 174, 189

folders, 558. See also directories

foreground processes

defined, 559

running, 236237

for loops, 429, 434435

fsck command, 414

fstab, 559, 332335

NFS share mounting, 520521

Samba share mounting, 521

G

gdisk command, 320324

GECOS, 559

getenforce command, 476

getfacl command, 157159

getsebool command, 487

GiB, 9

global unique ID (GUID), 559

GPG keys, downloading, 206207

GPT (GUID Partition Table)

creating

with gdisk command, 320324

with parted command, 324325

defined, 559

overview, 313

graphical applications with Secure Shell, 111

graphical.target, 388

grep command, 242

options, 9293

group accounts

creating, 136137

groupadd command, 137

vigr command, 136137

membership checking, 137

property management, 137

types of, 135136

group owners

changing, 148

defined, 559

groupadd command, 137

groupmems command, 137

groupmod command, 137

groups

defined, 559

of packages, 216218

groups command, 148

GRUB 2, 394397

accessing boot prompt, 406407

changing configuration, 394395

configuration files, 395396

defined, 559

modifying default options, 396397

reinstalling, 411, 413414

grub2-install command, 413414

grub2-mkconfig command, 396397

GUID (global unique ID), 559

GUID Partition Table. See GPT (GUID Partition Table)

gunzip command, 74

gzip command, 559, 74

H

hard links

defined, 560

exercise, 71

overview, 6869

hardware clock, 530

hardware initialization, 371, 374375

checking driver availability, 379380

hardware time, 560

head command, 84, 86

help with commands, 4449

/usr/share/doc documentation files, 49

--help option, 4445

info command, 4849

man command, 4548

mandb command, 4748

hexadecimal, 560

history

in Bash, 3738

of CIFS, 516517

of packages, 218219

home directories, 132

hostnamectl set-hostname command, 190

hostnamectl status command, 190, 373

hostnames, 190192

hosts, 170. See also virtual hosts

httpd package, 460

hwclock command, 532

hypervisors, 560

I

id command, 124

ifcfg configuration files, 189

ifconfig command, 175

if.then.else construction, 432434

info command, 4849

inheritance, 560

init, 560

initramfs

defined, 560

re-creating from rescue disk, 411414

inodes, 560, 68

input in shell scripts, 430431

input mode (vim), 40

input modules, 560

insmod command, 378

installing

modules, 224

packages, 212213

RHEL

advantages of subscription, 6

Cert Guide environment, 910

free alternatives, 7

manual installation, 1024

obtaining, 7

repository access, 8

setup requirements, 9

interfaces, 560

internal commands, 561, 33

Internet Protocol (IP), 561

I/O redirection, 3435

IP (Internet Protocol), 561

ip addr command, 175

ip addr show command, 175176

ip command, 175177

ip link command, 175

ip link show command, 177

ip route command, 175

ip route show command, 178

iptables command, 561, 500

IPv4 addresses

binary notation, 172

defined, 561, 170

fixed versus dynamic, 174

overview, 170171

subnet masks, 171

validating configuration, 175177

IPv6 addresses

defined, 561, 170

overview, 171

isolating systemd targets, 391394

iterations, 561

J

jobs

defined, 561

shell jobs. See shell jobs

jobs command, 237238

journalctl command, 561, 288, 299302

journalctl -o verbose command, 301302

journald, 299303

defined, 561, 288

journalctl command, 299302

overview, 288289

preserving systemd journal, 302303

K

kernel

analyzing activity, 371373

defined, 561, 370

drivers, 371, 374375

upgrading, 381

kernel modules, 373, 376380

drivers, checking availability, 379380

listing, 376

loading/unloading, 378

parameter management, 380

viewing information about, 377378

kernel ring buffer, 561

kernel space, 561

kernel threads

defined, 236

listing, 370

showing, 239240

Kernel-based Virtual Machine (KVM), 561

key-based authentication, 114115, 451452

key-based logins, 562

kill command, 562, 239, 244245

killall command, 245

KVM (Kernel-based Virtual Machine), 561

L

labels, 562

last lines of text files, viewing, 86

less command, 8485

line anchors, 562, 90

lines, counting, 8889

links

creating, 6970

hard links, 6869, 71

removing, 7071

symbolic links, 69, 71

Linux, 562

listing

directories, 6465

files, 6465

firewalld services, 502

kernel modules, 376

kernel threads, 370

modules, 221223

packages, 214215

live log file monitoring, 292

ln command, 6970

load average for processes, 247

loading kernel modules, 378

local consoles

logging in, 102103

pseudo terminals, 106

switching terminals, 103105

local time

defined, 530

managing, 534

time zone settings, 535537

log files

journald, 299303

journalctl command, 299302

overview, 288289

preserving systemd journal, 302303

rotating, 297299

rsyslogd, 293297

configuration files, 293, 297

facilities/priorities/destinations, 294296

overview, 288289

for SELinux

in audit log, 488490

sealert command, 490491

types of, 288

viewing

with journalctl -o verbose command, 301302

from journald, 299300

live monitoring, 292

sample content, 290292

with systemctl status command, 289

in /var/log, 290

log rotation

defined, 562

overview, 297299

logger command, 292

logging in

disabling root login, 446

with key-based authentication, 114115

to local consoles, 102103

to remote servers, 108110, 112

logical AND (&&), 553, 433

logical extent, 562

logical OR (||), 564, 433

logical partitions

defined, 562

on MBR, 319320

Logical Volume Manager. See LVM (Logical Volume Manager)

logical volumes

creating, 344345, 351352

defined, 562

resizing, 353356

login shells, 562

loopback interfaces, 176

loops. See conditional loops

ls command, 6465, 70

ls -l command, 146147

lsblk command, 348349

lscpu command, 247

lsmod command, 376

lspci command, 379380

lvcreate command, 353

lvdisplay command, 353

lvextend command, 354

LVM (Logical Volume Manager)

advantages of, 343344

architecture, 342343

commands, 353

defined, 562

device naming, 351352

logical volumes

creating, 344345, 351352

resizing, 353356

partitions, creating, 347

physical volumes

creating, 346349

verifying, 348

volume groups

creating, 349350, 352

resizing, 353354

lvremove command, 353

lvresize command, 354355

lvs command, 353

M

MAC addresses, 173

man command, 4548

man -k command, 4648

man pages

finding context types, 484485

searching, 46

for semanage command, 482483

mandb command, 4748

masquerading, 563

MBR (Master Boot Record)

creating with fdisk, 315318

defined, 563

extended and logical partitions, 319320

overview, 312313

measurement units for storage, 314

mkfs command, 326327

modinfo command, 377378

modprobe command, 378

modular kernel. See kernel modules

modules

defined, 563, 220

enabling, 223

information about, 223

installing, 224

listing, 221223

managing, 221225

terminology, 220

more command, 85

mount command, 5859, 331, 518

mounting

file systems, 330335

automating with /etc/fstab, 332335

with device name/UUID/disk label, 331332

manually, 331

NFS shares, 515516, 520521

Samba shares, 518, 520521

mounts, 5761

defined, 563

defining in automount, 522

in systemd, 258

for VDO, 360361

wildcard configuration, 523

moving files, 66

multiplier, 563

multi-user.target, 388, 389

mv command, 66

N

naming devices, 351352

nano editor in systemd, 266

NAT (Network Address Translation), 171. See also masquerading

NDA (nondisclosure agreement), 544

netfilter

defined, 563

overview, 500

netmask. See subnet masks

netstat command, 178

Network Address Translation (NAT), 171. See also masquerading

Network File System. See NFS (Network File System)

network masks. See subnet masks

network time, 563

Network Time Protocol (NTP)

defined, 563

overview, 531

networking

configuring, 180189

with nmcli command, 181187

with nmtui command, 187189

permissions for, 180181

DNS name resolution, 192193

hostnames, 190192

IPv4 addresses, 170171

binary notation, 172

fixed versus dynamic, 174

subnet masks, 171

validating configuration, 175177

IPv6 addresses, 170, 171

MAC addresses, 173

port addresses, 173

validating, 178179

protocols, 173

routing, validating, 178

verifying settings, 179180

newgrp command, 149

NFS (Network File System)

automount configuration, 522

defined, 563

mounting shares, 515516

mounting through fstab, 520521

security, 514

versions, 514515

nftables command, 564, 500

nice command, 564, 242244

nmcli command, 180187

nm-connection-editor command, 188

nmtui command, 180, 187189

nodes, 170

nohup command, 239

nondisclosure agreement (NDA), 544

normal user accounts, system accounts versus, 127130

NTP (Network Time Protocol)

defined, 563

overview, 531

O

octal, 564

optimization with tuned, 248249

options, 32

OR, 564, 433

output modules, 564

ownership

changing groups, 148

changing users, 147148

default, 148149

defined, 564

viewing, 146147

P

package groups, 564

Package Module Streams, 220

packages

defined, 564

finding, 210211

groups of, 216218

history of, 218219

information about, 211212

installing, 212213

listing, 214215

managing, 219

modules. See modules

Package Module Streams, 220

removing, 213214

repoquery command, 228

repositories. See repositories

rpm command, 225

database queries, 226

filename parts, 226

package file queries, 227228

query usage, 228229

updating, 215216

pagers, 564

parent shells, 565

parent-child relations for shell jobs, 239

parted command, 324325, 347

partitions

advantages of multiple, 312

defined, 565

disk device types, 315

GPT (GUID Partition Table), 313

gdisk command, 320324

parted command, 324325

LVM partition creation, 347

MBR (Master Boot Record), 312313

creating with fdisk, 315318

extended and logical partitions, 319320

swap files, 330

swap partitions, 329330

utilities for, 314315

partprobe command, 320

passphrases

configuring, 451452

defined, 565

overview, 114

passwd command, 133134

passwords

defined, 565

dictionary attacks, 446

resetting root password, 416

user account properties, 133134

paths, 565

performance optimization with tuned, 248249

permissions

ACLs, 156160

changing/viewing settings, 157159

default ACLs, 159160

file system preparation, 157

support for, 156157

advanced, 152156

basic, 149152

default, 160161

defined, 565

elevating, 125

PolicyKit, 126

su command, 125

sudo command, 126

networking configuration changes, 180181

user-extended attributes, 162163

permissive mode, 565

physical extent, 565

physical volumes

creating, 346349

defined, 565

verifying, 348

PID (process identification number), 566

pinfo command, 4849

pipes

defined, 565

less command, 84

overview, 36

pkill command, 245

PolicyKit, 125126

pools

creating, 357

defined, 356

managing, 358359

port addresses, 173

validating, 178179

port forwarding, 565

port scans, avoiding, 447

Portable Operating System Interface (POSIX), 566

portmappers, 566

ports

alternative port configuration, 447

changing SELinux labels, 447448

defined, 565

positional parameters in shell scripts, 428429

POSIX (Portable Operating System Interface), 566

preparation for exam, 541544

nondisclosure agreement (NDA), 544

registering for exam, 541542

theoretical pre-assessment exam, 545547

tips for taking exam, 542544

verifying readiness, 541

what to bring to exam, 542

primary groups

changing, 149

defined, 566, 131

primary partition, 566

priorities

defined, 566

of processes, adjusting, 242244

in rsyslogd, 294296

private keys, 566

private network addresses, 170171

privileged users. See root

proc, 566

process identification number (PID), 566

process management

from command line, 245

kill command, 244245

nice command, 242244

performance optimization, 248249

processes versus threads, 239240

ps command, 240242

shell jobs

managing, 237239

parent-child relations, 239

running in foreground/background, 236237

top command, 246248

types of processes, 236

processes

adjusting priority, 242244

defined, 566

information about, 240242

load average, 247

sending signals to, 244245

states of, 247

threads versus, 239240

types of, 236

profiles

defined, 566, 220

tuned, 248

programmatic API in Stratis, 356

protocols

defined, 566

for networking, 173

ps aux command, 88, 239240

ps command, 240242

Pseudo Root File System, 566

pseudo rout mount, 567

pseudo terminals, 106

public keys, 567

pvcreate command, 345, 353

pvdisplay command, 348, 353

pvremove command, 353

pvs command, 353

pwd command, 63

Q

querying

exercise, 228229

repositories, 228

RPM database, 226

RPM package files, 227228

queues, 567

R

read command, 430

read permissions, 149152

real-time clock, 567, 530

reboot

defined, 567

during exam, 544

overview, 106108

Red Hat Customer Portal, 567

Red Hat Enterprise Linux. See RHEL (Red Hat Enterprise Linux)

Red Hat Package Manager, 567

redirectors, 3435

reference clock, 567

registering

for exam, 541542

RHEL, 201

regular expressions, 8992

awk and sed commands, 9394

defined, 567

escaping, 90

grep options, 9293

line anchors, 90

wildcards, 9192

reinstalling GRUB 2, 411, 413414

relative filenames

defined, 568

overview, 6364

remote access

with key-based authentication, 114115

with Secure Shell, 108110, 112

transferring files, 111112

rsync command, 112

scp command, 112

sftp command, 112

Remote Procedure Calls (RPC), 568

removing

links, 7071

packages, 213214

renice command, 242244

repoquery command, 228

repositories

accessing, 8

creating, 208209

defined, 568

querying, 228

role of, 200201

security, 206207

specifying, 202205

repository files

example, 204205

options, 205

requirements for RHEL, 9

rescue disks, 408413

re-creating initramfs image, 411413, 414

reinstalling GRUB 2, 411, 413414

restoring system access, 409411

rescue.target, 388

resident memory, 568

resizing

logical volumes, 353356

volume groups, 353354

resolver, 568

restorecon command, 482, 485486

restoring

default file contexts, 485486

system access with rescue disk, 409411

RHEL (Red Hat Enterprise Linux)

defined, 67, 567

installing manually, 1024

preparation for installation

advantages of subscription, 6

Cert Guide environment, 910

free alternatives, 7

obtaining, 7

repository access, 8

setup requirements, 9

registering, 201

rich rules, 568

rm command, 66

rmmod command, 378

root

defined, 568

disabling login, 446

overview, 124125

PolicyKit, 126

resetting password, 416

su command, 125

sudo command, 126

root directory, 568

rotating log files, 297299

routing, validating, 178

RPC (Remote Procedure Calls), 568

rpm command, 225

database queries, 226

downloading GPG keys, 206

filename parts, 226

package file queries, 227228

query usage, 228229

RPM packages. See packages

rpm -q --scripts, 227

rpm -qa command, 226, 228

rpm -qc command, 226227

rpm -qd command, 226227

rpm -qf command, 226227

rpm -qi command, 226227

rpm -ql command, 226227

rpm -qp command, 227228

rpm -qR command, 227

rpm -V command, 228

rpm -Va command, 228

rsync command, 112

rsyslogd, 293297

configuration files, 293, 297

defined, 568, 288

facilities/priorities/destinations, 294296

overview, 288289

RULES section of rsyslog.conf, 294

running processes, 247

S

Samba

defined, 568

history of CIFS, 516517

server configuration, 518519

shares

authentication, 518

discovering, 517518, 520

mounting, 518, 520

mounting through fstab, 521

SAN (storage-area network), 570

scheduler, 568

scheduling tasks

at, 281

cron

anacron service, 278279

components of, 274

configuration file management, 276278

crond management, 274275

exercise, 280

security, 280

timing, 276

Scientific Linux

defined, 568

obtaining, 8

scp command, 112

screen command, 115116

scripts. See shell scripting

sealert command, 490491

searching

man pages, 46

text files, 8992

secondary groups, 569, 131

Secure Shell. See SSH (Secure Shell)

Secure Sockets Layer (SSL). See Transport Layer Security (TLS)

security

cron, 280

for NFS, 514

repositories, 206207

SSH server hardening, 446449

alternative port configuration, 447

disabling root login, 446

limiting user access, 448449

SELinux port labels, 447448

sed command, 9394, 110

SELinux

Boolean settings, 487488

changing port labels, 447448

context labels, 479481

context types, 481485

finding via man pages, 484485

restoring defaults, 485486

setting, 481484

defined, 569

disabling, 478479

elements of, 475

enabling, 475476

exam preparation for, 492

log files

in audit log, 488490

sealert command, 490491

modes, 475479

SELinux Policy, 569

semanage command, 481483

semanage port command, 447448

Server Message Block. See SMB (Server Message Block)

services

defined, 569, 256

enabling, 390391

in firewalld, 502503

in systemd, 257258

session options for SSH server, 450

sestatus command, 476477

set group ID (SGID) permission, 153155

set user ID (SUID) permission, 152153, 155

setenforce command, 476

setfacl command, 157159

setroubleshoot-server package, 491

setsebool command, 488

setup requirements for RHEL, 9

sftp command, 112

SGID (set group ID) permission, 153155

shares

CIFS

authentication, 518

discovering, 517518, 520

mounting, 518, 520

mounting through fstab, 521

defined, 569

NFS

mounting, 515516

mounting through fstab, 520521

shebang (#!), 569, 426

shell environment

/etc/motd and /etc/issue, 43

configuration files, 43

variables, 4243

shell jobs

defined, 236

managing, 237239

parent-child relations, 239

running in foreground/background, 236237

shell metacharacters, 569

shell scripting

arguments, 428429

conditional loops, 432437

case statement, 436437

for loops, 429, 434435

if.then.else construction, 432434

until loops, 435436

while loops, 435436

debugging scripts, 438

elements of, 426427

variables, 430431

shells, 569, 32. See also Bash; shell scripting

showmount command, 516

signals

defined, 569

sending to processes, 244245

sleeping processes, 247

SMB (Server Message Block)

defined, 569

history of CIFS, 516517

server configuration, 518519

shares

authentication, 518

discovering, 517518, 520

mounting, 518, 520

mounting through fstab, 521

smbclient command, 517518

snapshots

defined, 569, 344

managing, 358

in Stratis, 356

sockets in systemd, 259

soft links. See symbolic links

software clock, 530

software management. See also yum command

modules

enabling, 223

information about, 223

installing, 224

listing, 221223

managing, 221225

terminology, 220

packages

finding, 210211

groups of, 216218

history of, 218219

information about, 211212

installing, 212213

listing, 214215

managing, 219

Package Module Streams, 220

removing, 213214

updating, 215216

registering RHEL, 201

repoquery command, 228

repositories

creating, 208209

querying, 228

role of, 200201

security, 206207

specifying, 202205

rpm command, 225

database queries, 226

filename parts, 226

package file queries, 227228

query usage, 228229

subscription management, 201

software requirements for Apache servers, 460

software time. See system time

sort command, 84, 8788

sorting, text files with sort command, 8788

source context, 569

special permissions. See advanced permissions

ss -lt command, 178179

SSH (Secure Shell)

connection options, 450

defined, 569, 108

graphical applications with, 111

key-based authentication, 114115, 451452

list of configuration options, 451

remote access with, 108110, 112

server hardening, 446449

alternative port configuration, 447

disabling root login, 446

limiting user access, 448449

SELinux port labels, 447448

session options, 450

transferring files, 111112

rsync command, 112

scp command, 112

sftp command, 112

ssh command, 108110, 111

ssh-add command, 452

ssh-agent command, 452

ssh-copy-id command, 114

sshd. See SSH (Secure Shell)

ssh-keygen command, 114

SSL (Secure Sockets Layer). See Transport Layer Security (TLS)

star command, 73

static routes, 570

STDERR (standard error)

defined, 570

overview, 34

STDIN (standard input)

defined, 570

overview, 34

STDOUT (standard output)

defined, 570

overview, 34

sticky bit, 154155

stopped processes, 247

storage. See also file systems

LVM

advantages of, 343344

architecture, 342343

commands, 353

device naming, 351352

logical volume creation, 344345, 351352

logical volume resizing, 353356

partition creation, 347

physical volume creation, 346349

physical volume verification, 348

volume group creation, 349350, 352

volume group resizing, 353354

measurement units, 314

partitions

advantages of multiple, 312

disk device types, 315

formatting with file system, 326327

GPT (GUID Partition Table), 313, 320325

LVM partition creation, 347

MBR (Master Boot Record), 312313, 315320

swap files, 330

swap partitions, 329330

utilities for, 314315

Stratis

architecture, 356357

features of, 356

pool creation, 357

pool management, 358359

VDO

configuring, 360361

overview, 359360

storage-area network (SAN), 570

Stratis

architecture, 356357

defined, 570

features of, 356

pools

creating, 357

managing, 358359

stratis blockdev command, 358

stratis filesystem command, 358

stratis pool add-data command, 358

stratis pool command, 358

stratum, 570

streams, 220

su command, 125

subnet masks

defined, 570

overview, 171

subscription management, 201

subscription-manager tool, 201

subshells, 570

sudo command, 125, 126

SUID (set user ID) permission, 152153, 155

superuser. See root

swap files, 330

swap partitions, 329330

switching

terminals, 103105

user accounts, 127

symbolic links

defined, 570

exercise, 71

overview, 69

synchronizing

files, 112

time, 534535

sysfs, 570

system accounts, normal user accounts versus, 127130

system logging. See log files

system time, 570, 530

systemctl command, 256, 261263

systemctl disable command, 390

systemctl edit command, 265

systemctl enable command, 260, 390

systemctl get-default command, 394

systemctl halt command, 107

systemctl isolate command, 393

systemctl list-dependencies command, 260, 263264

systemctl poweroff command, 107

systemctl set-default command, 394

systemctl show command, 265

systemctl status command, 262, 289, 464

systemctl status crond -l command, 274275

systemctl status -l chronyd command, 534535

systemctl status NetworkManager command, 180

systemd

defined, 570

preserving journal, 302303

rebooting, 107

units

configuration changes, 266

dependency management, 263264

locations, 256257

managing, 261263

mounts, 258, 360361

option management, 265266

services, 257258

sockets, 259

targets, 259260

types of, 256

systemd targets

enabling services, 390391

isolating, 391394

setting default, 394

target units, 389390

tasks of, 388389

types of, 388

viewing, 391393

wants, 390

systemd-udevd, 374

T

tac command, 85

tail command, 84, 86

tail -f command, 292

tainted kernel, 571, 371

Tape ARchiver (tar) utility. See tar

tar, 7173

compressing files, 7374

creating archives, 72

defined, 571

exercise, 75

extracting files, 73

options, 74

target context, 571

targets

defined, 571

starting for troubleshooting, 407408

in systemd, 259260

enabling services, 390391

isolating, 391394

setting default, 394

target units, 389390

tasks of, 388389

types of, 388

viewing, 391393

wants, 390

task scheduling

at, 281

cron

anacron service, 278279

components of, 274

configuration file management, 276278

crond management, 274275

exercise, 280

security, 280

timing, 276

terminals

defined, 571, 102

pseudo, 106

screen command, 115116

switching, 103105

virtual, 104105

test command, 430431, 432

text files

counting words/lines/characters with wc command, 8889

filtering

with cut command, 87

with head command, 86

with tail command, 86

regular expressions, 8992

awk and sed commands, 9394

escaping, 90

grep options, 9293

line anchors, 90

wildcards, 9192

sorting with sort command, 8788

tools for, 8084

viewing

with cat command, 85

first/last lines of, 86

with less command, 8485

theoretical pre-assessment exam, 545547

thin allocation, 571

thin provisioning, 356

threads

defined, 571, 236

processes versus, 239240

time

date command, 532

epoch time, 532

hwclock command, 532

local time management, 534

monitoring synchronization status, 534535

NTP (Network Time Protocol), 531

time service clients, 537538

time zone settings, 535537

timedatectl command, 532, 533

types of, 530

time service clients, configuring, 537538

time stamps, 571

time synchronization, 571

time zone settings, 535537

timedatectl command, 532533

timers, 571

timing in cron, 276

TLS (Transport Layer Security), 571

top command, 246248

transferring, files securely, 111112

Transport Layer Security (TLS), 571

troubleshooting boot process

accessing boot prompt, 406407

file system issues, 414415

overview, 405

recovering virtual machine access, 416418

re-creating initramfs image, 414

reinstalling GRUB 2, 413414

rescue disk usage, 408413

resetting root password, 416

starting troubleshooting targets, 407408

TTY, 571

tune2fs command, 327329

tuned

defined, 571

performance optimization, 248249

profile overview, 248

tuned-adm command, 249

tzselect command, 536537

U

udev, 572

udevadm monitor command, 374375

UEFI (Unified Extensible Firmware Interface), 572

umask

defined, 572

setting default permissions, 160161

umount command, 572, 331

uname command, 373

Unified Extensible Firmware Interface (UEFI), 572

uninterruptable sleep processes, 247

units

configuration changes, 266

defined, 572

dependency management, 263264

locations, 256257

managing, 261263

mounts, 258, 360361

option management, 265266

services, 257258

sockets, 259

targets, 259260, 389390

types of, 256

universally unique ID (UUID)

defined, 572

mounting with, 331332

unloading kernel modules, 378

unprivileged users, 572

until loops, 435436

updating

mandb database, 4748

packages, 215216

upgrading kernel, 381

uptime command, 247

user accounts

creating, 131132, 135

home directories, 132

modifying configuration files, 131

useradd command, 131

id command, 124

limiting SSH server access, 448449

password properties, 133134

property management, 132134

root, 124125

PolicyKit, 126

su command, 125

sudo command, 126

switching, 127

system versus normal accounts, 127130

user environment, creating, 134

user environments, creating, 134

user ownership, changing, 147148

user space, 572

useradd command, 131

userdel command, 131

user-extended attributes, 162163

usermod command, 132

users, 572

UTC (Coordinated Universal Time), 556, 530

UUID (universally unique ID)

defined, 572

mounting with, 331332

V

validating

IPv4 address configuration, 175177

port availability, 178179

routing, 178

values, 572

variables

defined, 572

in shell environment, 4243

in shell scripts, 430431

VDO (Virtual Data Optimizer)

configuring, 360361

defined, 572

overview, 359360

verifying

exam readiness, 541

network settings, 179180

physical volumes, 348

web server availability, 464

VFAT, 572

vgcreate command, 349350, 353

vgdisplay command, 350, 353

vgextend command, 353354

vgreduce command, 353354

vgremove command, 353

vgs command, 353, 354

viewing

ACL settings, 157159

connection properties, 182185

connection status, 181

context labels, 480

firewall configuration, 504

hostname configuration, 190191

kernel module information, 377378

log files

with journalctl -o verbose command, 301302

from journald, 299300

live monitoring, 292

sample content, 290292

with systemctl status command, 289

in /var/log, 290

ownership, 146147

systemd targets, 391393

text files

with cat command, 85

first/last lines of, 86

with less command, 8485

vigr command, 136137

vim editor

commands, 4041

overview, 3941

in systemd, 266

vimtutor command, 40

vipw command, 131

virtual console tty1, 105

Virtual Data Optimizer. See VDO (Virtual Data Optimizer)

virtual hosts

for Apache servers, 465467

defined, 572

virtual machines (VMs), recovering access, 416418

virtual memory, 572

virtual terminals, 104105

visudo command, 126

VMs (virtual machines), recovering access, 416418

volume groups

creating, 349350, 352

defined, 572

resizing, 353354

volume-managing file systems, 356

W

want, 573

wants, 573, 390

wc command, 84, 8889

web servers. See Apache servers

while loops, 435436

wildcards

in automount, 523

defined, 573

file management, 6162

regular expressions, 9192

words, counting, 8889

write permissions, 149152

X

X forwarding, 111

XFS

defined, 573

property management, 329

xfs_admin command, 329

Y

YUM (Yellowdog Update, Modified)

defined, 573, 200

repositories, role of, 200201

yum command

common tasks, 209210

dnf command and, 200

modules

enabling, 223

information about, 223

installing, 224

listing, 221223

managing, 221225

packages

finding, 210211

groups of, 216218

history of, 218219

information about, 211212

installing, 212213

listing, 214215

managing, 219

removing, 213214

updating, 215216

yum group command, 216

yum groupinstall command, 216

yum groups info command, 217218

yum groups list command, 216217

yum history command, 218219

yum info command, 211212

yum install command, 212213, 225

yum install kernel command, 381

yum list command, 214215

yum localinstall command, 225

yum module enable command, 223

yum module info command, 223

yum module install command, 224

yum module list command, 221223

yum provides command, 211

yum remove command, 213214

yum repolist command, 209

yum search command, 210211

yum update command, 215216

yum upgrade kernel command, 381

yum whatprovides command, 211

Z

zombie processes, 247

zombies, 573

zones

defined, 573

in firewalld, 501

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.149.251.142