change the key for LUKS - SSD LVM
Hi,
I cannot change the key for LUKS - SSD LVM on Fedora.
fdisk -l
Device Start End Sectors Size Type
/dev/nvme0n1p1 2048 411647 409600 200M EFI System
/dev/nvme0n1p2 411648 2508799 2097152 1G Linux filesystem
/dev/nvme0n1p3 2508800 1000214527 997705728 475.8G Linux LVM
tried:
cryptsetup luksChangeKey /dev/nvme0n1p3
the output:
Device /dev/nvme0n1p3 is not a valid LUKS device.
My old machine the command works fine!
Thank you
Updated:
ls /dev/mapper
control luks-188a56cb-34fc-4bd9-b73c-0c165eb25cda
fedora_code-00 luks-3dc0d6b0-0f20-47ac-bebb-82b782ba7e67
fedora_code-01 luks-ca68facb-da5b-45a6-b110-d2cb53a99364
fedora_code-02
Updated:
cryptsetup luksAddKey /dev/mapper/luks-188a56cb-34fc-4bd9-b73c-0c165eb25cda
Device /dev/mapper/luks-188a56cb-34fc-4bd9-b73c-0c165eb25cda is not a valid LUKS device.
That command works fine with an actual luks device. Please post the output of
ls /dev/mapper
I Updated the question with the output-thanks
You can now see your crypted partitions:
/dev/mapper/luks-XXXX
. It's recommended adding a new key 1st and then remove the old one.Could you please explain more? how could I change the key now?
thank you
Apply the command in your original question to your luks partitions i.e.
/dev/mapper/luks-XXXX
. I'd suggest using luksAddKey instead of luksChangeKey