Why yum groupinstall "<package group name>" is failing on RHEL 7 with error "There is no installed groups file" ?

Solution Unverified - Updated -

Environment

  • Red Hat Enterprise Linux 7.0
  • yum

Issue

  • yum groupinstall "Office Suite and Productivity" is failing on Red Hat Enterprise Linux 7 with error There is no installed groups file

  • yum groupinstall "Office Suite and Productivity"

Loaded plugins: langpacks, product-id, subscription-manager
There is no installed groups file.
Maybe run: yum groups mark convert (see man yum)
Warning: Group office-suite does not have any packages to install.
Maybe run: yum groups mark install (see man yum)
No packages in any requested group available to install or update
  • yum groupinstall "Graphical Administration Tools"
Loaded plugins: langpacks, product-id, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
There is no installed groups file.
Maybe run: yum groups mark convert (see man yum)
Warning: Group graphical-admin-tools does not have any packages to install.
Group graphical-admin-tools does have 1 conditional packages, which may get installed.
Maybe run: yum groups mark install (see man yum)
No packages in any requested group available to install or update
  • yum groupinstall "System Administration Tools"
Loaded plugins: langpacks, product-id, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
There is no installed groups file.
Maybe run: yum groups mark convert (see man yum)
Warning: Group system-admin-tools does not have any packages to install.
Maybe run: yum groups mark install (see man yum)
No packages in any requested group available to install or update
  • yum group install "kde-desktop" fails with "No packages in any requested group available to install or update" message.

Resolution

  • The yum has changed in Red Hat Enterprise Linux 7. The package group "Office Suite and Productivity" has only the optional packages which by default doesn't get installed. So we will need to pass the option to install the optional packages too!

  • So to install the above package group, please run the following command.

# yum groupinstall "Office Suite and Productivity" --setopt=group_package_types=mandatory,default,optional
  • For more information about how to provide yum configuration parameters on yum command-line please refer 392183

Root Cause

  • The yum has changed in Red Hat Enterprise Linux 7. The package group "Office Suite and Productivity" has only the optional packages which by default doesn't get installed. So we will need to pass the option to install the optional packages too!
  • In case you have all Mandatory Packages installed on the system, then the current behavior is correct by design. RHEL-7 introduced new concept of package groups being handled as objects (something like an extra package) while previously the group presence was defined by the presence of respective packages.

  • It can be better explained in below two scenarios :
    A) If all the packages part of "Development" group are installed (e.g. via yum group install) and since you want to consume also future updates of the Development group (e.g. package additions) the group should be marked as installed (this is by default if you have installed packages via yum group install).

    B) you have accidentally installed same set of packages but you might not interested in particular in the Development group (since you did not install it directly) and therefore you do not want to keep it up to date (except individual package updates). In this case the group should not be marked as installed.
    In case, you are in situation B) but you want to switch to A). In order to do that you need to run
    yum groups mark install "Development Tools"
    in order to let yum know that you really want the group to be present.

The alternative would be to adjust the way how system is provisioned so you would install the package group (scenario A) instead of installing individual packages (scenario B).

Also, maybe we could consider implementing RFE so the group would be marked as installed automatically after "yum group install Group" in case all Mandatory Packages are already present.

Diagnostic Steps

  • When all the packages are already during the system provisioning or manually installed , we can see that the group is still not listed as installed - this is expected!
# yum grouplist
Loaded plugins: product-id, search-disabled-repos, subscription-manager
There is no installed groups file.
Maybe run: yum groups mark convert (see man yum)
Available Environment Groups:
   Minimal Install
   Infrastructure Server
   File and Print Server
   Basic Web Server
   Virtualization Host
   Server with GUI
Available Groups:
   Compatibility Libraries
   Console Internet Tools
   Development Tools
   Graphical Administration Tools
   Legacy UNIX Compatibility
   Scientific Support
   Security Tools
   Smart Card Support
   System Administration Tools
   System Management
Done
  • But in detailed output we can see that all packages from the group are installed (the additional space before the package name indicates that the packages has been installed but not as a part of a group installation, see man yum).
# yum group info 'Development Tools'
Loaded plugins: product-id, search-disabled-repos, subscription-manager
There is no installed groups file.
Maybe run: yum groups mark convert (see man yum)

Group: Development Tools
 Group-Id: development
 Description: A basic development environment.
 Mandatory Packages:
    autoconf
    automake
    binutils
    bison
    flex
    gcc
    gcc-c++
    gettext
    libtool
    make
    patch
    pkgconfig
    redhat-rpm-config
    rpm-build
    rpm-sign
 Default Packages:
    byacc
    cscope
    ctags
    diffstat
    doxygen
    elfutils
    gcc-gfortran
    git
    indent
    intltool
    patchutils
    rcs
    subversion
    swig
    systemtap
 Optional Packages:
   ElectricFence
   ant
   babel
   bzr
   chrpath
   cmake
   compat-gcc-44
   compat-gcc-44-c++
   compat-gcc-44-g77
   cvs
   dejagnu
   expect
   gcc-gnat
   gcc-objc
   gcc-objc++
   imake
   javapackages-tools
   ksc
   libstdc++-docs
   mercurial
   mod_dav_svn
   nasm
   perltidy
   python-docs
   rpmdevtools
   rpmlint
   systemtap-sdt-devel
   systemtap-server

So now we can eventually mark group as installed manually....

# yum groups mark install "Development Tools"
# yum group list
Loaded plugins: product-id, search-disabled-repos, subscription-manager
Available Environment Groups:
   Minimal Install
   Infrastructure Server
   File and Print Server
   Basic Web Server
   Virtualization Host
   Server with GUI
Installed Groups:
   Development Tools
Available Groups:
   Compatibility Libraries
   Console Internet Tools
   Graphical Administration Tools
   Legacy UNIX Compatibility
   Scientific Support
   Security Tools
   Smart Card Support
   System Administration Tools
   System Management
Done
  • Installed packages are prefixed with one extra space (not really user friendly way)
  • Component
  • yum

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.

Comments