diff --git a/debian/cloud-init.postinst b/debian/cloud-init.postinst
index b33e7b2..0c8429e 100644
--- a/debian/cloud-init.postinst
+++ b/debian/cloud-init.postinst
@@ -246,14 +246,14 @@ fix_azure_upgrade_1611074() {
wmsg="WARN: $me failed."
wmsg="$wmsg Subsequent resize may not update ephemeral correctly."
- tmpf=$(mktemp "${TMPDIR:-/tmp/cloud-init-upgrade.XXXXXX}") || {
+ tmpf=$(mktemp "${TMPDIR:-/tmp}/cloud-init-upgrade.XXXXXX") || {
echo "$wmsg (mktemp failed with $?)" 1>&2
return 0;
}
awk '{
if ($4 !~ /x-systemd.requires/ && $4 ~ /comment=cloudconfig/) {
- sub(/comment=cloudconfig/, "x-systemd.requires,comment=cloudconfig")
+ sub(/comment=cloudconfig/, "x-systemd.requires=cloud-init.service,comment=cloudconfig")
}
printf("%s\n", $0)}' /etc/fstab > "$tmpf" || {
echo "$wmsg (awk reading of /etc/fstab failed with $?)" 1>&2