[plug] Problems building drbd for an SMP 2.2.16 kernel

raven ian.kent at pobox.com
Thu Jul 6 18:16:03 WST 2000


Richard Sharpe wrote:

> Hi,
>
> I am trying to build drbd for a 2.2.16SMP machine, but am having problems
> when I try to load the module (drbd.o).
>
> It tells me that the module was build for a 2.2.16-3 kernel, while we are
> running on a 2.2.16-3SMP kernel.

Version defines are at the top of /usr/src/linux/Makefile eg.

VERSION = 2
PATCHLEVEL = 2
SUBLEVEL = 16
EXTRAVERSION = -1

If you want to be able to compile and load a module without rebuilding the
kernel you need to compile a kernel with:

CONFIG_MODVERSIONS not set

This corresponds to not checking version info for modules.


>
>
> This suggests that somewhere there is a version file that contains that
> magic info incorrectly.
>

The version file is /usr/include/linux/version.h
Redhat copy this file to other names when the kernel-*.rpm 's are created
but I believe that this the file that is used. I could be wrong about this.

Short story is you need to compile a kernel and compile the module against
that kernel config.
There should be no need to modify the veraion string if the module is
compiled against the correct kernel.

But are you sure it is a 2.2 module. I have seen some hint of independent
module compile and install in the 2.[34] doco?





More information about the plug mailing list