Imported Upstream version 2.6.1
[platform/upstream/cryptsetup.git] / man / cryptsetup-repair.8.adoc
1 = cryptsetup-repair(8)
2 :doctype: manpage
3 :manmanual: Maintenance Commands
4 :mansource: cryptsetup {release-version}
5 :man-linkstyle: pass:[blue R < >]
6 :COMMON_OPTIONS:
7 :ACTION_REPAIR:
8
9 == Name
10
11 cryptsetup-repair - repair the device metadata
12
13 == SYNOPSIS
14
15 *cryptsetup _repair_ [<options>] <device>*
16
17 == DESCRIPTION
18
19 Tries to repair the device metadata if possible. Currently supported
20 only for LUKS device type.
21
22 This command is useful to fix some known benign LUKS metadata header
23 corruptions. Only basic corruptions of unused keyslot are fixable. This
24 command will only change the LUKS header, not any key-slot data. You may
25 enforce LUKS version by adding --type option.
26
27 It also repairs (upgrades) LUKS2 reencryption metadata by adding
28 a metadata digest that protects it against malicious changes.
29
30 If LUKS2 reencryption was interrupted in the middle of writing
31 reencryption segment the repair command can be used to perform
32 reencryption recovery so that reencryption can continue later.
33 Repairing reencryption requires verification of reencryption
34 keyslot so passphrase or keyfile is needed.
35
36 *<options>* can be [--timeout, --verify-passphrase, --disable-locks,
37 --type, --header, --key-file, --keyfile-size, --keyfile-offset, --key-slot].
38
39 *WARNING:* Always create a binary backup of the original header before
40 calling this command.
41
42 include::man/common_options.adoc[]
43 include::man/common_footer.adoc[]