Comment 7 for bug 1374115

trialotto (trialotto) wrote :

@Scott (and everyone else),

It has been a while since visiting this launchpad and/or since doing some decent testing.

Nevertheless, I recall correctly, there is this option (also discussed on this launchpad) to work with partitions and disk setups on Azure VMs: just inject some custom data.

The custom data option can be used to define cloud-config settings and hence partitions and so on.

Daniel Watkins has created a Wiki page, based upon the topic thread somewhere in this launchpad.

The page can be found at: https://wiki.ubuntu.com/AzureSwapPartitions

However, note that the information provided on that page is not really up to date and, moreover, it sometimes does not work as expected and/or the instructions are not entirely correct.

Just view the page as some introduction.

@Scott, with respect to these lines

"One path to this would be to change the azure datasource to read:
 Datasource:
   Azure:
    cloud_config:
      disk_setup: ...
      fs_setup: ...

Then the datasource check to see if there were values in the passed-in ds_cfg, and use those instead of its BUILTIN_CLOUD_CONFIG if there were.

That could work, but without further thinking I dont know oif it would suffice. The datasource object is generally pretty static , and cloud-init might not re-read it on second boot (after the user had configured the new settings)."

one can state that

- it is not strictly necessary to use the "Datasource" stanza, (and)

- cloud-config settings, injected via custom data, will suffice (with some minor exceptions), (and)

- issues can still occur on Azure VMs, since there is this nasty habit of creating a NTFS volume at stop/start sequences, which habit is entirely related to some lines of odd code in the relevant Azure scripts (and I am pretty sure that a patch has not been created until now)

In general, read all of the above with some caution, it has been a while ago for me.

Regards......