summaryrefslogtreecommitdiff
path: root/cloudinit
diff options
context:
space:
mode:
authorKsenija Stanojevic <KsenijaS@users.noreply.github.com>2021-12-09 14:45:37 -0800
committerGitHub <noreply@github.com>2021-12-09 16:45:37 -0600
commitb591e9dba6c85f3934bc309032c3e436b8dcb3ac (patch)
tree2b2bb5d83009d147e9307f61fde6d38fd0441ca8 /cloudinit
parent8df8f43a2769b8f743ce127f2bb1d2a892b19d68 (diff)
downloadvyos-cloud-init-b591e9dba6c85f3934bc309032c3e436b8dcb3ac.tar.gz
vyos-cloud-init-b591e9dba6c85f3934bc309032c3e436b8dcb3ac.zip
Improve error log message when mount failed (#1140)
Diffstat (limited to 'cloudinit')
-rw-r--r--cloudinit/util.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/cloudinit/util.py b/cloudinit/util.py
index cad087a1..d7208f11 100644
--- a/cloudinit/util.py
+++ b/cloudinit/util.py
@@ -1752,8 +1752,10 @@ def mount_cb(device, callback, data=None, mtype=None,
mountpoint = tmpd
break
except (IOError, OSError) as exc:
- LOG.debug("Failed mount of '%s' as '%s': %s",
- device, mtype, exc)
+ LOG.debug("Failed to mount device: '%s' with type: '%s' "
+ "using mount command: '%s', "
+ "which caused exception: %s",
+ device, mtype, ' '.join(mountcmd), exc)
failure_reason = exc
if not mountpoint:
raise MountFailedError("Failed mounting %s to %s due to: %s" %