Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow OVA import when origin is null and destination is block SD #776

Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,8 @@ private void adjustKVMDataForBlockSD() {
// can be larger then the actual size.
// Separately, setting the Volume Type to Preallocated avoids Sparseness when the
// Destination is a Block SD
if (getVm().getOrigin() == OriginType.KVM
// Allow this workaround for Vms that do not have origin set
if ((getVm().getOrigin() == null || getVm().getOrigin() == OriginType.KVM)
Copy link
Member

@ahadas ahadas Dec 11, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note that with the fix for #745, we shouldn't get VMs with origin == null anymore
but what's the scenario that you try to address here - you import an OVA that was not exported from oVirt, there's a block storage domain is used as a destination and the conversion fails due to lack of space?
raw volumes are already supposed to be set as preallocated in case of OVA import so this change is not clear to me. could you please elaborate on the issue? is it reproducible with oVirt 4.5?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the details. With the latest oVirt install that has the fix for #745, the issue was not reproducible. We can close this PR.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ack

&& getActionState() == CommandActionState.EXECUTE
&& getStorageDomain() != null
&& getStorageDomain().getStorageType().isBlockDomain()) {
Expand Down