CentOS/RHEL 8 distributes sets of related RPM packages that form a logical unit (such as different components of an application or a group of tools) as modules, with these modules being able to be enabled or disabled on the system. How can a user or administrator of an OL8 system determine what modules are installed or are enabled or disabled on their system?
Modules
a set of RPM packages that are grouped together and must be installed together. They can contain several streams (AppStreams) that consist of multiple versions of applications that you can install. You enable a module stream to provide system access to the RPM packages that are contained in that module stream.
A typical module can contain the following types of packages:
- Packages with an application.
- Packages with the application’s specific dependency libraries.
- Packages with documentation for the application.
- Packages with helper utilities.
You can use the following commands to display all, installed, enabled, or disabled, modules on a system.
1. To display a list of all modules, do:
# dnf module list This system is receiving updates from Spacewalk server. Last metadata expiration check: 0:15:46 ago on Fri 26 Jul 2019 03:12:16 AM EDT. Oracle Linux 8 Application Stream Packages (x86_64) Name Stream Profiles Summary 389-ds 1.4 [e] 389 Directory Server (base) ant 1.10 [d] common [d] Java build tool container-tools 1.0 common [d] Common tools and dependencies for container runtimes container-tools ol8 [d] common [d] Common tools and dependencies for container runtimes freeradius 3.0 [d] server [d] High-performance and highly configurable free RADIUS server gimp 2.8 [d] common [d], devel gimp module go-toolset ol8 [d] common [d] Go httpd 2.4 [d] common [d], devel, minimal Apache HTTP Server
2. To check the enabled modules on a system, do:
# dnf module list --enabled This system is receiving updates from Spacewalk server. Last metadata expiration check: 0:19:38 ago on Fri 26 Jul 2019 03:12:16 AM EDT. Oracle Linux 8 Application Stream Packages (x86_64) Name Stream Profiles Summary 389-ds 1.4 [e] 389 Directory Server (base) satellite-5-client 1.0 [d][e] common [d],gui ULN client packages Hint: [d]efault, [e]nabled, [x]disabled, [i]nstalled
3. To check the disabled modules on system, do:
# dnf module list --disabled This system is receiving updates from Spacewalk server. Last metadata expiration check: 0:19:55 ago on Fri 26 Jul 2019 03:12:16 AM EDT. No matching Modules to list
4. To show the installed modules on a system, do:
# dnf module list --installed This system is receiving updates from Spacewalk server. Last metadata expiration check: 0:21:12 ago on Fri 26 Jul 2019 03:12:16 AM EDT. No matching Modules to list