[systemd-devel] Question about encrypted devices.
lennart at poettering.net
Fri Mar 22 16:19:13 PDT 2013
On Tue, 19.03.13 11:55, Mathieu Cassard (cassard.mathieu at gmail.com) wrote:
> I'm a quit new user of systemd. Hope this is the right place to ask
> for help...
> I am trying to mount an encrypted disk at boot.
> I am working with a customized distribution & kernel (using ptxdist).
> In my fstab :
> /dev/mapper/c1 /opt ext4 defaults 0 0
> In my crypttab
> c1 /dev/opt none luks
This looks like breakage in your LVM/DM userspace. What distro is this?
Most likely LVM/DM wasn't built with udev enabled.
> And during boot the system timeout waiting for dev-mapper-c1.device :
> Jan 01 00:00:09 TestBox systemd: Mounted /var/log directory.
> Jan 01 00:00:11 TestBox systemd-cryptsetup: Set cipher aes, mode xts-plain
> Jan 01 00:00:13 TestBox systemd: Started Cryptography Setup for c1.
> Jan 01 00:01:35 TestBox systemd: Job dev-mapper-c1.device/start timed out.
> Jan 01 00:01:35 TestBox systemd: Timed out waiting for device dev-mapper-c1
> Jan 01 00:01:35 TestBox systemd-journal: Forwarding to syslog missed 34 me
> Jan 01 00:01:35 TestBox systemd: Dependency failed for /opt.
> If I comment c1 in the fstab, the sytem boot ok, /dev/mapper/c1 is
> present and I can manually do :
> mount /dev/mapper/c1 /opt
> [ 84.052445] EXT4-fs (dm-0): recovery complete
> [ 84.058232] EXT4-fs (dm-0): mounted filesystem with ordered data
> mode. Opts: (null)
> udevadm info /dev/mapper/c1
> P: /devices/virtual/block/dm-0
> N: dm-0
> E: DEVNAME=/dev/dm-0
> E: DEVPATH=/devices/virtual/block/dm-0
> E: DEVTYPE=disk
> E: MAJOR=254
> E: MINOR=0
> E: SUBSYSTEM=block
> E: TAGS=:systemd:
> E: UDEV_LOG=3
> E: USEC_INITIALIZED=45372516
> Any idea why systemd keep waiting for /dev/mapper/c1 ? Or where to
> start looking ?
Well, the udevadm output above shows that the name "c1" is not attached
to the udev device, which means systemd won't pick it up.
But anyway, this is a DM issue, please contact the DM folks.
Lennart Poettering - Red Hat, Inc.
More information about the systemd-devel