Disabling Userland Helper Scripts (`before-resync-target`)
In a purely LINSTOR®, or containerized environment such as Kubernetes, the userland helper scripts should be disabled by default. However, if you’re loading the kernel modules outside of the module loading containers, you will need to disable them.
You will almost always want to load the kernel modules by using the
kernel-module-loader containers. However, there might occasionally be some
requirement to load the kernel module either from source or by using LINBIT®
RPM packages. If doing so, you will want to disable the default helper scripts
(before-resync-target
and after-resync-target
). You can do this several
ways.
Firstly, you can do this temporarily for testing by switching something
with the /sys
file system, or setting the option when you load the
module.
# echo disabled > /sys/module/drbd/parameters/usermode_helper
# modprobe drbd usermode_helper=disabled
To make this change be permanent and persist through reboots you will
need to create a /etc/modprobe.d/drbd.conf
file. Create the file like
the example below:
# in k8s environment we don't want `before-resync-helper` scripts
options drbd usermode_helper=disabled
⚠️ WARN: Creating the
modeprobe.d
file will not alone automatically load the DRBD module at boot. You still need to add the DRBD kernel module to/etc/modules
.
Reviewed 2020/12/02 - DGT