1. Put the KVM under the virtual machine;
[Email protected] ~]# Virsh List--All Id the Name state---------------------------------------------------- -GAMEDEV10 shut off-Gamedev11 shut off-Gamedev12 shut off-Gamedev13 shut off-Gamedev2 shut off-Gamedev6 shut off-Gamedev7 shut off-Gamedev8 shut off-Gamedev9 shut off-Gamedevtpl shut off-Yunwei shut off
2. Convert the virtual machine in the KVM under IMG file format to the VMDK format with the following command:
Qemu-img Convert/data/img/gamedev2.dsk
#转换完成后会有一个 gamedev2.vmdk file, upload this file to VMware VSphere
#/data/img/ The path to the disk file
[Email protected] ~]# ls/data/img/
Gamedev10.dsk gamedev12.dsk gamedev2.vmdk gamedev7.dsk gamedev9.dsk Git.dsk
Gamedev11.dsk gamedev2.dsk gamedev6.dsk gamedev8.dsk gamedevtpl.dsk test.img
3. Create a virtual machine "select Custom" in a VMware vsphere environment without creating a disk using the newly converted VMDK file to turn on the virtual machine
IP address may change, configure IP
[Email protected] network-scripts]#MVIfcfg-eth0 ifcfg-Ens160[[email protected] Network-scripts]# Vim ifcfg-ens160 TYPE="Ethernet"Bootproto="None"Defroute="Yes"Ipv4_failure_fatal="No"Ipv6init="Yes"ipv6_autoconf="Yes"Ipv6_defroute="Yes"Ipv6_failure_fatal="No"Ipv6_addr_gen_mode="stable-privacy"NAME="ens160"UUID="bf79d93a-2c0e-418d-a341-a2268c5e7da0"DEVICE="ens160"Onboot="Yes"ipaddr=10.0.3.44NETMASK=255.255.255.0GATEWAY=10.0.3.1[[Email protected] network-scripts]#/etc/init.d/network Restart
KVM Virtual machine migration to VMware