clevis-luks-edit - Man Page

Edit a binding from a clevis-bound slot in a LUKS device

Synopsis

clevis luks edit [-f] -d DEV -s SLT [-c CONFIG]

Overview

The clevis luks edit command edits clevis bindings from a LUKS device. For example:

clevis luks edit -d /dev/sda1 -s 1

Options

Examples

clevis luks list -d /dev/sda1
1: tang '{"url":"addr"}'

As we can see in the example above, /dev/sda1 has one slots bound, in this case, to a tang pin.

We can edit this binding by issuing the following command:

clevis luks edit -d /dev/sda1 -s 1

This will open a text editor ā€” the one set in the $EDITOR environment variable, or vi, as a fallback ā€” with the current configuration of this binding to be edited. In this case, we should have the following:

{
    "url": "addr"
}

Once at the editor, we can edit the pin configuration. For tang, we could edit the url, for instance. After completing the change, save the file and exit. The updated configuration will be validated for JSON, and if there are no errors, you will be shown the updated configuration and prompted whether to proceed.

By proceeding, the binding will be updated. There may be required to provide a valid LUKS passphrase for the device.

In the second example, we will update the same device and slot, but we will be providing the updated configuration as well:

clevis luks edit -d /dev/sda1 -s 1 -c '{"url":"new-addr-here"}'

In this case, the binding update will be done in non-interactive mode. Note that it may also be required to provide a LUKS passphrase for the device.

See Also

clevis-luks-list(1),

Info

04/03/2024