I'm using loop-aes for encryption, and experiencing similar issues when
/etc/init.d/mountall.sh attempts to mount the encrypted volumes listed
in /etc/fstab with loop= and encryption= options.

Adding "console owner" to /etc/event.d/rcS fixed that, but I also found
that the password was echoed to the screen unless I removed "splash"
from the boot command line.

Instead, I added the following to do_start() in /etc/init.d/mountall.sh,
based on the suggestions above:

        local stdin=`readlink /proc/self/fd/0`
        if [ "${stdin#/dev/null}" != "$stdin" ]; then
                exec /usr/bin/openvt -s -w /etc/init.d/mountall.sh "$@"
        fi

This seems to work correctly with or without "splash". Note that I found
"openvt -s -w" to work better than "openvt -w -f -c `fgconsole`" in that
regard -- ie switching to a new console rather than using the current
one (which splash is potentially interfering with).

The ON_VT part doesn't seem to be necessary, since once we're running on
a VT, stdin will be /dev/tty<something> and the "if" block will be
skipped anyway.


Another point to note is that /usr might not be mounted yet when these scripts 
run, if it's not part of the root fs -- in which case openvt won't be available.


** Also affects: loop-aes-utils (Ubuntu)
   Importance: Undecided
       Status: Unconfirmed

-- 
Upstart doesn't activate luks volumes in cryptsetup
https://launchpad.net/bugs/62751

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to