Click here to obtain the compressed migration tool package.
2. Choosing a Migration Mode Based on the Network Environment
Choose the appropriate migration mode according to the network environments of your source servers and destination CVMs.
Currently, the migration tool supports the default mode and the private network mode. The private network mode applies to three scenarios. Each migration mode or scenario has different network requirements for source servers and destination CVMs. If both source servers and destination CVMs can access the public network, you can use the default mode for migration. If source servers or destination CVMs cannot directly access the public network, you need to establish a connection between them through VPC peering connections, VPN connections, Cloud Connect Network, or Direct Connect before using the private network mode for migration.
3. Backing up Data
- Source server: you can use the UCloud snapshot feature or other methods to back up data.
- Destination CVM: you can create a snapshot or use other methods to back up data.
4. Checking Before the Migration
Before the migration, check the following items of the source server and destination CVM:
- Storage: cloud disks (including system disks and data disks) of the destination CVM must have sufficient storage capacity to store data from the source server.
- Security group: 443 and 80 ports must be open to the Internet in a security group.
- Bandwidth: we recommend that you increase inbound and outbound bandwidth for faster migration. The traffic consumed during migration will be approximately equal to the data volume. If needed, change your network billing method in advance.
- Operating system: we recommend that you use the same operating system on both the source server and the destination CVM. Different operating systems will result in inconsistency between the image to be created and the actual operating system. For example, when migrating a source server with the CentOS 7 system installed, choose a CVM with the CentOS 7 system installed as the destination.
|Linux source server|
- Check and install Virtio. For more information, see Checking Virtio Drivers in Linux.
- Check whether rsync is installed by running
which rsync for verification.
- Check whether SELinux is enabled. If yes, disable it.
- Ensure the current system time is correct, because the Tencent Cloud API will use the UNIX timestamp to check the generated token after receiving a migration request.
- You can use tool commands to automatically check the source server, for example,
sudo ./go2tencentcloud_x64 --check.
- By default, the go2tencentcloud migration tool automatically performs checks upon launch. To skip checks and perform forced migration, configure
true in the client.json file.
- For more information on the go2tencentcloud migration tool, see Migration Tool.
5. Starting the Migration
- Establish a private network connection between the source server and the destination CVM.
- Configure the “user.json” file.
The “user.json” file is used to configure the source server and the destination CVM. It contains the following configuration items:
- The API keys of your account, that is,
SecretKey. For more information, see Access Key.
- The region of the destination CVM. For more information on supported regions, see Regions and Availability Zones.
- The instance ID of the destination CVM, which can be checked on the Instances page.
- (Optional) The data disk configuration of the source server.
- Configure the “client.json” file.
The “client.json” file is used to configure the migration mode and other parameters. You need to configure the
Client.Net.Mode parameter in the “client.json” file, regardless of which migration scenarios you select.
- (Optional) Exclude files and directories on the source server that do not need to be migrated.
Edit the “rsync_excludes_linux.txt” file on the Linux source server to remove files and directories that do not need to be migrated.
- Run the tool.
For example, on a 64-bit Linux source server, execute the following command as the root user to run the tool.
Please wait for the migration process to complete.
If the following appears on the console, the migration has been completed successfully.