VMware-to-KVM Resize Support for Instances Using Ephemeral Root Disks - #652
Draft
anokfireball wants to merge 7 commits into
Draft
VMware-to-KVM Resize Support for Instances Using Ephemeral Root Disks#652anokfireball wants to merge 7 commits into
anokfireball wants to merge 7 commits into
Conversation
Cross-HV resize can use an image/local root only after conductor has a chance to convert it to BFV. The old utility-level BFV check rejected those instances before scheduling, so validate the root BDM in MigrationTask instead. Allow image/local and */volume roots. Reject blank/local, missing root BDMs, and cross-cell selections because the prep and abort RPCs run against the source cell. Change-Id: Ib66d7de2da1865437b0db9a2127cfd928c3ab073
KVM cannot boot a Nova-managed VMDK from a VMware ephemeral datastore, so an image/local root must be imported into Cinder before the existing BFV resize path runs. The conductor prep step powers off the source VM, detaches the root VMDK, imports it with manage_existing using source-name, size_gb, and optional source-id, creates a reserved attachment, and mutates the root BDM to volume-backed. The conversion is permanent across revert. Abort is only safe before Cinder relocates the disk; later code reports that through structured safe_to_abort metadata. Change-Id: I7e991b5da895b059a5b9f459c44ad3e4d5f93c3d
Cross-HV conversion needs a reversible source-side prep step around Cinder manage_existing. Add VMwareVMOps prep and abort helpers that detach the root VMDK and, when abort is safe, attach it back. Prep discovers the root disk before changing power state, accepts already shutdown guests, and powers the VM back on after detach failure only when Nova powered it off in this attempt. It returns the VMDK path, size, Cinder host, rollback device data, and optional FCD id needed by conductor. Abort is retry-tolerant: it skips reattach if the disk is already present and skips power-on if the VM is already running. Change-Id: I5b8057f8797d714c1e33f782a3b9f72a47f50407
Expose source-side prep and abort through compute RPC so conductor can drive VMware conversion without reaching into virt code. Bump compute RPC to 6.2.1, add driver stubs, delegate the VMware driver to VMops, and leave unsupported drivers on NotImplementedError. prep_cross_hv_conversion preserves DiskNotFound and InstanceInvalidState as expected RPC exceptions; abort failures remain unexpected and surface to the caller. Change-Id: I277618423e1fe881e56a36cd277b713bcc7a6cda
[cross_hv] fcd_volume_type has no default because the VMware FCD volume type is deployment-specific. Missing config must fail before conductor powers off or detaches the source VM. Register the [cross_hv] group, add manage_existing_timeout with a 600 second default, and validate fcd_volume_type before VMware prep. Change-Id: Icbda4fbc2760e26f495bcc161197121727a1084a
Add the Nova-side Cinder manage_existing wrapper used by cross-HV root disk conversion. It uses the request context, submits volumes.manage(), polls Cinder every 5 seconds until available, and uses [cross_hv] manage_existing_timeout by default. CrossHvVolumeManageFailed carries safe_to_abort, volume_id, and volume_status so conductor can decide whether VMware prep may be rolled back. Synchronous Cinder rejection, client connection errors, and Keystone discovery failures are safe to abort because Cinder has not accepted the disk. Polling treats error as safe, error_managing as unsafe, and timeout as unsafe unless the latest state is error. Relax translate_volume_exception so this keyword-based API can run before a Cinder volume id exists while preserving NotFound mapping for existing volume calls. Change-Id: Ie375421d381ed7dcfca5992d5cde261c02bfb84e
Keep abort orchestration in conductor, where the VMware prep payload is still available. manage_existing now reports structured failure metadata only. On CrossHvVolumeManageFailed with safe_to_abort=True, call abort_cross_hv_conversion with the original prep response and re-raise the manage failure. If abort itself fails, log that failure and preserve the manage exception. Unsafe manage failures and generic exceptions do not abort. Remove the temporary rollback argument from the volume API call. Change-Id: I4260e6521daf3faf25c1629c921c9528c848eb70
anokfireball
force-pushed
the
kvmotion-eph-support
branch
from
July 31, 2026 11:28
1e40dce to
81fb3c1
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.