DRBD, developed by LINBIT, is a kernel-level replicated block device for GNU/Linux. It synchronizes storage across up to 32 nodes over TCP/IP or RDMA with synchronous or asynchronous replication. DRBD 9 supports multi-node topologies, quorum, automatic promotion, and serves as the data plane for LINSTOR, LINBIT's software-defined storage manager.
This repository contains the Linux kernel module for DRBD 9.
The source tree always targets the newest upstream kernel; backward compatibility is handled automatically by a Coccinelle-based compat system. The oldest kernel we support is 4.12.14 (SLES 15 SP1).
| Distribution | Minimum version | Minimum kernel |
|---|---|---|
| RHEL | 8.0 | 4.18.0-80 |
| SLES | 15 SP1 | 4.12.14-197 |
| Debian | 10 (Buster) | 4.19.0 |
| Ubuntu | 18.04 (Bionic) | 4.15.0 |
RHEL-compatible distributions (AlmaLinux, Rocky Linux, Oracle Linux) use similar kernels and are generally supported as well.
Tip
DRBD development generally stays up-to-date with kernel compatibility, so most new distribution kernels should start working within the next DRBD release. For Red Hat-based distributions, a module built for a slightly older kernel version (usually within the same RHEL minor) may also work. We test DRBD with all new RHEL kernels and publish a live overview at kernels.drbd.io.
Please read the User Guide provided at docs.linbit.com.
For further products and professional support, please contact us.
Development is coordinated via mailing lists. Currently, we do not intend to use GitHub issue tracking or pull requests.
We apply Linux kernel code style checks. Install the pre-commit hook to check your contributions automatically:
curl -L https://github.com/torvalds/linux/raw/master/scripts/checkpatch.pl | sudo tee /usr/local/bin/checkpatch.pl | wc
sudo chmod +x /usr/local/bin/checkpatch.pl
curl -L https://github.com/torvalds/linux/raw/master/scripts/spelling.txt | sudo tee /usr/local/bin/spelling.txt | wc
sudo touch /usr/local/bin/const_structs.checkpatch
cp misc/pre-commit .git/hooks/
The simplest way to use DRBD is to install the pre-built rpm/deb packages, available to LINBIT customers. Contact us for more information.
Release tarballs ship pre-generated compat patches for common distribution
kernels. In most cases, make just works. For other kernels, the build
automatically uses LINBIT's "spatch as a service" to generate the right
patches. If you don't have internet access, you will need a local
Coccinelle installation (see Building from git).
Building from git requires Coccinelle (spatch) >= 1.1.1 for the kernel
backward compatibility system. Most distributions ship older versions.
Options:
- Use a recent kernel. When building against a recent upstream kernel,
no compat patches are needed and
spatchis not required. - Use Fedora's Coccinelle package, which is recent enough to build DRBD. Warning: Ubuntu's Coccinelle package, despite reporting the same version number, is not able to build DRBD.
- Build spatch from source.
Each release targets the latest upstream kernel at the time and ships pre-generated compat patches for the distributions listed above. We do not backport compat to older DRBD releases. If your kernel is newer than what a release was tested against, you may need to wait for the next release or do the compat work yourself.
Releases generated by git tags on GitHub are snapshots of the git repository at the given time. You most
likely do not want to use these. They might lack things such as generated man pages, the configure script,
and other generated files. If you want to build from a tarball, use the ones provided by us.