X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=scripts%2Flive-helpers;h=6edd51cd189bd7a660388a9f30291b0662f987dd;hb=6d5c38f8a3584268700602b6119572f5fb2be2fb;hp=84d460bce61440622630c002877309ee707f5a36;hpb=45a44dfbaec9d819567afa12238d9181dfbff5e6;p=live-boot-grml.git diff --git a/scripts/live-helpers b/scripts/live-helpers index 84d460b..6edd51c 100644 --- a/scripts/live-helpers +++ b/scripts/live-helpers @@ -287,7 +287,8 @@ try_mount () then fstype=$(get_fstype "${dev}") fi - mount -t "${fstype}" -o "${opts}" "${dev}" "${mountp}" || panic "Cannot mount ${dev} on ${mountp}, fstype=${fstype}, options=${opts}" + mount -t "${fstype}" -o "${opts}" "${dev}" "${mountp}" || \ + ( echo "SKIPPING: Cannot mount ${dev} on ${mountp}, fstype=${fstype}, options=${opts}" > live.log && return 0 ) fi } @@ -376,17 +377,15 @@ find_cow_device () case "$(get_fstype ${devname})" in vfat|ext2|ext3|ext4|jffs2) mkdir -p "${cow_backing}" - if ! try_mount "${devname}" "${cow_backing}" "rw" + if try_mount "${devname}" "${cow_backing}" "rw" then - break - fi - - if [ -f "${pers_fpath}" ] - then - echo $(setup_loop "${pers_fpath}" "loop" "/sys/block/loop*") - return 0 - else - umount ${cow_backing} + if [ -f "${pers_fpath}" ] + then + echo $(setup_loop "${pers_fpath}" "loop" "/sys/block/loop*") + return 0 + else + umount ${cow_backing} > /dev/null 2>&1 || true + fi fi ;; *)