cloud-init does not recognize (and mount) ephemeral partition on KVM
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cloud-init (Ubuntu) |
Expired
|
High
|
Unassigned |
Bug Description
When a KVM-based cloud instance is launched with ephemeral volume or swap space on a partition of the root disk (e.g., /dev/vda2 and /dev/vda3), the partition is ignored and remains unmounted. In the log this looks as follows:
Aug 12 19:29:45 euca-172-28-165-121 [CLOUDINIT] cc_mounts.
Aug 12 19:29:45 euca-172-28-165-121 [CLOUDINIT] DataSourceEc2.
Aug 12 19:29:45 euca-172-28-165-121 [CLOUDINIT] cc_mounts.
Aug 12 19:29:45 euca-172-28-165-121 [CLOUDINIT] cc_mounts.
Aug 12 19:29:45 euca-172-28-165-121 [CLOUDINIT] cc_mounts.
Aug 12 19:29:45 euca-172-28-165-121 [CLOUDINIT] cc_mounts.
Aug 12 19:29:45 euca-172-28-165-121 [CLOUDINIT] DataSourceEc2.
Aug 12 19:29:45 euca-172-28-165-121 [CLOUDINIT] cc_mounts.
Aug 12 19:29:45 euca-172-28-165-121 [CLOUDINIT] cc_mounts.
Aug 12 19:29:45 euca-172-28-165-121 [CLOUDINIT] cc_mounts.
Earlier versions of cloud-init (e.g., one in Ubuntu 12.04) were able to use such partitions, but latter versions (e.g., one in Ubuntu 14.04) are not. It appears that a check for the block device's presence in /sys/block was added between those two versions and it is causing the failure.
This check succeeds on AWS with paravirtualized instances, where what look like partitions (/dev/xvda1, /dev/xvda2, /dev/xvda3) of a disk (/dev/xvda), are actually separate, unrelated Xen-provided block devices, each with its own entry in /sys/block. When root, ephemeral, and swap block devices are actually partitions of one KVM disk (/dev/vda), they do not end up in /sys/block.
This was discovered in a Eucalyptus installation: https:/
tags: | added: regression-release trusty |
Changed in cloud-init (Ubuntu): | |
importance: | Undecided → High |
Sorry for late triage... if this is still an issue, please re-open and run 'cloud-init collect-logs' on the image.
Thanks.
Scott