Comment 33 for bug 444563

Revision history for this message
Wessel Dankers (wsl) wrote :

I think I got it. In /lib/udev/rules.d/65-dmsetup.rules there's this line:

ENV{DM_UUID}=="LVM-*", PROGRAM="/bin/sh -c 'set `lvm lvdisplay -C -o vg_name,lv_name --noheadings /dev/$name` ; echo $1/$2'", SYMLINK+="$result"

which is a particularly fragile piece of shell script that doesn't do any error checking. Replacing it with:

ENV{DM_UUID}=="LVM-*", PROGRAM="/bin/sh -ec 'link=$(lvm lvdisplay -C -o vg_name,lv_name --noheadings /dev/$name); set -- $link; echo $1/$2'", SYMLINK+="$result"

will fix the errors and warnings. No more empty or bogus symlinks.