Lines Matching +full:send +full:- +full:migration

1 # Live Migration
3 This document gives examples of how to use the live migration support
6 1. local migration - migrating a VM from one Cloud Hypervisor instance to another on the same machi…
7 1. remote migration - migrating a VM between two machines;
12 ## Local Migration (Suitable for Live Upgrade of VMM)
17 $ target/release/cloud-hypervisor
18 --kernel ~/workloads/vmlinux \
19 --disk path=~/workloads/focal.raw \
20 --cpus boot=1 --memory size=1G,shared=on \
21 --cmdline "root=/dev/vda1 console=ttyS0" \
22 --serial tty --console off --api-socket=/tmp/api1
28 $ target/release/cloud-hypervisor --api-socket=/tmp/api2
31 Get ready for receiving migration for the destination VM (on the host machine):
34 $ target/release/ch-remote --api-socket=/tmp/api2 receive-migration unix:/tmp/sock
37 Start to send migration for the source VM (on the host machine):
40 $ target/release/ch-remote --api-socket=/tmp/api1 send-migration --local unix:/tmp/sock
47 ## Remote Migration
63 machines. This is important for the migration to succeed. We will use
67 …=https://ftp.debian.org/debian/dists/stable/main/installer-amd64/current/images/netboot/debian-ins…
68 src $ mkdir -p /var/images
75 ### Unix Socket Migration argument
77 If Unix socket is selected for migration, we can tunnel traffic through "socat".
84 dst $ cloud-hypervisor --api-socket /tmp/api
87 In a different terminal, configure the VM as a migration target:
90 dst $ ch-remote --api-socket=/tmp/api receive-migration unix:/tmp/sock
96 dst $ socat TCP-LISTEN:{port},reuseaddr UNIX-CLIENT:/tmp/sock
104 src $ cloud-hypervisor \
105 --serial tty --console off \
106 --cpus boot=2 --memory size=4G \
107 --kernel /var/images/linux \
108 --initramfs /var/images/initrd \
109 --cmdline "console=ttyS0" \
110 --api-socket /tmp/api
115 #### Performing the Migration argument
120 src $ socat UNIX-LISTEN:/tmp/sock,reuseaddr TCP:{dst}:{port}
125 Then we kick-off the migration itself:
128 src $ ch-remote --api-socket=/tmp/api send-migration unix:/tmp/sock
134 ### TCP Socket Migration argument
136 If TCP socket is selected for migration, we need to consider migrating
144 dst $ cloud-hypervisor --api-socket /tmp/api
147 In a different terminal, prepare to receive the migration:
150 dst $ ch-remote --api-socket=/tmp/api receive-migration tcp:0.0.0.0:{port}
158 src $ cloud-hypervisor \
159 --serial tty --console off \
160 --cpus boot=2 --memory size=4G \
161 --kernel /var/images/linux \
162 --initramfs /var/images/initrd \
163 --cmdline "console=ttyS0" \
164 --api-socket /tmp/api
169 #### Performing the Migration argument
171 Initiate the Migration over TCP:
174 src $ ch-remote --api-socket=/tmp/api send-migration tcp:{dst}:{port}
182 the VM should remain intact after the migration.