I decided to reformat my hard drive and install a clean copy of the newly released Ubuntu 14.04.2 with full disk encryption (incl. LVM) and I chose a strong password with special characters which works out fine every single time I play around with it during the Ubuntu installation.

However once the installation was finished and my desktop computer rebooted for the first time, it was all black, not going anywhere passed the motherboard boot screen?

I hit the "reset" button on my case to double check, rebooted once more, only this time I was greeted with an GNU GRUB menu with four options and I chose "Ubuntu", then the much anticipated Ubuntu-logo and a text telling me to "enter passphrase" in order for me to unlock my disk with my chosen encryption password came up; however despite knowing that I had typed the correct password at least a hundred times (checked if caps lock or numpad was causing this, which it wasn’t) it still refuses to decrypt on login with the following error message: "cryptsetup: cryptsetup failed, bad password or options?".

What's going on here? Why is it that my password work every single time when I play around with it during the installation, but whenever I try to actually decrypt and login to Ubuntu it fails?

Are there any characters (super characters) that aren't allowed in the encryption password or could this be a bug because of my Swedish keyboard layout?


Unfortunately, the keyboard layout DOES matter. :(

On bootup, you start with the US Keyboard layout. As your filesystem is decrypted (entering the correct password), any settings changing keyboard layout (such as you changing it to Swedish Keyboard Layout) will be applied.

What I suggest is the following:

  1. Do a fresh install again. (sorry)
  2. When installing Ubuntu, just leave the keyboard layout alone (leave it to US).
  3. AFTER successfully installing Ubuntu and decrypting your filesystem on the first boot, THEN you can change the keyboard layout.

See this Unix Stack Exchange post for more details.


I had this same problem as I had written my password at setup with my Portuguese keyboard thinking I'd be writing it with the Portuguese keyboard layout; since during the setup the keyboard layout is in US my password turned out to be something else. The way I was able to decrypt the disk was by changing the layout on another computer to US and writing my password as if the Portuguese layout was the one in use, this writes up the password as it was stored.

For example, for me the key combinations for | generated a ~.

After writing the password with the US Keyboard Layout as if I was using my layout I get the character sequence I have to write to decrypt the disk and it's solved.


I had this problem too and while it still exists for me I have identified a workaround that enables my system to boot. My issue was to do with cryptsetup not accepting my password. This prevents me for booting and fixing system issues.

Turns out that my password included a special character '@' as in P@ssword. At the prompt pressing RIGHT SHIFT and key 2 does not generate a '@' instead a '2' is generated. This can be confirmed by switching over to another TTY and typing in the password (CTRL + ALT + F1). I noted that using LEFT SHIFT and key 2 generated the '@' control character. Thus if LEFT SHIFT is used in complex password it will be typed correctly and cryptsetup will be able to decrypt the volume.

Note the Ubuntu install program rates user password with Poor, Fair, or Good thus encouraging the use of special characters leading to this scenario in the ubuntu recovery mode.