LinuxCommandLibrary

dnf-module

TLDR

View modularity overview

$ dnf module list
copy
View modularity of specific package
$ dnf module list [package_name]
copy
Enable a module stream
$ sudo dnf module enable [package_name]:[stream]
copy
Install a specific module version
$ dnf module install [package_name]:[stream]
copy

SYNOPSIS

dnf module command [module:stream]

DESCRIPTION

dnf module manages package modularity, allowing multiple versions of software to coexist in repositories. Modules group packages with a specific purpose, and streams represent different versions.
Modularity is used in RHEL 8+ and Fedora for software like Python, Node.js, and PHP where multiple versions need to be available.

PARAMETERS

list

List available modules
enable module:stream
Enable a module stream
disable module
Disable a module
install module:stream
Install module packages
remove module
Remove module packages
reset module
Reset module state

CAVEATS

Only one stream of a module can be active at a time. Enabling a stream doesn't install packages; use install for that. Available on RHEL 8+ and recent Fedora.

SEE ALSO

dnf(8), dnf-install(8)

Copied to clipboard