[DRBD-user] building v9

Stéphane Rivière stef at genesix.org
Sat Dec 12 10:46:45 CET 2020


> Hmm interesting.  It would help to know how to find out about the exact and ideal version.  It must be available somewhere, right?  Having this version at the top of the table you've shared above (and even as number 1 supported kernel) would seem logical to me.  And it would be great if this table could be shared publicly, maybe in drbd-9.0's README?


My one month message old on this list. Not really related but see what
I've noticed...

Then a very fine man told me here that proxmox's packages are
available... (As proxmos is debian based, there are good for Debian 10 &
Ubuntu).

Hope this helps...

=============================================

I'm a Debian 10 user, which don't comes with a DRBD 9 package. So i did
it, through the well described process DRBD 9 comes with.

Particullary, I appreciate the trick to use a full docker container as a
command (spatch/inria coccinelle). And I understand why you are using
Coccinelle. The build complexity involved worth it.

Now my problem (if we should consider it is so) - stock new Debian 10
with original kernel 4.19 on a new high grade server (Xeon 16c, 64 Go,
NVMe 1To).

A first attempt with 9.0.25-1 6/11/20 :
- build ok
- packaging ok

But installing dkms_9.0.25-1_all.deb (kernel module) failed with a
non-explicit debian dpkg-buildpackage message (like... error : kernel
module not installed).

Second attempt with the drbd version closest to the kernel version :
9.0.16-1 25/10/18 (kernel 4.19 is dated 22/10/18)

All went fine.

It's not a problem for us to go in production with 9.0.16-1 (we will see
later / if / I am right to say so).

I wonder :

- how we could explain this behaviour and, maybe...
- how we could fix it

- why drbd 9 is not in debian 10 (and does not seem planned in debian
11, at least today)


Freundliche Grüße der Insel Oléron

=============================================

Build process - also in case other readers would like to test drbd 9
with debian 10


* Coccinelle

aptitude install apt-transport-https ca-certificates curl gnupg2
software-properties-common

curl -fsSL https://download.docker.com/linux/debian/gpg | sudo apt-key add -

add-apt-repository "deb [arch=amd64]
https://download.docker.com/linux/debian $(lsb_release -cs) stable"

aptitude update
apt-cache policy docker-ce
aptitude install docker-ce

systemctl status docker
docker pull szeder/coccinelle

touch /usr/local/bin/spatch
chmod +x s/usr/local/bin/spatch

#!/bin/bash
docker run -it --rm -v "$PWD:$PWD" -w "$PWD" szeder/coccinelle spatch "$@"


* Drbd - kernel module

aptitude install git build-essential fakeroot debhelper dkms docbook-xsl
help2man python-all python-dbus python-gobject xsltproc help2man
dh-systemd flex autoconf automake po4a clitest python-natsort
thin-provisioning-tools

mkdir /root/sow-drbd
cd /root/sow-drbd
git clone https://github.com/LINBIT/drbd.git
cd drbd

search match between kernel date and drbd date

git log --tags --simplify-by-decoration --pretty="format:%ai %d" | grep
2018

2018-10-25 11:15:45 +0200  (HEAD, tag: drbd-9.0.16-1)
2018-10-16 15:10:45 +0200  (tag: drbd-9.0.16-0rc1)
2018-08-14 13:13:50 +0200  (tag: drbd-9.0.15)
2018-05-01 00:13:42 +0200  (tag: drbd-9.0.14)
2018-04-17 10:33:08 +0200  (tag: drbd-9.0.13)
2018-04-06 14:33:03 +0200  (tag: drbd-9.0.13-0rc1)
2018-01-22 13:28:17 +0100  (tag: drbd-9.0.12)
2018-01-09 13:14:33 +0100  (tag: drbd-9.0.11)

git checkout drbd-9.0.16-1

Doc build workaround : Comment out all references to the documentation
in Makefile.in (search with the string "doc"). The --without-manual and
/ or --with-prebuiltman flags are not sufficient. Without this, the
compilation will be carried out perfectly but the build of the package
will fail.

make clean
make
dpkg-buildpackage -rfakeroot -b -uc



* Drbd - utils

cd /root/sow-drbd
git clone https://github.com/LINBIT/drbd-utils.git
cd drbd-utils

./autogen.sh

./configure --prefix=/usr --localstatedir=/var --sysconfdir=/etc
--without-manual --with-prebuiltman --with-xen --with-distro=debian

make
dpkg-buildpackage -rfakeroot -b -uc

dpkg-buildpackage rebuild with theses configure options :

./configure
 --prefix=/usr
 --localstatedir=/var                          modifiable single-machine
data [PREFIX/var]
 --sysconfdir=/etc                             read-only single-machine
data [PREFIX/etc]
 --sbindir=/usr/sbin                           system admin executables
[EPREFIX/sbin]
 --with-udev                                   Enable udev integration
 --with-xen                                    Enable Xen integration
 --with-pacemaker                              Enable Pacemaker integration
 --with-rgmanager                              Enable Red Hat Cluster
Suite integration
 --without-bashcompletion                      Enable programmable bash
completion
 --with-systemdunitdir=/lib/systemd/system     Directory for systemd
service files [Auto]
 --with-initscripttype=both        Type of init script to install
(sysv|systemd|both|none). [auto]
 --with-prebuiltman                            Do not try to
(re)generate man pages


* Installing

packages created :

drbd-dkms_9.0.16-1_all.deb
drbd-module-source_9.0.16-1_all.deb
drbd-utils_9.13.1-1_amd64.deb
drbd-utils-dbgsym_9.13.1-1_amd64.deb
drbd8-utils_9.13.1-1_amd64.deb

Installing :

dpkg -i drbd-dkms_9.0.16-1_all.deb drbd-utils_9.13.1-1_amd64.deb

(Lecture de la base de données... 96165 fichiers et répertoires déjà
installés.)
Préparation du dépaquetage de drbd-dkms_9.0.16-1_all.deb ...
Dépaquetage de drbd-dkms (9.0.16-1) sur (9.0.16-1) ...
Sélection du paquet drbd-utils précédemment désélectionné.
Préparation du dépaquetage de drbd-utils_9.13.1-1_amd64.deb ...
Dépaquetage de drbd-utils (9.13.1-1) ...
Paramétrage de drbd-utils (9.13.1-1) ...
Paramétrage de drbd-dkms (9.0.16-1) ...
Loading new drbd-9.0.16-1 DKMS files...
Building for 4.19.0-12-amd64
Building initial module for 4.19.0-12-amd64
Done.

drbd.ko:
Running module version sanity check.
 - Original module
 - Installation
   - Installing to /lib/modules/4.19.0-12-amd64/updates/dkms/

drbd_transport_tcp.ko:
Running module version sanity check.
 - Original module
 - Installation
   - Installing to /lib/modules/4.19.0-12-amd64/updates/dkms/

depmod...

DKMS: install completed.
Traitement des actions différées (« triggers ») pour systemd
(241-7~deb10u4) ...


After reboot

modinfo drbd

filename:       /lib/modules/4.19.0-12-amd64/updates/dkms/drbd.ko
alias:          block-major-147-*
license:        GPL
version:        *9.0.16-1*
description:    drbd - Distributed Replicated Block Device v9.0.16-1
author:         Philipp Reisner <phil at linbit.com>, Lars Ellenberg
<lars at linbit.com>
srcversion:     E3A2E554068CD055CD421FC
depends:        libcrc32c
retpoline:      Y
name:           drbd
vermagic:       4.19.0-12-amd64 SMP mod_unload modversions
parm:           enable_faults:int
parm:           fault_rate:int
parm:           fault_count:int
parm:           fault_devs:int
parm:           disable_sendpage:bool
parm:           allow_oos:DONT USE! (bool)
parm:           minor_count:Approximate number of drbd devices (1-255)
(uint)
parm:           usermode_helper:string
parm:           protocol_version_min:drbd_protocol_version


-- 
Stéphane Rivière
Ile d'Oléron - France


More information about the drbd-user mailing list