/lib/rcscripts/addons/dm-crypt-start.sh contains a check whether the mount point for a target is found before post_mount is executed. The failure is noted, but post_mount is executed nonetheless. This is in no way serious, but produces extra error messages when post_mount causes errors because of the missing mount point. Suggested fix: return (or exit with appropriate eend?) after printing the message. Reproducible: Always Steps to Reproduce: For me, running into this error was caused by mounting my dm-crypt partitions by label. In /etc/fstab, I have LABEL=tmp /tmp ext2 defaults,noatime,errors=remount-ro 0 2 For some reason, /proc/mounts says that /dev/dm-2 is mounted on /tmp instead of /dev/mapper/tmp. I don't know why this happens, and putting /dev/mapper/tmp in /etc/fstab fixed my problem. These steps are unrelated to the bug itself, but this is how I found it.
Created attachment 168696 [details, diff] Patch against 1.0.5-r1, which is the current stable.
/dev/dm-# should be a symlink to the actual /dev/mapper/NAME, so that shouldn't be an issue. Unless of course the script is not dereferencing symlinks properly.
I'm just thinking if someone might not want to mount the block device via fstab, but do some special custom mounting in post_mount.
should be all set now in the tree; thanks for the report! Commit message: Delete old dm_crypt_execute_localmount hook as no one uses it anymore http://sources.gentoo.org/sys-fs/cryptsetup/files/1.5.1-dmcrypt.rc?r1=1.6&r2=1.7