Import Xen machines

Latest response

Hi all,

I'm trying to migrate a Xen server to RHEV.

 

I am using the virt-v2v, but it is impossible. Whenever I get the error:

 

# virt-v2v -f /etc/virt-v2v.conf -o rhev -ic xen+ssh://root@srxen05.mutua.es -os nas1b:/vol/rhevAUXaggr1/export srxmsatelite-test2

 

libvirt error code: 42, message: Domain not found: xenUnifiedDomainLookupByName
 

 

Now I want to make other arrangements, and is to convert the machines manually.

 

Another alternative would be to convert the machines Xen manually. This is possible?

Any ideas?

 

Thanks.

 

Responses

Hi, the error means srxmsatelite-test2 is a VM name that virt-v2v could not find. Can you doublecheck the name to make sure you have the spelling correct, and check in virsh list whether the VM is there?

Hi, if I boot the virtual machine srxmsatelite-test2, virt-v2v tells me:

 

# virt-v2v -f /etc/virt-v2v.conf -o rhev -ic xen+ssh://root@srxen05.mutua.es -os nas1b:/vol/rhevAUXaggr1/export srxmsatelite-test2

root@srxen05.mutua.es's password:

virt-v2v: Guest srxmsatelite-test2 is currently blocked. It must be shut down first.

 

So I have to do with the machine off, I think. Am I wrong? How should I proceed?

 

Thanks :-)

Yes, to convert a virtual machine using virt-v2v, you need to shut the vm down first on the source machine if it's running.

ok, thanks. But do not understand why I failed and I get the error:

 

libvirt error code: 42, message: Domain not found: xenUnifiedDomainLookupByName

 

 

I tried another option, and is to convert the images so manually. But I can not get it right.

 

Any idea how I can proceed?

 

Thanks.

 

does the VM name appear when you run `virsh list --all` ?

Please run "virsh -c xen+ssh://root@srxen05.mutua.es list --all" and give the output.

[root@srkmrhev ~]# virsh -c xen+ssh://root@srxen05.mutua.es list --all
root@srxen05.mutua.es's password:
 Id Name                 State
----------------------------------
  0 Domain-0             running
  1 srxmdb2d             idle
  2 srxmdesarepo         idle
  3 srxmqatestx          idle
  4 srxmsubversiond      idle
  6 srxmwebscript01      idle
 12 srxmwaslab02         idle
 14 srxmsamg01           idle
 

I don't see srxmsatelite-test2 in this list

Sure, I have turned off earlier, in order to launch the command. However, it is true that it should seem, even in a list off. I will review it does not appear. :-?

Can't see vm named srxmsatelite-test2" in the output. It should have been in the list with a status "shut off".

 

If the vm srxmsatellite-test2 is on the host, it looks like you are running a very old version of "libvirt" that cannot display shutdown vms. I mean libvirt released with RHEL-5.0 or 5.1.

Can you provde output of "cat /etc/redhat-release" and "rpm -q libvirt" on the xen system?

here is the output.

 

 

[root@srxen05 bin]# cat /etc/redhat-release
Red Hat Enterprise Linux Server release 5.7 (Tikanga)
[root@srxen05 bin]# rpm -q libvirt
libvirt-0.8.2-22.el5
libvirt-0.8.2-22.el5

 

Thanks

New case.

 

I booted the virtual machine. With virsh I exported the configuration.

 

# virsh dumpxml srxmsatelite-test2 > /tmp/srxmsatelite-test2.xml

 

I copied the xml file to another server, where I have the utility virt-v2v

 

I edited the xml file and changed the directory where the disk images.

 

I copied the disk images to this server. In the xml file and specify the path.

 

It seems that all starts well, but ultimately fails.

 

[root@srkmrhev xen]# virt-v2v -i libvirtxml -osd nas1b:/vol/rhevAUXaggr1/export -o rhev --network default srxmsatelite-test2.xml
srxmsatelite-test2.boot: 100% [========================================================================================================================================]D 0h00m03s
srxmsatelite-test2.disk: 100% [========================================================================================================================================]D 0h02m43s
srxmsatelite-test2.swap: 100% [========================================================================================================================================]D 0h01m21s
mount_options: mount_options: mount_options_stub: /dev/sda2: No such file or directory at /usr/share/perl5/vendor_perl/Sys/VirtConvert/GuestfsHandle.pm line 203.
 at /usr/share/perl5/vendor_perl/Sys/VirtConvert/Converter.pm line 99
 (ignored)
mount_options: mount_options: mount_options_stub: /dev/sda1: No such file or directory at /usr/share/perl5/vendor_perl/Sys/VirtConvert/GuestfsHandle.pm line 203.
 at /usr/share/perl5/vendor_perl/Sys/VirtConvert/Converter.pm line 99
 (ignored)
mkdtemp: mkdtemp: mkdtemp_stub: you must call 'mount' first to mount the root filesystem at /usr/share/perl5/vendor_perl/Sys/VirtConvert/GuestfsHandle.pm line 203.
 at /usr/share/perl5/vendor_perl/Sys/VirtConvert/Config.pm line 235

This problem is not expected to happen with the above libvirt version. I would request you to open a case with Red Hat support with sosreport from xen system, virt-v2v debug output and sosreport from virt-v2v host.

 

This need to be analyzed in detail.

Does the xen guest configured with a scsi disk inside the guest? how does the "df" look like inside the guest?

[root@srxmsatelite-test2 ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/xvda2            4.0G  2.7G  1.1G  72% /
/dev/xvda1             78M   33M   41M  45% /boot
tmpfs                 1.0G     0  1.0G   0% /dev/shm

 

 

Thanks ;-)

Thanks, I opened a case with Red Hat yesterday.