[DRBD-user] BUG? Oops: kernel NULL pointer dereference in drbd_connector_callback

Philipp Reisner philipp.reisner at linbit.com
Thu Oct 29 15:43:15 CET 2009

Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.


On Thursday 29 October 2009 14:30:34 Dimitrij Hilt wrote:
> Lars Ellenberg schrieb:
> > On Mon, Oct 19, 2009 at 02:43:52PM +0200, Robert Dahlem wrote:
> >> On 19.10.2009 11:51, Lars Ellenberg wrote:
> >>>>> I'm trying to install DRBD 0.8.3.4 on top of Linux 2.6.31.3.
> >>>>> When trying to start DRBD I get an Oops:
> >>>
> >>> Did it even occur to you that you could also try the "usual"
> >>> out-of tree module build?
> >>
> >> Sorry, but no, that didn't occur to me. I used the kernel-patch method
> >> since 0.7 and always preferred it, because there are two drawbacks with
> >> the "usual" method:
> >>
> >> 1.) If you prepare your system for a new kernel version you need to
> >> remember a special depmod command to prevent ending up with "modprobe:
> >> FATAL: Module drbd not found" after a reboot:
> >>
> >> 	depmod -ae `cat /usr/src/linux/include/config/kernel.release`
> >>
> >> That was not needed with the kernel-patch method.
> >>
> >> 2.) If you have a running system and recompile/reinstall your kernel,
> >> after "make modules_install" the drbd module is gone. You always need to
> >> remember to change to the drbd directory and do "make install" again.
> >
> > So you alwasy roll your own kernel.  Ok.
> >
> > I think "most" use a distro kernel, and most distros solve those
> > problems with package management, dependencies and trigger scripts,
> > maybe a system like dkms and possibly a lazy depmod during boot.
>
> Same problem here with Debian, Kernel 2.6.30-bpo.1-amd64 from
> backports.org and DRBD-8.3.5. DRBD was build as modules source an
> compiled as Module for this kernel. Server was running 8.3.0 a long time
> without any problems. After update if drbd starts we get anytime a
> kernel Oops:

Please see here:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=552439

The issue is, that DRBD has to work on a high number of distribution kernels,
and all these kernels differ in various ways. You can configure the compile
process in drbd_config.h. Actually we deliver a script 
(scripts/adjust_drbd_config_h.sh) which looks at the kernel source on your
machine and sets all those little defines in drbd_config.h in a way that
the compilation process works.

Unfortunately, the way the debian packaging works, they never call that
script. For many years no user became aware of that fact, because the
drbd_config.h we ship is the way it should be for the vanilla upstream
kernel. Debian's distribution kernels are usually much closer to the
vanilla kernel than the kernels of the other distributions are.

But now, there is a setting in drbd_config.h (KERNEL_HAS_CN_SKB_PARMS)
that does not break the compilation process, you only get a warning,
but later on the module will OOPS!

Your way out: 
Unpack the plain .tar.gz distribution from oss.linbit.com and simply
call make in there. Either use the drbd/drbd.ko from that build,
or copy the correcter drbd_config.h over to your debian packaging
stuff... and redo the module assistant thing...

Also following the user's guild way to produce a .deb should produce 
a correct module:

http://www.drbd.org/users-guide/s-build-deb.html

To my knowledge, only the vanilla debian packaging is broken.

>
> Is anythink wrong with drbd-8.3.5?
>

No, it is just a wrong drbd_config.h 

-phil
-- 
: Dipl-Ing Philipp Reisner
: LINBIT | Your Way to High Availability
: Tel: +43-1-8178292-50, Fax: +43-1-8178292-82
: http://www.linbit.com

DRBD(R) and LINBIT(R) are registered trademarks of LINBIT, Austria.




More information about the drbd-user mailing list