Juju storage-get may report incorrect device with OpenStack provider
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical Juju |
Fix Released
|
High
|
Harry Pidcock |
Bug Description
Juju storage-get is reporting the incorrect device name for a volume mount with the OpenStack provider.
This has been seen on stable, candidate and edge. It is intermittent but consistent enough that it effects OpenStack charm engeineering CI, requiring retries unnecessarily.
Steps to reproduce:
Model snippet:
ceph-osd:
charm: ceph-osd
num_units: 3
storage:
$ openstack volume list
+------
| ID | Name | Status | Size | Attached to |
+------
| 657de65d-
| 6004573f-
| 1d083c8d-
On a unit where the mapping is disordered. Note in the bellow case vdc is the recently attached volume and vdd is the swap device. But storage-get reports the volume is at /dev/vdd.
root@juju-
kind: block
location: /dev/vdd
root@juju-
Model: Virtio Block Device (virtblk)
Disk /dev/vdd: 4295MB
Sector size (logical/physical): 512B/512B
Partition Table: loop
Disk Flags:
Number Start End Size File system Flags
1 0.00B 4295MB 4295MB linux-swap(v1)
Model: Virtio Block Device (virtblk)
Disk /dev/vdb: 16.1GB
Sector size (logical/physical): 512B/512B
Partition Table: loop
Disk Flags:
Number Start End Size File system Flags
1 0.00B 16.1GB 16.1GB ext4
Error: /dev/vdc: unrecognised disk label
Model: Virtio Block Device (virtblk)
Disk /dev/vdc: 10.7GB
Sector size (logical/physical): 512B/512B
Partition Table: unknown
Disk Flags:
Model: Virtio Block Device (virtblk)
Disk /dev/vda: 16.1GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags:
Number Start End Size File system Name Flags
14 1049kB 5243kB 4194kB bios_grub
15 5243kB 116MB 111MB fat32 boot, esp
1 116MB 16.1GB 16.0GB ext4
tags: | added: uosci |
Changed in juju: | |
milestone: | none → 2.7-beta1 |
status: | New → Triaged |
Changed in juju: | |
assignee: | nobody → Harry Pidcock (hpidcock) |
Changed in juju: | |
status: | Triaged → In Progress |
Changed in juju: | |
status: | In Progress → Fix Committed |
Changed in juju: | |
status: | Fix Committed → Fix Released |
This seems suspicious:
Error: /dev/vdc: unrecognised disk label
We do want to make sure that we have the right "chain of custody" from what we requested to be provisioned from the underlying provider, and how that actually gets mounted on the machine. Openstack is clearly telling us that it put the storage we requested at /dev/vdd and we're passing that information on to the charm.
Offhand it feels like it would be an Openstack bug if it is telling us "on the instance I just created, you should expect this storage to be available at /dev/XXX" but the storage isn't actually there.
Now if Openstack was just telling us "your device ID is ABCDEF-123-456" and we're looking at mounted device labels and not lining them up correctly, that would be our bug.
But given your "openstack volume list" command above, it does seem relevant.
I wonder if the issue is that somehow the device isn't getting the right label, and thus whatever fstab entry that tells it where it should be mounted isn't matching.