Red Hat Bugzilla – Bug 572883
proper kmod handling
Last modified: 2014-01-21 01:16:59 EST
as i wrote in yum-devel list thread:
currently in rhel and elrepo kmod are not yum friendly.
on rhel/centos-5w we've a lot's of kernel module (thanks to the elrepo)
and we can build our own on a nearly standardized way for rhel/centos.
but i now run into a problem how to add a require kmod line into another
package's spec file. it seems to very easy, if i've got package x.spec:
first question whether y-kmod or kmod-y (tha package name or the virtual
provides)? and if we go a bit further and have a i386 machine with 4gb
ram which install by default kernel-PAE and like to install x into that
machine i wish to pull (yum pull) kmod-x-PAE and not kmod-x since it
can't be used on a PAE kernel. what's more if x pull kmod-y that also
pull the none PAE kernel too which is also not a good think. there are
two plugins in yum-utils yum-kernel-module and yum-fedorakmod, but none
of the seems to working (yum-fedorakmod instal the proper kmod-x-PAE too
if i set installforallkernels=1, but still install the non PAE one and
the none PAE kernel too).
so what's the good and proper solution to require y kernel module into
package x (in a way that works with yum on all kernel variant)?
i even like to modify any of the yum-kernel-module or yum-fedorakmod to
be able to use, but the problem is that i can't write conditional
requires in a package spec file which depend on the runtime kernel
if there would be some tricky yum plugins which do this:
- if yum needs to install a package
- check whether the package provide kabi-module or kernel-module. if yes
it's a kernel module.
- if it's a kernel module than check the currently running kernel (and
optionally all installed kernel) and install the proper kernel module
variant. eg. if the running kernel is:
- kernel-2.6.18-164.11.1.el5 then install kmod-ocfs2
- kernel-PAE-2.6.18-164.11.1.el5 then install kmod-ocfs2-PAE
it'd be useful to fix in rhel6 (but i can't open rhel6 ticket so please modify the product type:-)
could you change it to rhel-6
I'm not exactly a kmod* packaging expert, but:
1. The only examples I can find of packages requiring kmod's, they require the virtual provide (this also seems sane, or it could never work). However these are kmod2 style packages (see below).
2. yum in RHEL-6 has new additions to compare_providers(), most importantly the fact it'll try and install the provider which requires the fewest deps. ... this might be enough to work out PAE vs. non-PAE on it's own.
3. kmod's in rpmfusion have moved away from using the yum-kmod plugin altogether, see: http://rpmfusion.org/Packaging/KernelModules/Kmods2
4. While we (RH) ship kmod-xfs and xfsprogs etc. in RHEL-5 ... we don't have a dep. between userspace and the kernel module.
...do you still want/need to change something ... if so what?
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release. Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release. This request is not yet committed for
ps. jon masters is the master of kmod:-) may be he can be added to the cc list.
there is no longer pae kernel in rhel-6 so it's no longer an issue, but
- you can remove yum-kernel-module and yum-fedorakmod
- or fix it.
as in rhel kernel among dot release eg 6.0. 6.3 are kabi compatible it has no reason to keep different kmods for different kernel (one works for all), but if i modify something in a kmod package the it'd be useful (and imho the only good solution) to update kmod package and not install. ie: if i have installed
kmod-foo-1.0 and in any repo there is a kmod-foo-1.1 then yum update do NOT install the new package, but update it.
and that's the main problem currently with yum.
This issue has been proposed when we are only considering blocker
issues in the current Red Hat Enterprise Linux release. It has
been denied for the current Red Hat Enterprise Linux release.
** If you would still like this issue considered for the current
release, ask your support representative to file as a blocker on
your behalf. Otherwise ask that it be considered for the next
Red Hat Enterprise Linux release. **
Created attachment 435745 [details]
fix installonlypkgs and kernelpkgnames
first of all remove 'kernel-modules' from the installonlypkgs and i try to make it clear the installonlypkgs and kernelpkgnames variable. does anyone really know what they good for???
- it contains kernel-devel but not kernel-PAE-devel
- it contains kernel-debug but not kernel-debug-devel
- it contains kernel-PAE but not kernel-xen
- it not contains kernel-doc and kernel-headers
- it contains some magic names like kernel-source kernel-unsupported
- it contains kernel-PAE-debug (typo of kernel-PAE-devel?)
- it contains kernel-PAE-debug but not kernel-debug
it would be nice to clean up!
> eg installonlypkgs:
> - it contains kernel-devel but not kernel-PAE-devel
That's not true. I've fixed the documentation to be clearer upstream:
List of package provides that should only ever be installed, never updated.
Kernels in particular fall into this category. Defaults to kernel,
kernel-bigmem, kernel-enterprise, kernel-smp, kernel-modules, kernel-debug,
kernel-unsupported, kernel-source, kernel-devel, kernel-PAE, kernel-PAE-debug.
Note that because these are provides, and not just package names, kernel-devel
will also apply to kernel-debug-devel, etc.
the original reason for this bugzilla was the kernel-modules. as i already white and discussed many places it should have to be removed from this list:
so can i reopen this bug for further discussion?
If newer kmods aren't meant to be "installonly" why are they providing kernel-modules? Just remove that provide, and it'll be happy.