Shell and help

  • alias, unalias

    Make a short name for a longer command (alias), or remove it (unalias).

    RHCSA exam2 options, 11 examples

  • apropos, whatis

    Search the short descriptions of the man pages (apropos), or show the description of one page (whatis).

    RHCSA exam15 options, 11 examples

  • bash

    The Bourne Again Shell: the default command shell of RHEL, and the program that runs shell scripts.

    RHCSA exam20 options, 10 examples

  • chvt

    Switch the screen of the machine to another virtual terminal (tty1 … tty12).

    Everyday Linux Yes3 options, 10 examples

  • clear

    Clean the terminal screen (and, by default, the scrollback buffer).

    Everyday Linux3 options, 11 examples

  • echo

    Print text or the value of variables to the screen (or to a file with redirection).

    RHCSA exam13 options, 12 examples

  • env

    Show the environment variables, or run a program with a changed environment.

    RHCSA exam13 options, 11 examples

  • exit

    End the shell or script with an exit status (0 = success, 1–255 = error); return does the same for a function.

    Everyday Linux1 options, 10 examples

  • export, unset

    Make a shell variable available to the programs you start (export), or remove a variable (unset).

    RHCSA exam6 options, 11 examples

  • history

    Show, search, repeat and clear the commands you typed before.

    RHCSA exam22 options, 12 examples

  • info

    Read the longer GNU documentation (Texinfo manuals) with chapters and links.

    RHCSA exam13 options, 11 examples

  • man

    Read the manual page of a command, a configuration file or a system call.

    RHCSA exam39 options, 12 examples

  • mandb

    Build or update the search database of the man pages (used by man -k, apropos and whatis).

    RHCSA exam Yes12 options, 11 examples

  • printenv

    Print the value of environment variables (all, or the ones you name).

    Everyday Linux4 options, 11 examples

  • printf

    Print formatted text: columns, numbers, padding — more exact than echo.

    Everyday Linux2 options, 10 examples

  • read

    Read one line of input (from the keyboard, a file or a pipe) into variables.

    RHCSA exam11 options, 10 examples

  • seq

    Print a list of numbers — for loops and test data.

    Everyday Linux5 options, 10 examples

  • set

    Turn shell options on or off (like -x trace, -e stop on error), set the positional parameters, or list all variables.

    Everyday Linux23 options, 10 examples

  • sleep

    Wait for a given time.

    Everyday Linux3 options, 10 examples

  • source

    Run the commands of a file in the current shell, so its variables, aliases and functions stay.

    RHCSA exam2 options, 10 examples

  • test

    Check a condition (file exists, strings equal, number greater …) and return 0 (true) or 1 (false). Also written as [ … ].

    RHCSA exam0 options, 11 examples

  • tty

    Print the name of the terminal device you are using (like /dev/tty3 or /dev/pts/0).

    Everyday Linux3 options, 11 examples

  • type

    Show what a command name really is: an alias, a shell keyword, a function, a built-in or a program file.

    RHCSA exam5 options, 11 examples

  • which

    Show the full path of the program that runs for a command name.

    Everyday Linux12 options, 11 examples

Files and folders

  • cd

    Change the current folder of your shell.

    RHCSA exam6 options, 11 examples

  • cp

    Copy files and folders.

    RHCSA exam35 options, 12 examples

  • file

    Find out what kind of data a file contains (text, script, program, image, archive …), whatever its name.

    Everyday Linux30 options, 11 examples

  • find

    Search a folder tree for files that match tests (name, owner, size, time, permissions …) and act on them.

    RHCSA exam68 options, 17 examples

  • ln

    Make links: hard links (a second name for the same data) or symbolic links (a pointer to a path).

    RHCSA exam16 options, 11 examples

  • ls

    List the files in a folder, with details like permissions, owner, size and time.

    RHCSA exam60 options, 13 examples

  • mkdir

    Create new folders (directories), also with all missing parent folders.

    RHCSA exam7 options, 11 examples

  • mv

    Move files and folders, or rename them.

    RHCSA exam17 options, 11 examples

  • pwd

    Print the full path of the folder you are in (print working directory).

    Everyday Linux4 options, 11 examples

  • rm

    Delete files, and with -r folders with all their content.

    RHCSA exam12 options, 11 examples

  • rmdir

    Remove empty folders (and refuse to remove folders that still have files).

    RHCSA exam5 options, 11 examples

  • stat

    Show all details of a file: size, blocks, inode, links, permissions, owner, SELinux context and all its times.

    Everyday Linux26 options, 11 examples

  • touch

    Create an empty file, or change the access and modification times of a file.

    RHCSA exam11 options, 11 examples

Text and search

  • awk

    Process text line by line as fields: print columns, filter by conditions, count and sum.

    RHCSA exam28 options, 13 examples

  • cat, tac

    Print files to the screen, join files together (cat), or print them last line first (tac).

    RHCSA exam15 options, 12 examples

  • cut

    Take parts of each line: fields split by a separator, or character positions.

    RHCSA exam15 options, 11 examples

  • grep

    Search files or command output for lines that match a pattern (text or regular expression).

    RHCSA exam48 options, 14 examples

  • head

    Show the first lines (or bytes) of files or command output.

    RHCSA exam8 options, 11 examples

  • less

    Read a file or command output one screen at a time, with scrolling and searching.

    RHCSA exam40 options, 12 examples

  • more

    Show text one screen at a time (the simple, older pager).

    Everyday Linux14 options, 11 examples

  • nano

    Edit text files with a simple terminal editor that shows its keys on the screen.

    RHCSA exam56 options, 11 examples

  • sed

    Change text as it flows through: replace words, delete or print lines — and edit files in place with -i.

    RHCSA exam35 options, 13 examples

  • sort

    Put lines in order: alphabetical, by numbers, by sizes, by versions, by a chosen column.

    RHCSA exam31 options, 12 examples

  • tail

    Show the last lines of files, and follow a log file live while it grows.

    RHCSA exam13 options, 11 examples

  • tee

    Copy the input to the screen (or the next command) and to one or more files at the same time.

    Everyday Linux6 options, 11 examples

  • tr

    Replace, delete or squeeze single characters in a text stream.

    Everyday Linux12 options, 11 examples

  • uniq

    Remove or count repeated lines that are next to each other (use it after sort).

    Everyday Linux13 options, 11 examples

  • vim

    Edit text files in the terminal with the vi/vim editor (keys and commands, no mouse needed).

    RHCSA exam28 options, 12 examples

  • wc

    Count lines, words, characters and bytes.

    RHCSA exam9 options, 11 examples

Archive and compress

  • bzip2, bunzip2, bzcat

    Compress files to .bz2 (bzip2), unpack them (bunzip2), or read them without unpacking (bzcat).

    RHCSA exam14 options, 12 examples

  • gzip, gunzip, zcat

    Compress files to .gz (gzip), unpack them (gunzip), or read them without unpacking (zcat).

    RHCSA exam19 options, 12 examples

  • tar

    Pack files and folders into one archive file (and unpack it), with optional compression.

    RHCSA exam128 options, 13 examples

  • xz, unxz, xzcat

    Compress files to .xz with very good compression (xz), unpack them (unxz), or read them (xzcat).

    Everyday Linux21 options, 11 examples

  • zip, unzip

    Pack files into a .zip archive (zip) and unpack it (unzip) — the format that Windows and macOS open directly.

    Everyday Linux50 options, 12 examples

Users and groups

  • chage

    Show and change the password aging and the expire date of an account.

    RHCSA exam For changes11 options, 12 examples

  • getent

    Look up entries in the system databases (users, groups, hosts, services …) the same way programs do.

    RHCSA exam6 options, 12 examples

  • gpasswd

    Add or remove members of a group, set group admins, or set a group password.

    RHCSA exam For changes8 options, 10 examples

  • groupadd

    Create a group (groupadd), change it (groupmod) or delete it (groupdel).

    RHCSA exam Yes17 options, 11 examples

  • groups

    Show the names of the groups a user is in.

    Everyday Linux3 options, 10 examples

  • id

    Show the UID, primary group and all groups of a user (or of yourself).

    RHCSA exam10 options, 11 examples

  • logname

    Print the name of the user who logged in to this session (also after su or sudo).

    Extra2 options, 10 examples

  • newgrp

    Start a new shell with another primary group — useful right after you were added to a group.

    Everyday Linux2 options, 10 examples

  • passwd

    Set or change a password, and lock, unlock, expire or show the password of an account.

    RHCSA exam For changes17 options, 12 examples

  • pkexec

    Run a program as another user (by default root) when polkit allows it.

    Extra For changes5 options, 10 examples

  • su

    Start a shell (or one command) as another user. You type the password of that user.

    RHCSA exam For changes12 options, 11 examples

  • sudo

    Run a command as root (or another user) with your own password, if the sudo rules allow it.

    RHCSA exam For changes31 options, 12 examples

  • useradd

    Create a new user account (and by default its private group and home folder).

    RHCSA exam Yes26 options, 11 examples

  • userdel

    Delete a user account, and with -r also its home folder and mail.

    RHCSA exam Yes6 options, 11 examples

  • usermod

    Change an existing user: groups, shell, home folder, name, UID, expire date, lock.

    RHCSA exam Yes25 options, 12 examples

  • vipw

    Edit /etc/passwd (vipw) or /etc/group (vigr) safely by hand, with a lock.

    Everyday Linux Yes6 options, 11 examples

  • visudo

    Edit the sudo rules safely: visudo locks the file and checks the syntax before it saves.

    RHCSA exam Yes9 options, 11 examples

  • w

    Show who is logged in and what each user is doing now, plus the uptime and load of the system.

    Everyday Linux10 options, 11 examples

  • who

    Show who is logged in now, on which terminal, since when and from where.

    Everyday Linux16 options, 11 examples

  • whoami

    Print the user name you are working as right now (the effective user).

    Everyday Linux2 options, 11 examples

Permissions

  • chattr

    Set or remove file attributes, like immutable (no change at all) and append only.

    Everyday Linux Yes5 options, 10 examples

  • chgrp

    Change the group of files and directories.

    RHCSA exam For changes14 options, 10 examples

  • chmod

    Change the permissions (mode) of files and directories, with numbers or letters.

    RHCSA exam For changes9 options, 12 examples

  • chown

    Change the owner and/or the group of files and directories.

    RHCSA exam Yes15 options, 11 examples

  • getfacl

    Show the access control lists (ACLs) of files and directories.

    Everyday Linux14 options, 10 examples

  • lsattr

    List the file attributes (like i = immutable, a = append only).

    Everyday Linux For changes7 options, 10 examples

  • namei

    Follow a path step by step and show every directory and link on the way, with owner and permissions.

    Everyday Linux9 options, 10 examples

  • setfacl

    Add, change or remove ACL entries: rights for extra users and groups on files and directories.

    Everyday Linux For changes18 options, 11 examples

  • umask

    Show or set the mask that decides the permissions of new files and directories.

    RHCSA exam3 options, 11 examples

Processes and jobs

  • free

    Show the use of memory (RAM) and swap.

    Everyday Linux17 options, 10 examples

  • jobs

    List the jobs of your shell, and move them between foreground (fg) and background (bg).

    RHCSA exam8 options, 10 examples

  • kill

    Send a signal to processes by PID (or job number) — by default SIGTERM, a polite request to stop.

    RHCSA exam For changes8 options, 11 examples

  • killall

    Send a signal to all processes with a given name.

    Everyday Linux For changes16 options, 10 examples

  • nice

    Start a command with a changed CPU priority (nice value from -20 to 19).

    RHCSA exam For changes3 options, 10 examples

  • nohup

    Run a command that keeps running after you log out (it ignores the hang-up signal).

    Everyday Linux2 options, 10 examples

  • pidof

    Print the PIDs of a running program, by its exact name.

    Everyday Linux13 options, 10 examples

  • pkill

    Find processes by name or other attributes (pgrep), signal them (pkill), or wait for them to end (pidwait).

    RHCSA exam For changes32 options, 11 examples

  • ps

    Show a snapshot of running processes: PID, user, CPU and memory use, state and command.

    RHCSA exam51 options, 12 examples

  • pstree

    Show the running processes as a tree: who started whom.

    Everyday Linux20 options, 10 examples

  • renice

    Change the nice value (CPU priority) of running processes, by PID, process group or user.

    RHCSA exam For changes7 options, 10 examples

  • systemd-cgls

    Show the control groups (cgroups) as a tree with their processes (systemd-cgls), or their live resource use (systemd-cgtop).

    Everyday Linux26 options, 10 examples

  • top

    Watch the processes live, sorted by CPU, with load, CPU and memory totals — and kill or renice from it.

    RHCSA exam19 options, 10 examples

  • tuned-adm

    Choose and check the tuned performance profile (a set of kernel, CPU, disk and power settings).

    RHCSA exam For changes7 options, 10 examples

  • uptime

    Show how long the system runs, how many users are logged in and the load average.

    Everyday Linux4 options, 10 examples

Services and boot

  • shutdown, reboot, poweroff, halt

    Stop, restart or switch off the system cleanly — now or at a planned time, with a warning to users.

    RHCSA exam Yes19 options, 11 examples

  • systemctl

    Control systemd: start, stop, enable and check services and other units, change targets, reboot and power off.

    RHCSA exam For changes57 options, 15 examples

  • systemd-analyze

    Analyze systemd: boot time, slow units, unit file errors, timer expressions and the security of services.

    Everyday Linux27 options, 10 examples

Scheduling

  • at

    Run commands once at a later time (at), list (atq) or remove (atrm) those jobs, or run them when the load is low (batch).

    RHCSA exam14 options, 11 examples

  • crontab

    Edit, list or remove the cron job list (crontab) of a user.

    RHCSA exam For changes11 options, 12 examples

  • systemd-run

    Run a command as a temporary (transient) systemd service or scope — now, later with a timer, or with resource limits.

    Everyday Linux For changes35 options, 10 examples

Logs

  • journalctl

    Read and search the systemd journal: by service, time, priority, boot, user and any field.

    RHCSA exam For changes53 options, 15 examples

  • logger

    Write a message to the system log (journal and rsyslog) — from the command line or a script.

    RHCSA exam24 options, 10 examples

  • logrotate

    Rotate, compress and delete old log files by the rules in /etc/logrotate.conf and /etc/logrotate.d/.

    RHCSA exam Yes11 options, 10 examples

Software packages

  • createrepo

    Create the index (repodata) for a folder of RPM files, so dnf can use it as a repository.

    Everyday Linux For changes21 options, 10 examples

  • dnf

    Install, update, remove and search RPM packages from repositories, with all dependencies.

    RHCSA exam For changes50 options, 15 examples

  • flatpak

    Install, update and run (mostly graphical) applications in a sandbox, from Flatpak remotes like Flathub.

    RHCSA exam For changes19 options, 11 examples

  • rpm

    Query, verify, install and remove RPM packages directly — mostly used to ask what is installed and which files a package has.

    RHCSA exam For changes62 options, 13 examples

  • subscription-manager

    Register a RHEL system with Red Hat, and turn Red Hat repositories on or off.

    RHCSA exam Yes23 options, 12 examples

Disks and file systems

  • automount

    The autofs daemon: mounts file systems (mostly NFS) when they are used and unmounts them when idle. Managed with systemctl; the command helps debugging.

    RHCSA exam Yes18 options, 10 examples

  • blkid

    Show the UUID, label and type of file systems and swap spaces — the values you need for /etc/fstab.

    RHCSA exam For changes20 options, 10 examples

  • dd

    Copy data block by block: make disk images, write ISO files to USB, create files of a fixed size, wipe or test disks.

    Everyday Linux For changes15 options, 11 examples

  • df

    Show how much space is used and free on each mounted file system.

    RHCSA exam18 options, 11 examples

  • du

    Show how much disk space files and folders use.

    Everyday Linux27 options, 12 examples

  • dumpe2fs

    Show the superblock and block group details of an ext2/ext3/ext4 file system.

    Everyday Linux Yes10 options, 10 examples

  • exportfs

    Manage the NFS export table: apply changes of /etc/exports, show the active exports, or export a folder for a moment.

    RHCSA exam Yes9 options, 10 examples

  • fallocate

    Reserve disk space for a file at once (no data is written), or punch holes into a file.

    Everyday Linux12 options, 10 examples

  • fdisk

    Create, delete and change partitions on MBR and GPT disks with a menu.

    RHCSA exam Yes17 options, 10 examples

  • findmnt

    Show mounted file systems as a tree, find one mount, or check /etc/fstab for errors.

    RHCSA exam43 options, 11 examples

  • fsck

    Check and repair file systems — the front end fsck, and e2fsck (= fsck.ext4) for ext2/3/4.

    RHCSA exam Yes31 options, 10 examples

  • gdisk

    Edit GPT partition tables with a menu (like fdisk, made for GPT).

    Extra Yes1 options, 10 examples

  • lsblk

    List disks, partitions, LVM volumes and other block devices as a tree, with size, type and mount point.

    RHCSA exam33 options, 11 examples

  • mkfs

    Create a file system on a partition or volume (front end for mkfs.xfs, mkfs.ext4, mkfs.vfat …).

    RHCSA exam Yes5 options, 10 examples

  • mkfs.ext4

    Create an ext4 (or ext3/ext2) file system.

    RHCSA exam Yes30 options, 10 examples

  • mkfs.vfat

    Create a FAT file system (FAT12/16/32) — for USB sticks, SD cards and the EFI system partition.

    Everyday Linux Yes27 options, 10 examples

  • mkfs.xfs

    Create an XFS file system — the default file system of RHEL.

    RHCSA exam Yes16 options, 10 examples

  • mkswap

    Prepare a partition, logical volume or file to be used as swap space.

    RHCSA exam Yes14 options, 10 examples

  • mount

    Attach a file system (disk, partition, ISO, network share) to a folder, or show what is mounted.

    RHCSA exam For changes29 options, 12 examples

  • parted

    Create, delete, resize and list partitions — in a menu or with one command line (good for scripts).

    RHCSA exam Yes8 options, 10 examples

  • partprobe

    Tell the kernel to read the partition table of a disk again.

    RHCSA exam Yes5 options, 10 examples

  • resize2fs

    Grow or shrink an ext2/ext3/ext4 file system.

    RHCSA exam Yes10 options, 10 examples

  • showmount

    Show the exports of an NFS server (and which clients mounted them).

    RHCSA exam6 options, 10 examples

  • swapon

    Switch swap spaces on (swapon) or off (swapoff), and show which are active.

    RHCSA exam For changes18 options, 10 examples

  • tune2fs

    Show and change the settings of an ext2/ext3/ext4 file system (label, reserved blocks, default mount options, checks, UUID).

    RHCSA exam Yes21 options, 10 examples

  • umount

    Detach a mounted file system from the folder tree.

    RHCSA exam For changes18 options, 10 examples

  • wipefs

    List or remove file system, RAID, LVM and partition table signatures from a device (fast, without wiping the data).

    Everyday Linux Yes14 options, 10 examples

  • xfs_admin

    Show or change the label, UUID and some features of an XFS file system (unmounted).

    RHCSA exam Yes12 options, 10 examples

  • xfs_growfs

    Grow a mounted XFS file system to fill its (bigger) device.

    RHCSA exam Yes11 options, 10 examples

  • xfs_info

    Show the geometry and features of an XFS file system (block size, allocation groups, log, features).

    Everyday Linux For changes3 options, 10 examples

  • xfs_repair

    Check and repair a damaged XFS file system (it must be unmounted).

    RHCSA exam Yes14 options, 10 examples

LVM

  • lvcreate

    Create a logical volume from the free space of a volume group (lvcreate), or delete one (lvremove).

    RHCSA exam Yes46 options, 10 examples

  • lvextend

    Make a logical volume bigger — with -r also its file system, while it stays mounted.

    RHCSA exam Yes28 options, 10 examples

  • lvreduce

    Make a logical volume smaller — with -r the file system is shrunk first (ext4 only; XFS cannot shrink).

    RHCSA exam Yes21 options, 10 examples

  • lvs

    Show logical volumes: short table (lvs), full details (lvdisplay), or list all (lvscan).

    RHCSA exam Yes28 options, 10 examples

  • pvcreate

    Turn a disk or partition into an LVM physical volume (pvcreate), or remove the LVM label again (pvremove).

    RHCSA exam Yes27 options, 10 examples

  • pvmove

    Move the data of a physical volume to other PVs in the same VG — while the LVs stay in use.

    Everyday Linux Yes20 options, 10 examples

  • pvs

    Show physical volumes: short table (pvs), full details (pvdisplay), or scan for PVs (pvscan).

    RHCSA exam Yes34 options, 10 examples

  • vgcreate

    Create a volume group from one or more physical volumes (vgcreate), or delete a volume group (vgremove).

    RHCSA exam Yes28 options, 10 examples

  • vgextend

    Add physical volumes to a volume group (vgextend), or remove them (vgreduce).

    RHCSA exam Yes20 options, 10 examples

  • vgs

    Show volume groups: short table (vgs), full details (vgdisplay), or scan for VGs (vgscan).

    RHCSA exam Yes28 options, 10 examples

Network

  • dig

    Ask DNS servers for records (A, AAAA, MX, TXT, NS …) and show the full answer — the main DNS test tool.

    Everyday Linux42 options, 12 examples

  • host

    Simple DNS lookups with short, readable output.

    Everyday Linux20 options, 10 examples

  • hostname

    Show the host name (and its FQDN, domain or IP addresses), or set it until the next reboot.

    RHCSA exam For changes12 options, 10 examples

  • ip

    Show and change network cards, addresses, routes and neighbours (the live kernel settings).

    RHCSA exam For changes34 options, 15 examples

  • nmcli

    Set up, change and check network connections with NetworkManager.

    RHCSA exam For changes45 options, 16 examples

  • nmtui

    A menu in the terminal to edit NetworkManager connections, activate them and set the host name.

    RHCSA exam Yes2 options, 10 examples

  • nslookup

    Ask a DNS server for the address of a name, or for other DNS records (mail, text, name servers).

    Everyday Linux20 options, 14 examples

  • ping

    Send ICMP echo requests to a host to test if it is reachable and how fast it answers.

    RHCSA exam38 options, 11 examples

  • ss

    Show network sockets: which ports are listening, which connections are open, and which process owns them.

    RHCSA exam For changes39 options, 11 examples

  • tracepath

    Show the routers (hops) on the way to a host and the MTU of the path. Needs no root.

    Everyday Linux8 options, 10 examples

SSH and remote work

  • rsync

    Copy and synchronize files and folders (locally or over SSH), sending only what changed.

    RHCSA exam102 options, 14 examples

  • scp

    Copy files between systems over SSH (secure copy).

    RHCSA exam22 options, 12 examples

  • sftp

    Transfer files interactively over SSH, like a secure FTP client.

    RHCSA exam24 options, 11 examples

  • ssh

    Log in to another system over an encrypted connection, run remote commands, and make secure tunnels.

    RHCSA exam43 options, 14 examples

  • ssh-agent, ssh-add

    Keep unlocked SSH keys in memory (ssh-agent) and load or remove keys there (ssh-add), so you type a passphrase only once.

    RHCSA exam30 options, 12 examples

  • ssh-copy-id

    Install your public SSH key on a server, so you can log in with the key instead of a password.

    RHCSA exam9 options, 11 examples

  • ssh-keygen

    Create SSH key pairs, change their passphrase, show fingerprints and clean the known_hosts file.

    RHCSA exam42 options, 12 examples

  • sshd

    The OpenSSH server. Mostly used through systemctl; the command itself tests the configuration (-t, -T) and helps debugging.

    RHCSA exam Yes19 options, 10 examples

SELinux and security

  • audit2allow

    Explain SELinux denials (audit2why) or build a policy module that allows them (audit2allow) — the last resort.

    Extra Yes17 options, 10 examples

  • ausearch

    Search the audit log (/var/log/audit/audit.log): SELinux denials, logins, commands and other kernel audit events.

    RHCSA exam Yes38 options, 10 examples

  • chcon

    Change the SELinux context of files directly — only for a quick test, because restorecon or a relabel undoes it.

    RHCSA exam Yes13 options, 10 examples

  • getenforce

    Show the SELinux mode (getenforce), or switch between enforcing and permissive until the next reboot (setenforce).

    RHCSA exam For changes2 options, 10 examples

  • getsebool

    Show SELinux booleans (getsebool) or switch them on and off (setsebool; with -P permanently).

    RHCSA exam For changes4 options, 10 examples

  • restorecon

    Set the SELinux labels of files back to what the policy (and your semanage fcontext rules) say.

    RHCSA exam Yes17 options, 10 examples

  • sealert

    Explain SELinux denials in plain text, with the likely cause and the commands that fix it.

    Everyday Linux Yes9 options, 10 examples

  • semanage

    Change the SELinux policy settings that admins need: file context rules, port types, booleans, permissive domains, user mappings.

    RHCSA exam Yes18 options, 11 examples

  • sestatus

    Show the full SELinux status: on or off, current and config mode, policy name and version.

    RHCSA exam2 options, 10 examples

Firewall

  • firewall-cmd

    Configure firewalld: zones, services, ports, sources, rich rules, forwarding — at run time or permanently.

    RHCSA exam For changes43 options, 12 examples

  • nft

    Show and manage nftables rules: tables, chains, rules and sets — the kernel firewall below firewalld.

    Extra Yes18 options, 10 examples

Kernel and hardware

  • dmesg

    Show the kernel messages (the kernel ring buffer): hardware found, drivers loaded, disk and memory errors.

    RHCSA exam For changes30 options, 11 examples

  • dracut

    Create (or rebuild) the initramfs: the small root file system in RAM that finds and mounts the real root at boot.

    RHCSA exam Yes38 options, 10 examples

  • grub2-install

    Install the GRUB 2 boot loader to a disk (BIOS systems) — used to repair a system that does not find its boot loader.

    Everyday Linux Yes20 options, 10 examples

  • grub2-mkconfig

    Generate the GRUB 2 configuration file from /etc/default/grub and the scripts in /etc/grub.d/.

    RHCSA exam Yes4 options, 10 examples

  • grubby

    Show and change the boot entries of GRUB 2: kernel arguments, the default kernel, and entry details.

    RHCSA exam Yes25 options, 10 examples

  • insmod

    Load one module file into the kernel (insmod) or remove a loaded module (rmmod) — without dependency handling.

    Everyday Linux Yes7 options, 10 examples

  • lsinitrd

    Show the content of an initramfs image: dracut modules, files, kernel modules, and the content of single files.

    Everyday Linux For changes8 options, 10 examples

  • lsmod

    List the kernel modules that are loaded now.

    RHCSA exam0 options, 10 examples

  • lspci

    List the PCI devices (network cards, disk controllers, GPUs …) and the drivers that handle them.

    Everyday Linux For changes22 options, 10 examples

  • lsusb

    List USB buses and the USB devices connected to them.

    Everyday Linux For changes7 options, 10 examples

  • modinfo

    Show information about a kernel module: file, description, license, dependencies, aliases and parameters.

    RHCSA exam11 options, 10 examples

  • modprobe

    Load or unload kernel modules, with their dependencies and the settings from /etc/modprobe.d/.

    RHCSA exam Yes20 options, 10 examples

  • sysctl

    Read and change kernel parameters at run time (the files under /proc/sys), and load them from config files.

    RHCSA exam For changes14 options, 10 examples

  • udevadm

    Control and query udev, the service that creates device files and runs rules when hardware appears.

    Everyday Linux For changes38 options, 10 examples

Time

  • chronyc

    Talk to the chrony NTP daemon: show time sources, sync state and statistics, or make the clock step.

    RHCSA exam For changes13 options, 10 examples

  • date

    Show the date and time in any format, calculate other dates, or set the system clock.

    RHCSA exam For changes12 options, 11 examples

  • hwclock

    Read or set the hardware clock (RTC), and copy the time between the hardware clock and the system clock.

    RHCSA exam Yes22 options, 10 examples

  • timedatectl

    Show and change the system time, the time zone, the RTC mode and whether NTP sync is on.

    RHCSA exam For changes11 options, 10 examples

  • tzselect

    Find the name of a time zone by answering questions (it does not change the system).

    Everyday Linux4 options, 10 examples

Web

  • apachectl

    Control and test the Apache web server: check the config syntax, list virtual hosts and modules. (Start and stop with systemctl.)

    RHCSA exam Yes16 options, 10 examples

  • curl

    Send requests to URLs (HTTP, HTTPS, FTP …): test web servers, call APIs, download files, check TLS.

    Everyday Linux57 options, 12 examples

System information

  • chroot

    Run a command (default: a shell) with another folder as the root / — the key step to repair an installed system from a rescue shell.

    RHCSA exam Yes6 options, 10 examples

  • hostnamectl

    Show and change the hostname of the system, and see the OS, kernel and hardware facts.

    RHCSA exam For changes10 options, 11 examples

  • lscpu

    Show the CPU: architecture, model, sockets, cores, threads, caches, flags, virtualization and CPU security bugs.

    Everyday Linux15 options, 10 examples

  • nproc

    Print the number of CPUs (cores/threads) that the current process can use.

    Everyday Linux4 options, 10 examples

  • uname

    Show the name and version of the kernel, the machine type and the hostname.

    Everyday Linux11 options, 11 examples