1.5.4 Removing Installed Modules

Before removing an installed module, carefully review the information in Section 1.5.3, “About Modular Dependencies and Stream Changes”.

When you remove an installed module, all of the packages that are installed by the profiles of the currently enabled module stream, and any further packages and modules that depend on them, are also removed. Note that any packages installed from this module stream that are not listed in any of its profiles remain installed on the system and can be removed manually.

Note

A prerequisite to removing installed modules requires that the module to be removed already has some profiles installed.

To remove an installed module, follow these steps:

  1. Remove the module.

    # dnf module remove module-name

    where module-name specifies the name of the module to remove.

    The dnf module remove command removes all of the packages that are installed from this module. You are presented with a summary of the changes to be made and a request for confirmation.

  2. Disable the module stream.

    # dnf module disable module-name

    where module-name is the name of the module to disable.

    You are presented with a summary of the changes to be made and a request for confirmation.

  3. Remove any packages that you manually installed from the module stream.

    # dnf remove package ...

    where package ... is the name of the package, or packages, to be removed.

    You are presented with a summary of the changes to be made and a request for confirmation.