Chapter 3. Searching for RHEL content


Search and examine content in the Red Hat Enterprise Linux (RHEL) 10 AppStream and BaseOS repositories by using the DNF tool. For example, you can identify specific packages or package groups to ensure you install the exact components required for your environment’s stability and security.

3.1. Searching for software packages

Identify and locate the specific software for your Red Hat Enterprise Linux (RHEL) 10 system by searching for packages with the DNF tool. You can search by name or summary to ensure you find and install the correct components required for your environment.

Procedure

  • Depending on your scenario, use one of the following options to search the repository:

    • To search for a term in the name or summary of packages, enter:

      $ dnf search <term>
    • To search for a term in the name, summary, or description of packages, enter:

      $ dnf search --all <term>

      Note that searching additionally in the description by using the --all option is slower than a normal search operation.

    • To search for a package name and list the package name and its version in the output, enter:

      $ dnf repoquery <package_name>
    • To search for which package provides a file, specify the file name or the path to the file:

      $ dnf provides <file_name>

3.2. Listing software packages

List available or installed packages on your Red Hat Enterprise Linux (RHEL) 10 system by using the DNF tool. You can use this information to confirm current versions and identify ready-to-install content to ensure your environment stays consistent and up-to-date.

Procedure

  • List the latest versions of all available packages, including architectures, version numbers, and the repository they where installed from:

    $ dnf list --all
    ...
    postgresql.x86_64            16.4-1.el10      rhel-AppStream
    postgresql-contrib.x86_64    16.4-1.el10      rhel-AppStream
    postgresql-docs.x86_64       16.4-1.el10      rhel-AppStream
    postgresql-jdbc.noarch       42.7.1-6.el10    rhel-AppStream
    ...

    The @ sign in front of a repository indicates that the package in this line is currently installed.

    Alternatively, to display all available packages, including version numbers and architectures, enter:

    $ dnf repoquery
    ...
    postgresql-0:16.4-1.el10.x86_64
    postgresql-contrib-0:16.4-1.el10.x86_64
    postgresql-docs-0:16.4-1.el10.x86_64
    postgresql-jdbc-0:42.7.1-6.el10.noarch
    postgresql-odbc-0:16.00.0000-4.el10.x86_64
    ...

    Optionally, you can filter the output by using other options instead of --all, for example:

    • Use --installed to list only installed packages.
    • Use --available to list all available packages.
    • Use --upgrades to list packages for which newer versions are available.

3.3. Displaying package information

View detailed metadata for specific software in Red Hat Enterprise Linux (RHEL) 10 by displaying package information with the DNF tool. You can use this information to verify that a package meets your system requirements and security standards before installation.

You can display the following types of information related to the package:

  • Version
  • Release
  • Architecture
  • Package size
  • Description

Procedure

  • Display information about one or more available packages:

    $ dnf info <package_name>

    This command displays the information for the currently installed package and, if available, its newer versions that are in the repository. Alternatively, use the following command to display the information for all packages with the specified name in the repository:

    $ dnf repoquery --info <package_name>

List available package groups and their contents for your Red Hat Enterprise Linux (RHEL) 10 system by using the DNF tool. You can list package groups to quickly verify and install all required tools for specialized environments.

Procedure

  1. List both installed and available groups:

    $ dnf group list

    Note that you can filter the results by appending the --installed and --available option to the dnf group list command. By using the --hidden option, you can display hidden groups in the output.

  2. List mandatory, optional, and default packages contained in a particular group:

    $ dnf group info "<group_name>"
  3. Optional: View the number of installed and available groups:

    $ dnf group summary

3.5. Listing repositories

List enabled and disabled repositories on your Red Hat Enterprise Linux (RHEL) 10 system by using the DNF tool. You can review the repositories to identify available content and troubleshoot repository availability to ensure your environment can access the necessary software updates.

Procedure

  1. List all enabled repositories on your system:

    $ dnf repolist

    To display only certain repositories, append one of the following options to the command:

    • Append --disabled to list only disabled repositories.
    • Append --all to list both enabled and disabled repositories.
  2. Optional: List additional information about the repositories:

    $ dnf repoinfo <repository_name>

3.6. Specifying glob expressions in DNF input

Write more expressive DNF commands on your Red Hat Enterprise Linux (RHEL) 10 system by appending one or more glob expressions as arguments.

Many DNF commands accept glob expressions in place of package names, file paths, and other parameters. Glob expressions are strings of characters that contain one or more of the wildcard characters. By using glob expressions, you can efficiently search for large groups of related software and match paths without requiring exact matches for every item.

Procedure

  • Use one of the following methods if you use global expressions in dnf commands:

    • Enclose the entire global expression in single or double quotation marks:

      # dnf provides "*/<file_name>"

      Note that you must precede <file_name> either by / for an absolute path or */ to use a wildcard if the full path is unknown.

    • Escape the wildcard characters by preceding them with a backslash (\) character:

      # dnf provides \*/<file_name>
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

© 2026 Red Hat
Back to top