-   Slackware (
-   -   can't unlock luks home when booting (

gorillus 01-16-2012 03:46 PM

can't unlock luks home when booting
I set up a encrypted /home partition with:

cryptsetup -c aes-xts-plain -y -s 512 luksFormat /dev/sda1
My /etc/crypttab:

chome    /dev/sda1    none    luks,timeout=30
I also tried it with ASK instead of none (red this in an Arch-Forum)

My /etc/fstab:

/dev/sdb1    /    ext4    defaults,discard    1  1
/dev/mapper/chome  /home    ext4    defaults    1    2

The issue:

When I try to boot now it asks for the password, shows a message:

"Command failed: No key available with this passphrase"

and continues with booting (including mounting). I don't have even a second of time to enter the password. What is my mistake?

PS: Im using Slackware 13.37 on an GPT-Partition-table, cryptsetup 1.2.0. Unlocking manually works perfectly

GazL 01-16-2012 05:13 PM

Looks like a bug in rc.S to me. Unless I am misreading it cryptsetup never gets called when the third field is 'none' (except when the fourth also contains 'swap')

Change your crypttab to simply

chome /dev/sda1
and you should get 3 attempts at entering the passphrase.

I also noticed the luksFormat command you've shown and the crypttab lists a different device - I'll assume one or other was a typo)

gorillus 01-16-2012 05:20 PM

Thanks a lot! That works! It doesn't look that beauty, but it works...

Do you think I should write a bug report?

PS: Yes the first sda2 was a typo - Fixed

Alien Bob 01-16-2012 05:37 PM

Slackware's crypttab file does not follow the syntax of other distros. It has limited capabilities and is not documented other than by reading /etc/rc.d/rc.S or README_CRYPT.TXT.

Drom rc.S: "# A password field of 'none' indicates a line for swap"


gorillus 01-16-2012 05:39 PM

Thanks Eric! Didn't know that...

All times are GMT -5. The time now is 09:12 AM.