Virtual machine migration (live migration)

migrate:

      Migration refers to the system of the operating system and applications on the source host to the destination host moves, and works correctly at the destination host

Migration purposes:

    1, simplify system maintenance and management

    2, high system load balancing

    3, enhance system error tolerance

    4, the power management system to optimize

KVM live migration of virtual machines --- Live Migration

Live migration (also known as live migration, live migration), a virtual machine that is saved (save) / restore (restore): The overall state of the virtual machine preserved intact, and can quickly be restored to the original hardware platforms or even different hardware on the platform. After recovery, the virtual machine is still running smoothly, users will not notice any difference.

Migration of species:

P2P: migration between physical machines

V2P: physical machine virtual machine moved

P2V: physical machine move virtual machines

V2V: VM virtual machine moved

Migration to measure efficiency:

 1. The overall migration time: migration time on the destination host client services will be unavailable to start operating from the source host, then the source host client has been out of service, the client has not been restored on the destination host service.

2. server downtime: During the migration process, the client on the source and destination hosts are in a time unavailable at this time on the source host client has been suspended, the purpose of the destination host client has not been restored

Complex services.

3. affect the performance of the service: not only include relatively lower than if somewhat before the performance and application migration client after migration, also including the impact on the performance of other services on the destination host after migration.

 

Experiment: V2V

Preparing the environment:

1, the two have built a good kvm server and virtual machine

2, two servers can communicate with each other

3,192.168.206.132 hostname: lichaohostkvm60G: ~

      192.168.206.130 hostname: lichaohostkvm50G: ~

 

1> set up nfs service

# 1 resolve domain names

&1

 

&2

# 2 keys

&1 

ssh-keygen

&2

ssh-copy-id 192.168.206.130

Download # 3

yum install rpcbind nfs-utils -y

 

# 4 Create a shared directory

mkdir  nfsdate

# 5 Edit Profile

&1

 

& 2 as follows

/nfsdate 192.168.206.130(rw)

# 6 modify owner

chown -R nfsnobody:nfsnobody /nfsdate

# 7 nfs service starts

 

# 8 download lichaohostkvm50G end

 

# 9 To Mount

&1

Create a shared directory & 2

 

Mount & 3

 

& View 4

 

2> Migrating lichaohostkvm60G in the vm10 to licahohostkvm50G in

#

#

 

1 & Copy vm10 disk files to a shared directory

 

Backup & 2 vm10 virtual machine configuration file

 

& 3 Delete vm10 domain

 

& 4 editor vm10 virtual machine configuration file

vim vm10.xml

 

 

5 & ​​domain defined vm10

 

6 & Power vm10 virtual machine

 

& 7 migration using the virt-manager

#1

# 2 migration

 

#3

 

#4

 

# 5 migration was successful

 

 

Guess you like

Origin www.cnblogs.com/myxxjie/p/11013155.html