Skip to content

dm-vdo/kvdo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

50 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

kvdo

The kernel module component of VDO which provides pools of deduplicated and/or compressed block storage.

Background

VDO (which includes kvdo and vdo) is software that provides inline block-level deduplication, compression, and thin provisioning capabilities for primary storage. VDO installs within the Linux device mapper framework, where it takes ownership of existing physical block devices and remaps these to new, higher-level block devices with data-efficiency capabilities.

Deduplication is a technique for reducing the consumption of storage resources by eliminating multiple copies of duplicate blocks. Compression takes the individual unique blocks and shrinks them with coding algorithms; these reduced blocks are then efficiently packed together into physical blocks. Thin provisioning manages the mapping from LBAs presented by VDO to where the data has actually been stored, and also eliminates any blocks of all zeroes.

With deduplication, instead of writing the same data more than once each duplicate block is detected and recorded as a reference to the original block. VDO maintains a mapping from logical block addresses (used by the storage layer above VDO) to physical block addresses (used by the storage layer under VDO). After deduplication, multiple logical block addresses may be mapped to the same physical block address; these are called shared blocks and are reference-counted by the software.

With VDO's compression, multiple blocks (or shared blocks) are compressed with the fast LZ4 algorithm, and binned together where possible so that multiple compressed blocks fit within a 4 KB block on the underlying storage. Mapping from LBA is to a physical block address and index within it for the desired compressed data. All compressed blocks are individually reference counted for correctness.

Block sharing and block compression are invisible to applications using the storage, which read and write blocks as they would if VDO were not present. When a shared block is overwritten, a new physical block is allocated for storing the new block data to ensure that other logical block addresses that are mapped to the shared physical block are not modified.

This public source release of VDO includes a kernel module and a set of userspace tools for managing storage volumes. The "kvdo" module implements fine-grained storage virtualization, thin provisioning, block sharing, and compression, as well as memory-efficient duplicate identification. The userspace tools include a utility called "vdostats" for extracting statistics from VDO volumes, and utilities for analyzing and repairing VDO volumes.

Documentation

Releases

Each branch on this project is intended to work with a specific release of Enterprise Linux (Red Hat Enterprise Linux, CentOS, etc.). We try to maintain compatibility with active Fedora releases, but some modifications may be required and if they become too extensive we may stop providing these updates at any point for a particular branch.

Version Intended Enterprise Linux Release Supported With Modifications
6.1.x.x EL7 (3.10.0-*.el7)
6.2.x.x EL8 (4.18.0-*.el8) Supported Fedora releases and Rawhide
8.x.x.x EL9 (5.14.0-*.el9) Supported Fedora releases and Rawhide
  • Pre-built versions with the required modifications for the referenced Fedora releases can be found here and can be used by running dnf copr enable rhawalsh/dm-vdo.

The unstable branch provides a snapshot of our most up to date internal code that is targeting the mainline kernel and is currently under test. There are no guarantees of stability from this branch.

Status

VDO was originally developed by Permabit Technology Corp. as a proprietary set of kernel modules and userspace tools. This software and technology has been acquired by Red Hat, has been relicensed under the GPL (v2 or later), and this repository begins the process of preparing for integration with the upstream kernel.

While this software has been relicensed there are a number of issues that must still be addressed to be ready for inclusion into the upstream kernel. To see the progress of this effort, visit the Unstable branch of this project.

Building

In order to build the kernel modules, invoke the following command from the top directory of this tree:

    make -C /usr/src/kernels/`uname -r` M=`pwd`

To install the compiled modules:

    make -C /usr/src/kernels/`uname -r` M=`pwd` modules_install
  • There is a dkms.conf template that can be used in the kvdo.spec file which can take care of building and installing the necessary kernel modules any time a new kernel is booted.

  • Patched sources that work with the most recent upstream kernels can be found here.

Communication channels

Community feedback, participation and patches are welcome to the vdo-devel@redhat.com mailing list -- subscribe here.

Contributing

This project is currently a stepping stone towards integration with the Linux kernel. As such, contributions are welcome via a process similar to that for Linux kernel development. Patches should be submitted to the vdo-devel@redhat.com mailing list, where they will be considered for inclusion. This project does not accept pull requests.

Licensing

GPL v2.0 or later. All contributions retain ownership by their original author, but must also be licensed under the GPL 2.0 or later to be merged.