-
Notifications
You must be signed in to change notification settings - Fork 39
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
virt-v2v 2.2.0 not handling vmware guests with spaces in the name #35
Comments
This is probably because of this change upstream: e2af12b Unfortunately there's no syntax that works for both versions of scp :-( |
IIRC it's the client (virt-v2v) side scp which matters, not the server side, although I'm not 100% sure. |
And to confuse things, some distros backport the parsing changes from 8.8 but still call it "OpenSSH 8.7". RHEL 9 is one of these. Not sure about Debian but you might want to check. |
Hmmm. The virt-v2v commit above is to support the "newer" sftp style, right? I think the Debian Debian 12 says its package is:
Reading the changelog in the src package, I saw this
Interestingly, Ubuntu 22.04 (where I'm running virt-v2v 1.44.2 (not 1.4 as I typo'd above)) has
Glancing at the patches in the debian12 package [0], nothing stands out to me other than the very short [0]
[1]
|
So perhaps it's not that patch, as the patch applies to scp not ssh. The command being run is ssh. What happens if you run the command by hand, ie:
There may be a second quoting issue here. I created a file called
|
I believe the code affected is: virt-v2v/input/parse_domain_from_vmx.ml Line 90 in c5c9aa2
|
I get the same output from these two commands on Debian12, Ubuntu 22.04, Fedora 39 (in Vagrant), and CentOS Stream 9 (also random vagrant box). The weird double-single-escaped quote works, but the plain single quote doesn't.
|
My impression is we need to revert the last hunk of commit e2af12b, i.e., the hunk that removes the double-quoting from |
(... Because that commit removed the double quoting for both scp and ssh. The update was probably right for (recent versions of) scp, but ssh continues needing the double quoting -- one layer for the local shell, another for the remote shell.) |
I can't reproduce the problem with virt-v2v-2.3.4-5.el9.x86_64
#virt-v2v -ic vpx://
***@***.***/data/10.73.212.38/?no_verify=1
-it vddk -io vddk-libdir=/home/vddk8.0.1 -io
vddk-thumbprint=85:C2:91:55:86:E5:BE:08:60:96:64:8D:54:6E:3F:39:A5:F5:1F:19
-ip /home/passwd 'Auto-esx7.0-rhel9.2 space-name-local-storage'
[ 0.0] Setting up the source: -i libvirt -ic vpx://
***@***.***/data/10.73.212.38/?no_verify=1
-it vddk Auto-esx7.0-rhel9.2 space-name-local-storage
[ 1.9] Opening the source
[ 33.2] Inspecting the source
[ 45.8] Checking for sufficient free disk space in the guest
[ 45.8] Converting Red Hat Enterprise Linux 9.2 Beta (Plow) to run on KVM
virt-v2v: This guest has virtio drivers installed.
[ 187.2] Mapping filesystem data to avoid copying unused and blank areas
[ 188.3] Closing the overlay
[ 188.7] Assigning disks to buses
[ 188.7] Checking if the guest needs BIOS or UEFI to boot
[ 188.7] Setting up the destination: -o libvirt
[ 190.2] Copying disk 1/1
█ 100% [****************************************]
[ 399.1] Creating output metadata
[ 399.4] Finishing off
# virsh list --all
Id Name
State
------------------------------------------------------------------------------------------------------
.....
27 Auto-esx7.0-rhel9.2 space-name-local-storage
running
Regards
Ming Xie
…On Sat, Sep 30, 2023 at 6:06 PM Laszlo Ersek ***@***.***> wrote:
(because that commit removed the double quoting for *both* scp *and* ssh.
The update was probably right for (recent versions of) scp, but ssh
continues needing the double quoting -- one layer for the local shell,
another for the remote shell.
—
Reply to this email directly, view it on GitHub
<#35 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALGAAPLPS4HQIDFQQZIHG63X47VILANCNFSM6AAAAAA5GZMJDA>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
@mxie91 note that the error specifically comes up when using |
I posted a patch here based on Laszlo's diagnosis above: |
Double quoting was removed in commit e2af12b ("input: -i vmx: Remove support for openssh scp < 8.8", Nov 2021). However it should only have been removed from scp commands, not for this ssh command where it is still required. See: #35 Thanks: Laszlo Ersek for diagnosis and suggesting the fix Reported-by: Bill Sanders Reviewed-by: Laszlo Ersek <[email protected]>
I just tested head of tree after that patch and on Debian 12 it works but fails at an That checks out based on discussions at the beginning of this issue. I'm able to switch to Debian 12, so that's good enough for me. Thanks for the patch :) I'm curious if it will be backported to 2.2.x? |
Double quoting was removed in commit e2af12b ("input: -i vmx: Remove support for openssh scp < 8.8", Nov 2021). However it should only have been removed from scp commands, not for this ssh command where it is still required. See: #35 Thanks: Laszlo Ersek for diagnosis and suggesting the fix Reported-by: Bill Sanders Reviewed-by: Laszlo Ersek <[email protected]> (cherry picked from commit 22c5b98)
virt-v2v 2.2.0 (as packaged in debian 12) fails to convert:
/vmfs/volumes/630cd6f1-0adec4cd-8b43-e0d55e25f3e4/bsanders win test/bsanders win test.vmx
using-it ssh
for VMware.Specifically, the error in question:
Note the
characters to
test -f
command. The documentation [0] suggested to convert%20
, and in virt-v2v 1.4, this works as expected. The error message is inaccurate - this VM does not have snapshots.The same ssh test line from v2v 1.4, note the subtle difference in quoting:
[0] https://libguestfs.org/virt-v2v-input-vmware.1.html - "VMX: Construct the SSH URI"
The text was updated successfully, but these errors were encountered: