Advanced Package Management DIY Labs
- Configure Access to RHEL 8 Repositories (Make sure the RHEL 8 ISO image is attached to the VM and mounted.) Create a definition file under /etc/yum.repos.d/, and define two blocks (one for BaseOS and another for AppStream).
vim /etc/yum.repos.d/local.repo
[BaseOS]
name=BaseOS
baseurl=file:///mnt/BaseOS
gpgcheck=0
[AppStrean]
name=AppStream
baseurl=file:///mnt/AppStream
gpgcheck=0
- Verify the configuration with dnf repolist. You should see numbers in thousands under the Status column for both repositories.
Lab: Install and Manage Individual Packages
- List all installed and available packages separately.
dnf list --available && dnf list --installed
- Show which package contains the /etc/group file.
- Install the package httpd.
- Review /var/log/yum.log/ for confirmation. (/var/lib/dnf/history)
- Perform the following on the httpd package:
- Show information
- List dependencies
dnf repoquery --requires httpd
- Remove it
Lab Install and Manage Package Groups
- List all installed and available package groups separately.
dnf group list available && dnf group list installed
- Install package groups Security Tools and Scientific Support.
dnf group install 'Security Tools'
- Review /var/log/yum.log for confirmation.
- Show the packages included in the Scientific Support package group, and delete this group.
dnf group info 'Scientific Support' && dnf group remove 'Scientific Support'
Lab: Install and Manage Modules
- List all modules. Identify which modules, streams and profiles are installed, default, disabled, and enabled from the output.
- Install the default stream of the development profile for module php, and verify.
dnf module install php && dnf module list
- Remove the module.
Lab Switch Module Streams and Install Software
- List postgresql module. This will display the streams and profiles, and their status.
dnf module list postgresql
- Reset both streams
dnf module reset postgresql
- enable the stream for the older version, and install its client profile.
dnf module install postgresql:15