Azure temporary disk not present for instance type

Bug #1901011 reported by Terry Cain on 2020-10-22
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
cloud-init
Medium
Johnson Shi

Bug Description

Cloud Provider: Azure
Instance type: Dsv4

The new Dv4, Dsv4, Ev4, and Esv4 instance types don't come with a temporary disk at /dev/disk/cloud/azure_resource

So when I create/reboot one of these new instances I get longer reboot times as cloud-init is waiting 2 minutes for this disk path to appear.
Looks like the function that looks for the disk is here - https://git.launchpad.net/cloud-init/tree/cloudinit/sources/DataSourceAzure.py?id=93cebe009d116230850c770227e9ead5c490c0d0#n888

Log snippet:
```
2020-10-21 12:34:43,120 - handlers.py[DEBUG]: start: init-network/activate-datasource: activating datasource
2020-10-21 12:34:43,120 - handlers.py[DEBUG]: start: azure-ds/activate: activate
2020-10-21 12:34:43,120 - handlers.py[DEBUG]: start: azure-ds/address_ephemeral_resize: address_ephemeral_resize
2020-10-21 12:34:43,120 - handlers.py[DEBUG]: start: azure-ds/wait-for-ephemeral-disk: wait for ephemeral disk
2020-10-21 12:34:43,121 - util.py[DEBUG]: Azure ephemeral disk: Waiting up to 120 seconds for the following files: ['/dev/disk/cloud/azure_resource']
2020-10-21 12:36:43,160 - util.py[DEBUG]: Azure ephemeral disk: Still missing files after 120 seconds: {'/dev/disk/cloud/azure_resource'}
2020-10-21 12:36:43,161 - DataSourceAzure.py[WARNING]: ephemeral device '/dev/disk/cloud/azure_resource' did not appear after 120 seconds.
2020-10-21 12:36:43,161 - handlers.py[DEBUG]: finish: azure-ds/wait-for-ephemeral-disk: SUCCESS: wait for ephemeral disk
2020-10-21 12:36:43,161 - handlers.py[DEBUG]: finish: azure-ds/address_ephemeral_resize: SUCCESS: address_ephemeral_resize
```

I've looked in the instance metadata between a Dsv4 and Dsv3 and there is nothing to indicate if this temporary disk will be present.

More than happy to make a patch to look for the instance type and skip the call if its not needed.

Additional info:

Azure temporary disk VM list -
https://docs.microsoft.com/en-us/azure/virtual-machines/azure-vms-no-temp-disk#what-are-the-differences-between-these-new-vm-sizes-and-the-general-purpose-dv3dsv3-or-the-memory-optimized-ev3esv3-vm-sizes-that-i-am-used-to

Chris Pressland (cpressland) wrote :

How's that for timing, I was literally going to raise this today. +1 and all that.

Johnson Shi (johnsonshi) wrote :

We're (MSFT) taking a look at this right now and seeing if anything can be done.

James Falcon (falcojr) on 2020-10-28
Changed in cloud-init:
status: New → Triaged
importance: Undecided → Medium
assignee: nobody → Johnson Shi (johnsonshi)
Johnson Shi (johnsonshi) wrote :

WIP PR addressing this issue at https://github.com/canonical/cloud-init/pull/716

Changed in cloud-init:
milestone: none → 21.1
Eduardo Otubo (otubo) wrote :

This bug is believed to be fixed in cloud-init in version 21.1. If this is still a problem for you, please make a comment and set the state back to New

Thank you.

Changed in cloud-init:
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.