Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DRBD kernel module mismatch in different distro's #10

Closed
kees-closed opened this issue May 9, 2021 · 6 comments
Closed

DRBD kernel module mismatch in different distro's #10

kees-closed opened this issue May 9, 2021 · 6 comments

Comments

@kees-closed
Copy link

Hi, I'm trying to understand something I've noticed in multiple distro's. That's that the kernel module is still version 8 and the userspace utilities are version 9. This software mismatch prevents me from using the connection mesh method, which is exclusively in DRBD 9.

I noticed this way back already, as described in here.

But this is still the case in Debian 11 as well:

drbdadm --version
DRBDADM_BUILDTAG=GIT-hash:\ baaca8a080dc54652f57da4bafb2dce51dfe9f68\ reproducible\ build\,\ 2020-09-29\ 09:05:36
DRBDADM_API_VERSION=1
DRBD_KERNEL_VERSION_CODE=0x08040b
DRBDADM_VERSION_CODE=0x090f00
DRBDADM_VERSION=9.15.0

And on Fedora 34:

drbdadm --version
DRBDADM_BUILDTAG=GIT-hash:\ a7820b3c14497a34f955ba5ce56cf1bc9d2d353e\ build\ by\ mockbuild@\,\ 2021-02-21\ 21:23:10
DRBDADM_API_VERSION=1
DRBD_KERNEL_VERSION_CODE=0x08040b
DRBDADM_VERSION_CODE=0x091000
DRBDADM_VERSION=9.16.0

What could be the reason for this? Is the kernel module not mature enough to be used? I suppose there is no way to use the connection mesh option when this old kernel module is used. The only alternatives would be to use the old stacking or build a module myself. Both not ideal.

@kees-closed
Copy link
Author

I suppose it's because the DRBD9 kernel module isn't in the kernel mainline yet? I guess it will be "old school" stacking resources then :)

@rck
Copy link
Member

rck commented May 11, 2021

A few things, maybe also for people finding this issue:

  • it is fine to use drbd-utils 9.x with a kernel module 8.x. There is no "mismatch".
  • kmod 9.x is mature enough, we recommend it for our customers, upstreaming is just a major effort. for sure that is the goal, but will not happen "tomorrow"
  • building a module on your own is as complicated as calling make. One can even build a dkms package. But yes, it assumes a sufficiently compatible kernel (we build for around 100 kernels, the main LTS distributions/kernels should work). Still, it is additional work, depending if you distro provides a stable kABI or not, so you can become a customer and get access to LINBIT's software including prebuilt kernel modules.

@rck rck closed this as completed May 11, 2021
@kees-closed
Copy link
Author

  • it is fine to use drbd-utils 9.x with a kernel module 8.x. There is no "mismatch".

I'll leave the following snippet here below for future generations to find, it might help them understand the severity of the error.

# /lib/drbd/drbdadm-84 --version
DRBD module version: 8.4.10
   userland version: 9.5.0
mixing different major numbers will not work!

Thanks for your reply by the way. I know that these solutions exist. I'll use the old stacking method in the meantime since I don't want to burden myself with maintaining and testing these kernel modules myself. Once it hits the mainline kernel I will switch. Thank you all for your hard work and dedication!

@rck
Copy link
Member

rck commented May 12, 2021

there is no missmatch and there is no "severity on an error", you are just using it wrong. Why would you directly call the -84 version? The top level one handles that perfectly fine and calls the according tool depending on the kernel module loaded:

PATH=../v84:$PATH ./drbdadm --version  # using toplevel one, adding the -84 to the PATH in this case so it can be found and spawned
DRBDADM_BUILDTAG=GIT-hash:\ 35a7e9cbe29a14f3903d79c223997a948e77fd76\ build\ by\ roland@laubbaum\,\ 2021-04-30\ 14:15:18
DRBDADM_API_VERSION=1
DRBD_KERNEL_VERSION_CODE=0x08040b
DRBDADM_VERSION_CODE=0x091100
DRBDADM_VERSION=9.17.0
Ξ laubbaum drbd-utils/user/v9 master ✓ ../v84/drbdadm-84 --version # using it wrong for whatever reason
DRBD module version: 8.4.11
   userland version: 9.17.0
mixing different major numbers will not work!
DRBDADM_BUILDTAG=GIT-hash:\ 35a7e9cbe29a14f3903d79c223997a948e77fd76\ build\ by\ roland@laubbaum\,\ 2021-04-30\ 14:15:18
DRBDADM_API_VERSION=1
DRBD_KERNEL_VERSION_CODE=0x08040b
DRBDADM_VERSION_CODE=0x091100
DRBDADM_VERSION=9.17.0

@kees-closed
Copy link
Author

The reason is just troubleshooting, since I get different versions of the userspace tools and kernel modules. Matching the userspace with the kernel module version (8.4) was just a way to test things and understand the tool. That error doesn't make it more clear. Please understand that this mixture of versions in a release is confusing for users as well. I hope the kernel module will be in sync soon then maybe with Debian 12 I can use the mesh functionality out of the box :)

@raltnoeder
Copy link
Member

DRBD 8.x is limited to one replication link per resource. Multiple links require version 9.x, and that is also the reason why the connection-mesh section is only supported with a DRBD 9.x kernel module.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants