Expose persistent serial numbers for local disks
A guest querying the hardware properties of a disk will currently see a serial number for a volume, but not for a local disk (local root, ephemeral, or swap). This feature will add a persistent serial number for local disks.
Blueprint information
- Status:
- Started
- Approver:
- Matt Riedemann
- Priority:
- Low
- Drafter:
- Matthew Booth
- Direction:
- Needs approval
- Assignee:
- Matthew Booth
- Definition:
- Pending Approval
- Series goal:
- None
- Implementation:
- Needs Code Review
- Milestone target:
- None
- Started by
- Matt Riedemann
- Completed by
Related branches
Related bugs
Sprints
Whiteboard
Serial numbers for volumes are simply the volume id. Local disks don't have a unique id, so we will use the SHA256 of '<instance-
We could localise the change to the libvirt driver, but to make the logic available to all drivers we will add a serial number to DriverBlockDevice.
An added complication is that for legacy reasons we don't pass a DriverBlockDevice for a local root disk to the driver. We will add this to the block_device_info dict as 'root'.
The change is local to the compute host, and has no RPC or upgrade implications. Newly created, rebooted, or migrated guests will automatically get serial numbers for their local disks.
Gerrit topic: https:/
Addressed by: https:/
Add serial numbers for local disks
Approved for Queens. -- mriedem 20171019
Gerrit topic: https:/
Addressed by: https:/
Remove unused global variables
Addressed by: https:/
Add uuid field to BlockDeviceMapping
Addressed by: https:/
DriverBlock
Gerrit topic: https:/
Addressed by: https:/
Add uuid column to BlockDeviceMapping
Addressed by: https:/
Make BlockDeviceMapping object support uuid
Addressed by: https:/
Add an online migration for BDM.uuid
Addressed by: https:/
Give volume DriverBlockDevice classes a common prefix
Addressed by: https:/
Add DriverLocalImag
Addressed by: https:/
Expose driver_block_device fields as attributes
Addressed by: https:/
Pass DriverBlockDevice to driver.
Addressed by: https:/
Rename block_device_
Addressed by: https:/
Add local_root to block_device_info
Addressed by: https:/
Expose BDM uuid to drivers
Addressed by: https:/
Use real block_device_info data in test_blockinfo
Addressed by: https:/
Fix libvirt volume tests passing invalid disk_info
Addressed by: https:/
Pass disk_info dict to libvirt_info
Addressed by: https:/
Local disk serial numbers for the libvirt driver
Addressed by: https:/
Add test for assignment of uuid to a deleted BDM
Addressed by: https:/
Expose volume host type and path independent of libvirt config
Addressed by: https:/
Don't generate fake disk_info in swap_volume
Addressed by: https:/
Remove redundant swap_volume tests
Sorry but we're now past feature freeze for Queens. Please re-propose the spec for Rocky and we'll try to get this merged early in the first milestone. -- mriedem 20180126
Addressed by: https:/
Add serial numbers for local disks
Re-approved for Rocky. -- mriedem 20180327
Addressed by: https:/
Rename block_device_
We're past feature freeze for Rocky, so this must be deferred. Please re-propose the spec for Stein if you'd like to work on it next cycle. -- melwitt 20180727
Addressed by: https:/
Add serial numbers for local disks
Re-approved for Stein. -- mriedem 20180906
This did not complete in the Stein release so I am deferring to the Train release. Remember to re-propose the spec for Train as necessary: https:/
Gerrit topic: https:/
Addressed by: https:/
Give volume DriverBlockDevice classes a common prefix
Deferring this out of Train since it wasn't re-approved and we're about 2 weeks from feature freeze. -- mriedem 20190829
Work Items
Work items:
Add a DriverBlockDevice class for local disks from image: TODO
Add 'root' to block_device_info: TODO
Add 'serial' to all DriverBlockDevice classes: TODO
Expose serial for local disks in libvirt driver: TODO