-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Added vddk support in vmware to kvm migrations #12970
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
base: 4.22
Are you sure you want to change the base?
Changes from all commits
7dc5d50
d380447
fbd8082
cb42c2f
ababa52
7fb0b85
2976142
e35d12e
5740e8a
50e4ebc
b4acbc3
8843062
64f1610
5c3993f
90ddb19
ab914bf
6b3dc07
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -457,3 +457,19 @@ iscsi.session.cleanup.enabled=false | |
|
|
||
| # Instance conversion VIRT_V2V_TMPDIR env var | ||
| #convert.instance.env.virtv2v.tmpdir= | ||
|
|
||
| # LIBGUESTFS backend to use for VMware to KVM conversion via VDDK (default: direct) | ||
| #libguestfs.backend=direct | ||
|
|
||
| # Path to the VDDK library directory for VMware to KVM conversion via VDDK, | ||
| # passed to virt-v2v as -io vddk-libdir=<path> | ||
| #vddk.lib.dir= | ||
|
|
||
| # Ordered VDDK transport preference for VMware to KVM conversion via VDDK, passed as | ||
| # -io vddk-transports=<value> to virt-v2v. Example: nbd:nbdssl | ||
| #vddk.transports= | ||
|
|
||
| # Optional vCenter SHA1 thumbprint for VMware to KVM conversion via VDDK, passed as | ||
| # -io vddk-thumbprint=<value>. If unset, CloudStack computes it on the KVM host via openssl. | ||
| #vddk.thumbprint= | ||
|
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @harikrishna-patnala can you update the docs with these settings here: https://docs.cloudstack.apache.org/en/4.22.0.0/adminguide/virtual_machines.html#importing-virtual-machines-from-vmware-into-kvm
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. added a doc PR here apache/cloudstack-documentation#640 |
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -805,8 +805,11 @@ protected AgentAttache notifyMonitorsOfConnection(final AgentAttache attache, fi | |
| String uefiEnabled = detailsMap.get(Host.HOST_UEFI_ENABLE); | ||
| String virtv2vVersion = detailsMap.get(Host.HOST_VIRTV2V_VERSION); | ||
| String ovftoolVersion = detailsMap.get(Host.HOST_OVFTOOL_VERSION); | ||
| String vddkSupport = detailsMap.get(Host.HOST_VDDK_SUPPORT); | ||
| String vddkLibDir = detailsMap.get(Host.HOST_VDDK_LIB_DIR); | ||
| String vddkVersion = detailsMap.get(Host.HOST_VDDK_VERSION); | ||
| logger.debug("Got HOST_UEFI_ENABLE [{}] for host [{}]:", uefiEnabled, host); | ||
| if (ObjectUtils.anyNotNull(uefiEnabled, virtv2vVersion, ovftoolVersion)) { | ||
| if (ObjectUtils.anyNotNull(uefiEnabled, virtv2vVersion, ovftoolVersion, vddkSupport, vddkLibDir, vddkVersion)) { | ||
| _hostDao.loadDetails(host); | ||
| boolean updateNeeded = false; | ||
| if (StringUtils.isNotBlank(uefiEnabled) && !uefiEnabled.equals(host.getDetails().get(Host.HOST_UEFI_ENABLE))) { | ||
|
|
@@ -821,6 +824,26 @@ protected AgentAttache notifyMonitorsOfConnection(final AgentAttache attache, fi | |
| host.getDetails().put(Host.HOST_OVFTOOL_VERSION, ovftoolVersion); | ||
| updateNeeded = true; | ||
| } | ||
| if (StringUtils.isNotBlank(vddkSupport) && !vddkSupport.equals(host.getDetails().get(Host.HOST_VDDK_SUPPORT))) { | ||
| host.getDetails().put(Host.HOST_VDDK_SUPPORT, vddkSupport); | ||
| updateNeeded = true; | ||
| } | ||
| if (!StringUtils.defaultString(vddkLibDir).equals(StringUtils.defaultString(host.getDetails().get(Host.HOST_VDDK_LIB_DIR)))) { | ||
| if (StringUtils.isBlank(vddkLibDir)) { | ||
| host.getDetails().remove(Host.HOST_VDDK_LIB_DIR); | ||
| } else { | ||
| host.getDetails().put(Host.HOST_VDDK_LIB_DIR, vddkLibDir); | ||
| } | ||
| updateNeeded = true; | ||
| } | ||
| if (!StringUtils.defaultString(vddkVersion).equals(StringUtils.defaultString(host.getDetails().get(Host.HOST_VDDK_VERSION)))) { | ||
| if (StringUtils.isBlank(vddkVersion)) { | ||
| host.getDetails().remove(Host.HOST_VDDK_VERSION); | ||
| } else { | ||
| host.getDetails().put(Host.HOST_VDDK_VERSION, vddkVersion); | ||
| } | ||
| updateNeeded = true; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. do we need all these params in host_details? Persisting Host.HOST_VDDK_VERSION should be enough when vddk lib is properly set, to indicate vddk support.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Version identification is not just enough to claim the support but we will also need the directory where it is located as we need to pass that in the virt-v2v command with vddk. |
||
| } | ||
| if (updateNeeded) { | ||
| _hostDao.saveDetails(host); | ||
| } | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should keep other possible options in the comment (other than direct) ?