Automating Encryption at Rest With Canonical's Charmed MongoDB
Ubuntu, Monday, November 23rd, 2026
Canonical explains how Charmed MongoDB automates encryption at rest, including master key storage and rotation.
Canonical describes how encryption at rest works in Charmed MongoDB, which uses a two-level key hierarchy: a master key encrypts a key database holding one encryption key per database.
Encryption at rest must be configured at initial deployment and cannot be enabled or disabled later, and losing the keys means losing the data.
Canonical advises against storing the master key in a local file and chose the HashiCorp Vault or OpenBao KV engine over KMIP because it supports secret versioning and rotation in open source form.
Rotating the master key re-encrypts only the key database and must be done offline, one member at a time, but the Charmed MongoDB operators automate this, and a Terraform module deploys the whole stack.