Skip to content

Instantly share code, notes, and snippets.

@PetrGlad
Created November 20, 2016 14:34
Show Gist options
  • Save PetrGlad/6087799560b95a50fff1abd08cb1cd3b to your computer and use it in GitHub Desktop.
Save PetrGlad/6087799560b95a50fff1abd08cb1cd3b to your computer and use it in GitHub Desktop.
LUKS mount howto
# <requires root>
apt install cryptsetup
blkid | grep 'crypto_LUKS'
# encrypted device --> LUKS device mapper --> mapped device --> mount
# to mount
cryptsetup luksOpen /dev/sda1 my-decrypted-storage
mount -t auto /dev/mapper/my-decrypted-storage /media/storage
# to unomunt
umount /media/storage
cryptsetup luksClose my-decrypted-storage
@PetrGlad
Copy link
Author

To mount encrypted directory inside not encrypted filesystem use ecryptfs-* utilities.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment