7. Deploy, Configure, and Maintain Systems
πRed Hat Certified System Administrator (RHCSA β EX200)
Software packages are the building blocks of Linux systems. They include applications, utilities, and tools that make your system functional. In RHEL, packages are usually managed in the RPM format (Red Hat Package Manager).
There are three main ways to install or update software on RHEL:
- From the Red Hat Content Delivery Network (CDN)
- From a remote repository
- From the local file system
We will go through each method step by step.
1. Using Red Hat Content Delivery Network (CDN)
The Red Hat CDN is the official source for RHEL software updates and packages. You need a valid Red Hat subscription to access it.
Steps to use CDN
- Register your system with Red Hat Command: sudo subscription-manager register You will need your Red Hat username and password.
- Attach your subscription sudo subscription-manager attach –auto This attaches the system to an available subscription automatically.
- Enable repositories List available repositories: sudo subscription-manager repos –list Enable a repository (for example, RHEL 9 BaseOS): sudo subscription-manager repos –enable=rhel-9-for-x86_64-baseos-rpms
- Install packages from CDN Use
dnf(the default package manager in RHEL 8 and above) oryum(RHEL 7). Example: sudo dnf install vim This will download and install the latestvimeditor from the CDN repository. - Update packages To update all packages: sudo dnf update
Key points for the exam:
- You must register with Red Hat to access CDN.
subscription-manageris required to manage subscriptions.dnfis the preferred package manager in RHEL 8+.
2. Using a Remote Repository
A remote repository is any server hosting RPM packages. These are not necessarily from Red Hat but can be other trusted sources (like EPEL or third-party repositories).
Steps
- Add the repository Create a
.repofile in/etc/yum.repos.d/. For example: sudo nano /etc/yum.repos.d/epel.repo Add content like: [epel]
name=Extra Packages for Enterprise Linux
baseurl=https://download.fedoraproject.org/pub/epel/9/$basearch
enabled=1
gpgcheck=1
gpgkey=https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-9 - Clean metadata sudo dnf clean all
sudo dnf makecache - Install packages from the remote repository sudo dnf install htop
- Update packages from the repository sudo dnf update htop
Key points for the exam:
- Remote repositories must be configured in
.repofiles. - Use
dnf makecacheto update repository metadata. dnf installanddnf updatework with remote repos just like with CDN.
3. Installing from the Local File System
Sometimes, you have RPM files downloaded locally. This can happen when you donβt have internet access.
Steps
- Install a local RPM sudo dnf install /path/to/package.rpm Example: sudo dnf install ~/Downloads/httpd-2.4.51-1.el9.x86_64.rpm
- Upgrade a local RPM sudo dnf upgrade /path/to/package.rpm
- Check package information rpm -qi httpd
Key points for the exam:
dnf installworks for both remote and local packages.- Always provide the full path to the
.rpmfile if installing locally. - Use
rpm -qato list all installed packages.
Important Commands Summary
| Task | Command |
|---|---|
| Register system | sudo subscription-manager register |
| Attach subscription | sudo subscription-manager attach --auto |
| List repositories | sudo subscription-manager repos --list |
| Enable repository | sudo subscription-manager repos --enable=<repo> |
| Install package from repo/CDN | sudo dnf install <package> |
| Update all packages | sudo dnf update |
| Install local RPM | sudo dnf install /path/to/file.rpm |
| Upgrade local RPM | sudo dnf upgrade /path/to/file.rpm |
| List installed packages | rpm -qa |
| Show package info | rpm -qi <package> |
Exam Tips
- Know how to register your system with Red Hat and attach a subscription.
- Be able to enable or disable repositories.
- Be comfortable with installing and updating packages from:
- CDN (official source)
- Remote repositories (third-party)
- Local RPM files (offline installation)
- Understand the difference between
dnf(recommended) andrpm(low-level, works locally). - Always check your repository and package sources before installing.
β
Summary:
In RHCSA, you need to be able to install and update software packages using all three methods: CDN, remote repositories, and local RPMs. dnf is your main tool, and subscription-manager is required for Red Hat official content. Remember the commands and be comfortable switching between online and offline installation.
