log result from mount command
authorIvo De Decker <ivo.dedecker@ugent.be>
Sun, 14 Jul 2013 11:26:43 +0000 (13:26 +0200)
committerColin Watson <cjwatson@debian.org>
Thu, 19 Jan 2017 21:01:46 +0000 (21:01 +0000)
linux-boot-probes/common/50mounted-tests
os-probes/common/50mounted-tests

index 992af2b..fc25dbf 100755 (executable)
@@ -57,9 +57,12 @@ if type grub-mount >/dev/null 2>&1 && \
 else
        ro_partition "$partition"
        for type in $types; do
-               if mount -o ro -t "$type" "$partition" "$tmpmnt" 2>/dev/null; then
+               if mountinfo=`mount -o ro -t "$type" "$partition" "$tmpmnt" 2>&1`; then
+                       debug "mounted as $type filesystem"
                        mounted=1
                        break
+               else
+                       debug "mounting $partition as $type failed: $mountinfo"
                fi
        done
 fi
index 52a5441..c02397e 100755 (executable)
@@ -69,10 +69,12 @@ if type grub-mount >/dev/null 2>&1 && \
 else
        ro_partition "$partition"
        for type in $types $delaytypes; do
-               if mount -o ro -t "$type" "$partition" "$tmpmnt" 2>/dev/null; then
+               if mountinfo=`mount -o ro -t "$type" "$partition" "$tmpmnt" 2>&1`; then
                        debug "mounted as $type filesystem"
                        mounted=1
                        break
+               else
+                       debug "mounting $partition as $type failed: $mountinfo"
                fi
        done
 fi