Comment 4 for bug 316607

Revision history for this message
Ulrich Lukas (ulrich-lukas) wrote :

Many thanks for your help Shiv!

I've applied the patch to vol_id and un_vol_id in /lib/cryptsetup/checks/.

Now, the automated creation of the swap device works again.

Looking at the scripts, your explanation seems absolutely plausible to me.

I've even cross-checked the detection by trying the following once with dev="/dev/null" and dev="/dev/sda1":
> vol_id=`/lib/udev/vol_id -t $dev 2>&1`
> pattern=`echo $dev | sed 's/\//\\\\\//g'`
> unknown=`/lib/udev/vol_id -t /dev/null 2>&1 | sed "s/\/dev\/null/$pattern/g"`
> if [ "$vol_id" != "$unknown" ] && [ "$vol_id" != "minix" ] && [ -z "$fs" ]; then echo FILESYSTEM DETECTED; fi

Seems to work...