DKMS pulls in kernel-debug-devel which is useless and breaks puppet deployment of DKMS-related apps

Latest response

I'd like to get the community's take on this in addition to submitting a support case which I'll do after I write this up.

Problem: DKMS-dependent apps need kernel-devel in order to build dynamic kernel modules. DKMS has a dependency of 'kernel-devel'. Sadly, the package kernel-debug-devel testifies to RPM that it meets that dependency, and for whatever reason, it is pulled in before the true kernel-devel package (maybe because kernel-deb* is before kernel-dev* alphabetically?). *1

So once this is installed, DKMS thinks it can roll kernel modules, but since kernel-debug-devel doesn't provide kernel source files, it actually can't - thus no OpenAFS for you!

The next issue in this cascade of woe is that once this dependency for 'kernel-devel' is satisfied by the RPM 'kernel-debug-devel', the RPM database shows that 'kernel-devel' is installed to the extent that Puppet can check. *2 Since one of the tests for 'kernel-devel' is met by 'kernel-debug-devel', you cannot apply 'kernel-devel' RPM via puppet unless you do so before 'kernel-debug-devel' RPM is on the host.

I believe all of this sadness is caused by incorrect provides of kernel-debug-devel RPM as shown in *3.

1.

 ===================================================================================================================================================================================================================
  Package                                              Arch                                     Version                                                Repository                                              Size 
===================================================================================================================================================================================================================
Installing:
 dkms                                                 noarch                                   2.2.0.3-26.el7                                         epel-el7-x86_64                                         76 k
Installing for dependencies:
 kernel-debug-devel                                   x86_64                                   3.10.0-123.9.3.el7                                     rhel-x86_64-server-7                                   9.0 M

Transaction Summary
===================================================================================================================================================================================================================
Install  1 Package (+1 Dependent package) 


2. 

/bin/rpm -q kernel-devel --nosignature --nodigest --qf '%{NAME} %|EPOCH?{%{EPOCH}}:{0}| %{VERSION} %{RELEASE} %{ARCH}\n'
package kernel-devel is not installed
/bin/rpm -q kernel-devel --nosignature --nodigest --qf '%{NAME} %|EPOCH?{%{EPOCH}}:{0}| %{VERSION} %{RELEASE} %{ARCH}\n' --whatprovides
kernel-debug-devel 0 3.10.0 123.9.3.el7 x86_64


3.

rpm -ql kernel-debug-devel --provides | grep kernel-devel
kernel-devel-x86_64 = 3.10.0-123.9.3.el7.debug
kernel-devel = 3.10.0-123.9.3.el7.debug
kernel-devel-uname-r = 3.10.0-123.9.3.el7.x86_64.debug

Responses

I think you've identified a bug. Perhaps you'd like to file a report at bugzilla.redhat.com (in addition to opening a support case) ?

I can confirm that, on a system that already has kernel-devel installed, there is no issue.

Yea I think it's a bug with kernel-debug-devel. Chatting with folks on #RHEL, it sounds like it's a bug and that other people have been hit by it.
This snippet from IRC sums up the problem succinctly:

(12:15:29 PM) -----: I'm currently hating that kernel-debug-devel provides kernel-devel, and the NEVRA ordering finds kernel-debug-devel over kernel-devel

https://bugzilla.redhat.com/show_bug.cgi?id=1164344

Unfortunately that bug report is private. :(

That is a crying shame - I've complained about them making bugreports private until the cows come home - no idea why they are private. I'm the only person on that bug report so far and I know I didn't make it private so it must default to such. BOOOO

Here's the problematic portion of the kernel spec file:

#
# This macro creates a kernel-<subpackage>-devel package.
#       %%kernel_devel_package <subpackage> <pretty-name>
#
%define kernel_devel_package() \
%package %{?1:%{1}-}devel\
Summary: Development package for building kernel modules to match the %{?2:%{2} }kernel\
Group: System Environment/Kernel\
Provides: kernel%{?1:-%{1}}-devel-%{_target_cpu} = %{version}-%{release}\
Provides: kernel-devel-%{_target_cpu} = %{version}-%{release}%{?1:.%{1}}\
Provides: kernel-devel = %{version}-%{release}%{?1:.%{1}}\
Provides: kernel-devel-uname-r = %{KVRA}%{?1:.%{1}}\
AutoReqProv: no\
Requires(pre): /usr/bin/find\
Requires: perl\
%description -n kernel%{?variant}%{?1:-%{1}}-devel\
This package provides kernel headers and makefiles sufficient to build modules\
against the %{?2:%{2} }kernel package.\
%{nil}

I don't think I'll ever remember how to do code blocks on this portal..... I thought it was three ''' but nope...

It's ~~~ text ~~~ (three tilde symbols).

code

Awesome, thanks.

It's a little frustrating. I'm looking into adding a gui shortcut to allow quick code-block formatting.

Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.