[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Passphrase prompt on boot

Short version: why doesn't my PC prompt for its passphrase on tty1?

Long version...

I have a 'stretch' PC used as a home server, so it doesn't normally
require a monitor and keyboard.  It has an encrypted filesystem and on
boot it asks for the passphrase with this prompt,

   Please unlock disk sda3_crypt:

To do without the monitor and keyboard, I changed my /etc/default/grub
to make the prompt appear on a serial console.  The non-blank,
non-comment lines are

   GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
   GRUB_CMDLINE_LINUX_DEFAULT="console=tty1 console=ttyS0,115200n8 quiet"
   GRUB_TERMINAL="console serial"
   GRUB_SERIAL_COMMAND="serial --speed=115200 --unit=0 --word=8 --parity=no --stop=1"

This works in that with a serial console attached, both the grub menu
and the 'Please unlock' prompt appear on the serial console, then I
can type the passphrase and boot continues normally.

Unfortunately it no longer works with an attached monitor and
keyboard.  The grub menu appears on the monitor, followed by boot
messages but then it stops with no prompt on the monitor.

At this point I can go to the serial console and supply the passphrase
there, then the messages resume on the monitor.  The monitor and
keyboard then work normally.

How to get the 'Please unlock' prompt on both the serial console and
on the local tty1?


Reply to: