Skip to content

Compression and Encryption

A volume’s compression algorithm and, on S3, its server-side encryption are recorded on the volume. You choose them at init and can change them later with flexblock update. A change applies to later writes only.

  1. Stop cleanly: unmount, then stop the daemon. See Stopping Cleanly.

  2. Make the change.

    Terminal window
    sudo flexblock update /dev/nvme1n1p1 --compression lz4
    sudo flexblock update /dev/nvme1n1p1 --s3-no-sse
  3. Start the daemon again and mount.

Add --dry-run to print the old and new values without changing anything.

FlagMeaning
--compression <none|lz4|zstd|snappy>New algorithm for later writes. The default at init is zstd.
--s3-sseS3 only: request server-side encryption (SSE-S3) for later writes.
--s3-no-sseS3 only: stop requesting server-side encryption, for stores that reject the header.

On the other providers, server-side encryption is managed by the provider and there is nothing to change.

You do not need to rewrite anything. Each object in the bucket records its own compression, so objects written under the old setting stay readable after the change.

Run with no change at all, update repairs a volume superblock that object storage reports missing or stale. One that records a larger size than the device needs --device-size at that size.

Terminal window
sudo flexblock update /dev/nvme1n1p1