Skip to content

Azure temporary disk not present for instance type #3797

@ubuntu-server-builder

Description

@ubuntu-server-builder

This bug was originally filed in Launchpad as LP: #1901011

Launchpad details
affected_projects = []
assignee = johnsonshi
assignee_name = Johnson Shi
date_closed = 2021-02-23T19:26:20.411839+00:00
date_created = 2020-10-22T12:21:02.272972+00:00
date_fix_committed = 2021-02-23T19:26:20.411839+00:00
date_fix_released = 2021-02-23T19:26:20.411839+00:00
id = 1901011
importance = medium
is_complete = True
lp_url = https://bugs.launchpad.net/cloud-init/+bug/1901011
milestone = 21.1
owner = terrz
owner_name = Terry Cain
private = False
status = fix_released
submitter = terrz
submitter_name = Terry Cain
tags = []
duplicates = []

Launchpad user Terry Cain(terrz) wrote on 2020-10-22T12:21:02.272972+00:00

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    launchpadMigrated from Launchpad

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions