Skip to content

Linux Foundations / Find your way around Linux ยท Step 4 of 63

Lesson: Red Hat Enterprise LinuxSwitch
โ† Linux Foundations

System administration

Red Hat Enterprise Linux

An introduction to RHEL: its subscription model, long life cycle, DNF packages and security defaults.

Red Hat Enterprise Linux (RHEL) is a commercial distribution built for organizations that want predictable releases, long support and someone to call. Much of what you learn on it also applies to compatible rebuilds.

Where it comes from

New ideas usually appear first in Fedora, a fast-moving community distribution. CentOS Stream is branched from Fedora and shows what the next minor RHEL update is heading towards. RHEL is then released from that work. Community rebuilds such as AlmaLinux and Rocky Linux aim to be compatible with RHEL.

Subscriptions and life cycle

The software is open source, but official updates and support come through a subscription. Red Hat offers a no-cost Developer Subscription for individuals; read its current terms. A system is commonly registered like this:

$ sudo subscription-manager register

Each major release has a life cycle of about ten years, with optional extensions. Minor releases such as 9.4 arrive along the way, and versions of core software stay broadly stable, with fixes often backported. A package may therefore be patched even though its version number looks old.

Check the release:

$ cat /etc/redhat-release
Red Hat Enterprise Linux release 9.4 (Plow)

Packages with DNF

RHEL uses .rpm packages. dnf fetches them and resolves dependencies (on RHEL 7 the command was yum).

$ sudo dnf install tree
$ sudo dnf upgrade
$ rpm -q bash
bash-5.1.8-9.el9.x86_64

rpm -q asks whether a package is installed and shows its version. Your numbers will differ.

Services and firewall

RHEL uses systemd to manage services:

$ sudo systemctl enable --now sshd
$ systemctl is-active sshd
active

enable makes the service start at boot, and --now also starts it immediately.

The default firewall front end is firewalld, controlled with firewall-cmd.

SELinux

SELinux adds mandatory access control: even if file permissions allow an action, policy can still deny it. It is enforcing by default.

$ getenforce
Enforcing

If something is blocked, read the logs and fix the label or policy. Turning SELinux off removes a layer of protection.

Try it

On a RHEL system, or a compatible rebuild such as AlmaLinux or Rocky Linux, run cat /etc/redhat-release, getenforce and rpm -q bash. Then install tree with dnf. Rebuilds do not need subscription-manager. To practice permissions, which SELinux builds on top of, use the permissions lab.

Check your understanding

Red Hat Enterprise Linux

All 4 sections ยท no timer

Unlimited retries

Questions from every section are combined into one assessment. Answer them all correctly to complete the article.

Your completion saves in this browser. Sign in to sync it to your account.