In this first post I want to give a quick introduction to Blivet. I will try to avoid going into too much detail.

Blivet is a python module for configuring storage on Linux. It is also the storage backend for Anaconda – the Fedora OS installer. That's where Blivet came from, so anything you've done with storage while installing Fedora (since Fedora 11) is something Blivet can do.

It can create and manage LVM (including snapshots and thin provisioning), MD, LUKS, BTRFS (including subvolumes, snapshots, and RAID), and a whole slew of other storage technologies.

Blivet uses a model in which changes (like creating a new device) are represented by actions. Once an action has been registered, Blivet's device tree will reflect the change as if it were already done. That allows you to stack changes – for example, remove existing partitions from a disk, then reinitialize the disk, then create a complex device stack on that disk – all without writing any changes to the disk. You can also cancel actions at any time before they are executed if you change your mind about what you want to do. Once you are satisfied with the overall layout you can write the changes to disk by telling Blivet to execute the actions.

Blivet has powerful disk partitioning capabilities. New partitions can have a fixed size or a (potentially unbounded) size range. A new partition can be constrained to a single disk or a set of possible disks. All new partitions are aligned according to the information exported by the kernel. They can also be specified in terms of start and end sectors on a specific disk, but that disables automatic alignment and requires that you specify a single disk.

Another noteworthy feature is the device factory class hierarchy. These classes can create complex device stacks with a single method call, based on a top-down specification. You can go from an empty disk to an encrypted LVM setup using thin provisioning with two method calls: one to initialize the disk and one to create the full device stack on it.

This is only intended as an introduction. Future posts will go into greater detail about specific areas of functionality.