diff options
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/live | 7 | ||||
| -rw-r--r-- | scripts/live-helpers | 20 |
2 files changed, 26 insertions, 1 deletions
diff --git a/scripts/live b/scripts/live index 8db6b80..0280edd 100755 --- a/scripts/live +++ b/scripts/live @@ -1171,7 +1171,7 @@ find_livefs () fi # or do the scan of block devices - for sysblock in $(echo /sys/block/* | tr ' ' '\n' | grep -v loop | grep -v ram) + for sysblock in $(echo /sys/block/* | tr ' ' '\n' | grep -v loop | grep -v ram | grep -v 'dm-') do devname=$(sys2dev "${sysblock}") fstype=$(get_fstype "${devname}") @@ -1218,6 +1218,11 @@ set_usplash_timeout () mountroot () { + + if [ -x /scripts/local-top/cryptroot ]; then + /scripts/local-top/cryptroot + fi + exec 6>&1 exec 7>&2 exec > live.log diff --git a/scripts/live-helpers b/scripts/live-helpers index 504a3f4..807553a 100644 --- a/scripts/live-helpers +++ b/scripts/live-helpers @@ -34,6 +34,13 @@ get_fstype () local FSTYPE local FSSIZE + # fstype misreports LUKS devices + is_luks "${1}" + if [ $? -eq 0 ]; then + /lib/udev/vol_id -t ${1} 2>/dev/null + return + fi + eval $(fstype < ${1}) if [ "${FSTYPE}" != "unknown" ] @@ -306,3 +313,16 @@ get_mac () echo ${mac} } + +is_luks() +{ + devname="${1}" + if [ -x /sbin/cryptsetup ] + then + /sbin/cryptsetup isLuks "${devname}" 2>/dev/null + return $? + else + return 1 + fi + +} |
