Installing GoldenDog on a LUKS Encrypted Partition
This guide provides a step-by-step walkthrough for installing GoldenDog on a pre-existing LUKS encrypted partition. This is a manual process that requires using the terminal during the installation.
This process involves manual disk partitioning and terminal commands. There are no guarantees; proceed at your own risk. Ensure you have a backup of your data.
Manual Partitioning
The Debian installer might not detect encrypted partitions automatically. Follow these steps to prepare the disk:
- In the Partition disks screen, select Manual.
- Select the encrypted partition (e.g.,
/dev/sda6) or any other you intend to use. - Press Enter and under How to use this partition:, select physical volume for encryption. This will load the necessary modules and programs.
- Go back to How to use this partition: and select do not use the partition, then choose Done setting up the partition.
Opening the Encrypted Volume
-
Open a console by pressing
Ctrl+Alt+F2. -
Run the following command to open the partition (replace
sda6with your partition):cryptsetup luksOpen /dev/sda6 volume_name -
Return to the installer by pressing
Ctrl+Alt+F5(orF1/F7depending on the system). -
Click the Go Back button.
Configuring the Volumes
- Select Detect disks and click Continue. The encrypted volume should now be visible.
- Configure your partitions for
/(root) andswapas desired, but do not touch the encrypted partition/dev/sda6directly yet. - Select the partition inside the encrypted volume, go to How to use this partition: and choose physical volume for encryption.
- IMPORTANT: When asked to Erase data, select NO.
- Choose Done setting up the partition.
- Select Finish partitioning and write changes to disk. Ensure the encrypted partition is NOT marked for formatting.
Final System Configuration
Before the installation finishes, we need to ensure the system knows how to mount the encrypted volume.
-
Switch back to the console with
Ctrl+Alt+F2. -
Get the UUID of the encrypted partition:
cryptsetup luksUUID /dev/sda6Note down this UUID.
-
Edit the
fstabof the new system:nano /target/etc/fstabAdd the following line (adjusting for your mount point, e.g.,
/home):/dev/mapper/home-cifrado /home ext4 defaults 0 2 -
Edit the
crypttabof the new system:nano /target/etc/crypttabAdd the following line:
home-cifrado UUID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx none luksReplace
xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxxwith the UUID you obtained earlier. -
Return to the installer, finish the installation, and install the bootloader.
-
Restart your system. You will be prompted for the password to mount the encrypted volume.
Document Written by noname from the Debian Argentina community