Virtual Machine Migration From One Project to Another¶
These instructions help in facilitating migration of a virtual machine from one project to another within OpenStack environment.
Preparing of VM¶
Your virtual machine needs to be in Shut Down state before we start snapshotting the machine, so that there isn't a state change on the machine during the process.
You can shut down the VM through the web interface.
Create a Snapshot of the VM¶
Create Snapshot via CLI¶
- List the servers in your current project
- Create a snapshot
- Check if the snapshot is in the list of images and in active status.
Create Snapshot via Web Interface¶
Follow the instructions at the OpenStack Documentation.
Download the Snapshot¶
Copy the ID of snapshot you just took and use it below in place of myInstanceSnapshotID
Import Snapshot Into the New Project¶
Import Snapshot via CLI¶
-
Source openrc file for the new project
-
Import snapshot
openstack image create myInstanceSnapshot --disk-format qcow2 --container-format bare --private --file <snapshot-file>
Import Snapshot via Web Interface¶
Follow the instructions OpenStack Documentation
Create a New Instance From the Snapshot¶
Create Instance via CLI¶
Launch an instance
openstack server create --flavor m1.medium --image myInstanceSnapshot --network dmznet myNewInstance
Create Instance via Web Interface¶
Follow the instructions OpenStack Documentation