projects
/
live-boot-grml.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merging casper 1.165.
[live-boot-grml.git]
/
scripts
/
live-helpers
diff --git
a/scripts/live-helpers
b/scripts/live-helpers
index
35fb8cf
..
84d460b
100644
(file)
--- a/
scripts/live-helpers
+++ b/
scripts/live-helpers
@@
-76,25
+76,17
@@
is_supported_fs ()
get_fstype ()
{
get_fstype ()
{
- local FSTYPE
- local FSSIZE
-
- # fstype misreports LUKS devices
- if is_luks "${1}"
- then
- /lib/udev/vol_id -t ${1} 2>/dev/null
- return
- fi
-
- eval $(fstype ${1} 2>/dev/null)
-
- if [ "${FSTYPE}" != "unknown" ]
+ # udev >=146-1 no longer provides vol_id:
+ if [ -x /lib/udev/vol_id ]
then
then
- echo ${FSTYPE}
- return 0
+ /lib/udev/vol_id -t ${1} 2>/dev/null
+ else
+ eval $(blkid -o udev "${1}")
+ if [ -n "$ID_FS_TYPE" ]
+ then
+ echo "${ID_FS_TYPE}"
+ fi
fi
fi
-
- /lib/udev/vol_id -t ${1} 2>/dev/null
}
where_is_mounted ()
}
where_is_mounted ()
@@
-328,7
+320,7
@@
find_cow_device ()
fi
# Checking for a luks device
fi
# Checking for a luks device
- if [ -e /sbin/cryptsetup ] && /sbin/cryptsetup isLuks ${devname}
+ if [
"${PERSISTENT}" = "cryptsetup" ] && [
-e /sbin/cryptsetup ] && /sbin/cryptsetup isLuks ${devname}
then
while true
do
then
while true
do
@@
-357,17
+349,28
@@
find_cow_device ()
done
fi
done
fi
- if [ "$(/lib/udev/vol_id -l ${devname} 2>/dev/null)" = "${pers_label}" ]
+ # udev >=146-1 no longer provides vol_id:
+ if [ -x /lib/udev/vol_id ]
then
then
- echo "${devname}"
- return 0
+ if [ "$(/lib/udev/vol_id -l ${devname} 2>/dev/null)" = "${pers_label}" ]
+ then
+ echo "${devname}"
+ return 0
+ fi
+ else
+ eval $(blkid -o udev "${devname}")
+ if [ "$ID_FS_LABEL" = "${pers_label}" ]
+ then
+ echo "${devname}"
+ return 0
+ fi
fi
if [ "${PERSISTENT}" = "nofiles" ]
then
# do not mount the device to find for image files
# just skip this
fi
if [ "${PERSISTENT}" = "nofiles" ]
then
# do not mount the device to find for image files
# just skip this
- break
+ continue
fi
case "$(get_fstype ${devname})" in
fi
case "$(get_fstype ${devname})" in