Chapter 12. YUM commands list


In the following sections, examine YUM commands for listing, installing, and removing content in Red Hat Enterprise Linux 8.

12.1. Commands for listing content in RHEL 8

The following are the commonly used YUM commands for finding content and its details in Red Hat Enterprise Linux 8:

CommandDescription

yum search term

Search for a package by using term related to the package.

yum repoquery package

Search for enabled YUM repositories for a selected package and its version.

yum list

List information about all installed and available packages.

yum list --installed

yum repoquery --installed

List all packages installed on your system.

yum list --available

yum repoquery

List all packages in all enabled repositories that are available to install.

yum repolist

List all enabled repositories on your system.

yum repolist --disabled

List all disabled repositories on your system.

yum repolist --all

List both enabled and disabled repositories.

yum repoinfo

List additional information about the repositories.

yum info package_name

yum repoquery --info package_name

Display details of an available package.

yum repoquery --info --installed package_name

Display details of a package installed on your system.

yum module list

List modules and their current status.

yum module info module_name

Display details of a module.

yum module list module_name

Display the current status of a module.

yum module info --profile module_name

Display packages associated with available profiles of a selected module.

yum module info --profile module_name:stream

Display packages associated with available profiles of a module by using a specified stream.

yum module provides package

Determine which modules, streams, and profiles provide a package.

Note that if the package is available outside any modules, the output of this command is empty.

yum group summary

View the number of installed and available groups.

yum group list

List all installed and available groups.

yum group info group_name

List mandatory and optional packages included in a particular group.

12.2. Commands for installing content in RHEL 8

The following are the commonly used YUM commands for installing content in Red Hat Enterprise Linux 8:

CommandDescription

yum install package_name

Install a package.

If the package is provided by a module stream, yum resolves the required module stream and enables it automatically while installing this package. This also happens recursively for all package dependencies. If more module streams satisfy the requirement, the default ones are used.

yum install package_name_1 package_name_2

Install multiple packages and their dependencies simultaneously.

yum install package_name.arch

Specify the architecture of the package by appending it to the package name when installing packages on a multilib system (AMD64, Intel 64 machine).

yum install /usr/sbin/binary_file

Install a binary by using the path to the binary as an argument.

yum install /path/

Install a previously downloaded package from a local directory.

yum install package_url

Install a remote package by using a package URL.

yum module enable module_name:stream

Enable a module by using a specific stream.

Note that running this command does not install any RPM packages.

yum module install module_name:stream

yum install @module_name:stream

Install a default profile from a specific module stream.

Note that running this command also enables the specified stream.

yum module install module_name:stream/profile

yum install @module_name:stream/profile

Install a selected profile by using a specific stream.

yum group install group_name

Install a package group by a group name.

yum group install group_ID

Install a package group by the groupID.

yum install-n <package_name>

Install a package by using its exact name.

yum install-na <package_name>.<architecture>

Install a package by using its exact name and architecture.

yum install-nevra <package_name>-<epoch>:<version>-<release>.<architecture>

Install a package by using its exact name, epoch, version, release, and architecture.

12.3. Commands for removing content in RHEL 8

The following are the commonly used YUM commands for removing content in Red Hat Enterprise Linux 8:

CommandDescription

yum remove package_name

Remove a particular package and all dependent packages.

yum remove package_name_1 package_name_2

Remove multiple packages and their unused dependencies simultaneously.

yum group remove group_name

Remove a package group by the group name.

yum group remove group_ID

Remove a package group by the groupID.

yum module remove --all module_name:stream

Remove all packages from the specified stream.

Note that running this command can remove critical packages from your system.

yum module remove module_name:stream/profile

Remove packages from an installed profile.

yum module remove module_name:stream

Remove packages from all installed profiles within the specified stream.

yum module reset module_name

Reset a module to the initial state.

Note that running this command does not remove packages from the specified module.

yum module disable module_name

Disable a module and all its streams.

Note that running this command does not remove packages from the specified module.

yum remove-n <package_name>

Remove a package by using its exact name.

yum remove-na <package_name>.<architecture>

Remove a package by using its exact name and architecture.

yum remove-nevra <package_name>-<epoch>:<version>-<release>.<architecture>

Remove a package by using its exact name, epoch, version, release, and architecture.

Back to top
Red Hat logoGithubredditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust. Explore our recent updates.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

Theme

© 2025 Red Hat, Inc.