A workgroup manages the lifecycle of multiple migration tasks simultaneously. You can use workgroups to migrate servers in batches and improve migration efficiency.
Migration scenarios
Workgroup-based batch migration currently supports only migrating servers to ECS Image. After migration, manually create ECS instances from the generated custom images.
-
Migrate servers to ECS instances
-
Migrate Simple Application Server instances to ECS instances
For other server migration scenarios, see Server migration operations.
Preparations
-
Complete pre-migration preparations. For more information, see Pre-migration preparation.
-
Set up a migration template. For more information, see Set up a migration template.
Procedure
Step 1: Create a workgroup
You can create up to 50 workgroups per Alibaba Cloud account.
-
Go to the Workgroup Migration page in the SMC console.
ImportantTo migrate Alibaba Cloud ECS instances across accounts (from source account A to destination account B), log on to the SMC console using destination account B.
-
On the Workgroup Migration page, click Create Workgroup.
-
In the Create Workgroup dialog box, configure the parameters.
Parameter
Description
workgroupName (optional)
Enter a workgroup name.
The name must be 2 to 64 characters long, start with a letter or Chinese character, and cannot start with
http://orhttps://. It can contain digits, colons (:), periods (.), underscores (_), or hyphens (-).workgroupDescription (optional)
Enter a description for the workgroup.
Select Migration Source (optional)
-
If you have already imported migration sources, select them from the drop-down list.
-
If you have not imported migration sources, after creating the workgroup, perform Step 2: Import and associate migration sources.
Note-
A workgroup can be associated with up to 50 migration sources.
-
A migration source can be associated with only one workgroup.
Tag (optional)
Enter tag keys and values directly or select existing ones to help manage the workgroup.
NoteYou can attach up to 20 tags to each workgroup.
-
-
Click Create.
If you no longer need the workgroup later, first disassociate all migration sources from it. Then, in the Actions column of the target workgroup, choose and follow the on-screen instructions to delete the workgroup.
Step 2: Import and associate migration sources
A migration source is an on-premises IDC server, virtual machine, cloud host from another cloud platform, or other type of server.
-
In the Create Workgroup dialog box, click Import Migration Source.
NoteIf you have already associated all migration sources when creating the workgroup, click Close and proceed to Step 3: Start migration.
-
On the Import Migration Source page, follow the on-screen instructions to import and associate migration sources.
Command-line import (recommended)
Important-
The source server must have public network access. If the source server is behind a firewall, see What are the SMC service domains? to obtain the SMC endpoints and ports, and then add them to your firewall allowlist.
-
If your source server cannot access the public network or you want to use a private network for a faster migration, see Private network migration.
-
Configure the parameters as prompted and copy the activation command.
The following table describes the parameters.
Parameter
Description
Workgroup
The created workgroup is selected by default.
Migration Source Type
Physical server/virtual machine/cloud server from another cloud platform
Import Method
Select Use CLI to Import Server.
Migration Source Quota
The number of migration sources that can be activated by the activation code. Valid values: 1 to 1,000. Default value: 200.
Validity Period
The validity period of the activation code, in days. Valid values: 1 to 90. Default value: 90.
Activation Code
Generate the activation code and copy the command:
-
Click Generate.
-
Based on the operating system of the source server, click the Linux Shell or Windows PowerShell tab.
-
Click Copy to copy the activation code command.
-
-
Log on to the source server, and then paste and run the copied command with administrator privileges to import the migration source.
Linux source server
-
Log on to the Linux source server.
-
Paste and run the copied command with administrator privileges to import the migration source.
wget https://p2v-tools.oss-cn-hangzhou.aliyuncs.com/smc/China_Mainland/run_smc_client.sh && sudo bash run_smc_client.sh --accesstokenid at-bp1bq****94dnpodl1cm --accesstokencode xxxxxxIf you receive a message similar to
Import Source Server [s-bp18x8751kgz2oyh****] Successfully!, the migration source has been successfully imported.
Windows source server
-
Log on to the Windows source server.
-
Open Windows PowerShell with administrator privileges.
-
Paste and run the copied command to import the migration source.
$(New-Object System.Net.WebClient).DownloadFile('https://p2v-tools.oss-cn-hangzhou.aliyuncs.com/smc/China_Mainland/run_smc_client.ps1', 'run_smc_client.ps1'); .\run_smc_client.ps1 -accesstokenid at-bp1bq****94dnpodl1cm -accesstokencode xxxxxxIf you receive a message similar to
Import Source Server [s-bp19rlidl3mwuptc****] Successfully!, the migration source has been successfully imported.If the command fails to run, see What do I do if a command fails to run when I import a Windows migration source by using the command line?.
-
Client import
-
Configure the parameters as prompted and copy the activation command.
The following table describes the parameters.
Parameter
Description
Workgroup
The created workgroup is selected by default.
Migration Source Type
Select the source server type as needed:
Physical server/virtual machine/cloud server from another cloud platform.
Import Method
Select Use Client to Import Server.
Description
-
In the Description section, download, install, and activate the appropriate SMC client based on the operating system (Linux or Windows) and architecture (32-bit or 64-bit) of the source server.
-
Click Generate and copy the activation code.
You need to enter the activation code during client installation.
-
-
Import the migration source.
ImportantDo not close the SMC client during the migration. Otherwise, the migration source loses its connection to the SMC console and the migration fails.
Import a Windows source server
-
Use a remote connection tool that supports file transfer, such as WinSCP, to upload the SMC client to the Windows source server.
-
On the Windows source server, use the system's built-in decompression tool or a third-party tool to decompress the SMC client package.
-
In the folder for the SMC client version that matches your server's system, double-click the go2aliyun_client.exe application.
When prompted for administrator privileges, click OK.
-
Obtain an activation code or an AccessKey pair.
-
(Recommended) Obtain an activation code: In the Description section of the SMC console, click Generate and copy the activation code.
-
Obtain an AccessKey pair: An AccessKey pair consists of an AccessKey ID and an AccessKey secret. If you have not created one, see Create an AccessKey pair.
-
-
As prompted, enter the values for
access_token_idandaccess_token_code, and then pressEnter.When you receive a message similar to
Import Source Server [s-bp18x8751kgz2oyh****] Successfully!, the migration source has been successfully imported.
Import a Linux source server
-
Use a remote connection tool that supports file transfer, such as WinSCP, to upload the SMC client to the Linux source server, or run the command provided in the import instructions to download the SMC client directly on the source server.
-
Remotely connect to the Linux source server and decompress the SMC client package.
This example uses the
Linux 64-bit General-purpose Edition. If you use a different version of the SMC client, replace the package name in the command with the name of the file you downloaded.tar -zxvf go2aliyun_client.tar.gzNoteThe Linux 64-bit ARM Edition supports the g6r general-purpose instance family and the c6r compute-optimized instance family. For more information about instance families, see Enterprise-level Arm-based compute instance families.
-
(Optional) You can filter or exclude files and directories from the migration.
ImportantIf you enable block replication for the migration, you cannot exclude files or directories.
-
Obtain an activation code or an AccessKey pair.
-
(Recommended) Obtain an activation code: In the Description section of the SMC console, click Generate and copy the activation code.
-
Obtain an AccessKey pair: An AccessKey pair consists of an AccessKey ID and an AccessKey secret. If you have not created one, see Create an AccessKey pair.
-
-
In the SMC client directory, run the following commands to start the SMC client.
The directory
go2aliyun_client...is an example. Replace it with the actual directory name created when you decompress the package, as the name varies by client version.cd go2aliyun_client2.6.5_linux_x86_64 sudo chmod +x go2aliyun_client sudo ./go2aliyun_client -
Enter the activation code or AccessKey pair as prompted. The following example shows how to enter an activation code:
$ sudo ./go2aliyun_client go2aliyun_client China version 2.6.5 Access Token Id: at-bp1bq****94dnpodl1cm Access Token Code: ****After entering the activation code or AccessKey pair, the following prompts may appear:
-
If a snapshot driver is not installed on the source system, the SMC client prompts you to install one. Respond to the prompt based on your migration plan.
-
If you plan to enable block replication when you create the migration task, enter
yesto automatically install the snapshot driver. -
If you do not plan to enable block replication, enter
no.
ImportantIf the snapshot driver fails to install, do not enable block replication when you create the migration task. Otherwise, the migration will fail.
Install snapshot dependences(gcc/make/kernel-devel)? (yes/no): yes -
-
Most mainstream source systems have rsync installed by default. If rsync is not installed, the SMC client prompts you to install it. Enter
yesto automatically install rsync.Need to install rsync, run 'apt-get -y install rsync' to continue? (yes/no): yes -
If SELinux is enabled on the source system, the SMC client prompts you to disable it. Enter
yesto automatically disable SELinux.Need to disable SELINUX, run 'setenforce 0' to continue? (yes/no): yes
When you receive a message similar to
Import Source Server [s-bp11npxndknsycqj****] Successfully!, the migration source has been successfully imported.NoteIf the import fails, troubleshoot the issue based on the returned message. Then, run the following commands to exit the background process and re-import the migration source. For information about common issues and solutions, see SMC FAQ and Troubleshooting.
sudo ./go2aliyun_client --abort sudo ./go2aliyun_client -
-
-
Associate the migration source.
-
Go to the Workgroup Migration page in the SMC console.
-
In the Associate Migration Source column of the target workgroup, click Associate Migration Source.
-
In the Associate Migration Source dialog box, select the migration source and click OK.
-
-
-
Check the migration source status.
-
Go to the Workgroup Migration page in the SMC console.
-
Click the workgroup ID to go to the workgroup details page.
-
In the Migration Sources section, check the status in the Real-time Migration Status column.
-
If the status is Migration SourceOnline, the import was successful.
-
If the status is anything else, the import has failed. See the following solutions to resolve the issue, and then import the data again.
-
Troubleshoot the issue based on the error message in the console or by checking the SMC client log file. The default installation directories of the SMC client are:
-
Windows source server: C:\smc.
-
Linux source server: /smc.
-
-
For information about common issues and solutions, see SMC FAQ and Troubleshooting.
-
-
-
Step 3: Start migration
-
Go to the Workgroup Migration page in the SMC console.
-
In the Actions column of the target workgroup, click Start Migration.
-
In the Confirm Migration Source dialog box, verify the servers to be migrated and click Next.
If servers appear under the Inoperable Migration Sources tab, click the
icon to view why they cannot be migrated. -
Configure migration parameters as needed and click Start Migration.
If you have preset migration task parameters in a migration template, the template parameters are automatically filled in when you create the migration task to improve efficiency. For more information, see Set up a migration template.
NoteIf some migration sources already have migration tasks, new migration tasks are not created for them.
-
In the dialog box that appears, read the notes and click Got It.
-
On the Workgroup Migration page, check the migration status.
-
When the Migration Status changes from To be Started to In progress, the server migration has started.
You can click the workgroup ID to view the real-time migration status of each server. If you enabled migration rehearsal, SMC performs a rehearsal first. After the rehearsal passes, SMC starts the migration.
-
When the Real-time Migration Status is Rehearsal passed, the rehearsal succeeded and the system automatically starts migration.
-
When the Real-time Migration Status is Rehearsal failed, the rehearsal failed. View the rehearsal report, fix the critical items, and retry the rehearsal. For more information, see Configure migration rehearsal.
-
-
When the Real-time Migration Status is Synchronizing, the server data is being migrated.
Migration duration depends on the source data size, network bandwidth, and other factors. While the migration is in progress, you can perform the following operations as needed:
-
Modify migration settings: In the Actions column, click Modify Migration Job to change the task name, description, transfer rate limit, compression ratio, and checksum validation parameters.
-
Pause migration: In the Actions column, click Pause Migration Job to pause the migration.
-
-
When the Real-time Migration Status is Pending, the initial full migration of the server is complete.
The first migration performs a full migration of the source server system data and generates a full ECS custom image.
At this point, the Actions column displays links for Start migration, Manual incremental sync, and Complete incremental sync.
-
Step 4: Incremental migration
After the initial migration completes and the migration status is Pending, SMC waits for the next cycle based on the Synchronization Interval you set, then automatically runs incremental migration and generates a new ECS custom image.
Each ECS custom image generated by incremental migration is a full image of the source server at that moment, including both the incremental data at migration time and all previously migrated data.
-
Pause business operations and run incremental migration.
During off-peak hours, pause business operations on the source server and run incremental migration again.
-
Log on to the source server and pause business operations.
-
Perform incremental migration.
-
Automatic incremental migration
SMC automatically runs incremental migration based on the Synchronization Interval you set.
-
Manual incremental migration
In the Actions column of the target workgroup, click Manual Incremental Synchronization and follow the on-screen instructions to perform incremental migration in batches.
NoteYou can also click the workgroup ID to manually perform incremental sync for each server individually.
-
-
-
Complete incremental sync.
After the last incremental sync task completes, finalize the data synchronization.
-
In the Actions column of the target workgroup, choose .
-
In the Run Incremental Job dialog box, click Next.
You can also select Perform One Last Synchronization in the Complete Incremental Synchronization dialog box to complete the final data sync.
-
Click Next to confirm the migration source.
-
Click Confirm to start incremental sync.
-
On the Workgroup Migration page, check the migration status.
Migration duration depends on the source data size, network bandwidth, and other factors. When the migration status is Completed, incremental migration is finished.
NoteAfter completing incremental sync, the task stops and you cannot perform manual incremental sync again. If you accidentally clicked Complete Incremental Synchronization but still need to migrate incremental data, start a new migration.
-
Verify migration results
-
After successful migration, Alibaba Cloud custom images are generated.
-
On the Workgroup Migration page, click the workgroup ID.
-
In the Migration Deliverables column of the target migration source, view the ECS custom image.
You can also click View Report to check the image inspection results. For more information, see View image inspection results.
-
-
Verify the migration results.
Manually verify migration results (recommended)
-
In the Actions column of the target migration source, click Create Instance. The system redirects you to the ECS console Create Instance page with the generated ECS custom image preselected.
-
Create an ECS instance from the custom image. For more information, see Create an instance from a custom image or shared image.
Automatically verify migration results
NoteTo use this feature, you must install the Cloud Assistant plugin on the instance, and the instance OS version must support it. For more information, see Install Cloud Assistant Agent.
This feature uses the Alibaba Cloud OOS template
ACS-SMC-CreateAndVerifyInstanceto automatically verify whether the image generated by the migration task can successfully create and start an ECS instance.-
In the Actions column of the target migration source, click Verify Migration Result.
-
In the dialog box that appears, review the verification process and click Verify Now.
You can also click Customize Verification Parameters to manually configure parameters for verification.
-
In the Verify Migration Result column, check the verification results.
-
Verified: The migration result is normal. You can click View output parameters to see the verification results.
-
Not Verified: The migration result has issues. Click View Cause to learn why the migration task failed and troubleshoot accordingly.
You can also click the
icon in the Actions column and then click View Verification Records in OOS Console to get historical execution information for the OOS template. -
-
After migrating the server, perform the following steps to ensure that your services run correctly:
-
Validate the data to ensure its integrity and correctness. For more information, see How do I check the system after migrating a Linux server? or How do I check the system after migrating a Windows server?.
-
If applications and services on the source server are not configured to automatically start, manually start them after the migration.
-
The IP address changes during the migration. If your services depend on IP address configurations, you must modify settings such as domain name resolution and ICP filing after the migration.
-
If a domain name is mapped to the source server, remap it to the new public IP address. For more information, see Add a website resolution.
-
To retain the source server's private IP address, assign it to the new instance after migration.
-
If the destination is an ECS Image: Specify the private IP address when you create the ECS instance. For more information, see Specify the primary private IPv4 address for the primary ENI when you create an ECS instance.
-
If the destination is an ECS Instance: If you did not modify the private IPv4 address in the advanced settings of the migration settings step, you can still modify the private IPv4 address of the destination instance after the migration. For more information, see Modify the primary private IPv4 address of the primary ENI for an existing instance.
-
-
Clean up resources
During migration, SMC creates a temporary pay-as-you-go intermediate instance named No_Delete_SMC_Transition_Instance under your Alibaba Cloud destination account for each server. Clean up these instances manually based on migration results:
-
Migration successful: The intermediate instance is automatically released. No manual cleanup is required.
-
Migration failed: The intermediate instance remains with the migration task and incurs charges. To avoid unnecessary fees, release the intermediate instance using one of the following methods:
-
If you no longer need the migration task, click the workgroup ID, then click the migration source ID. In the Actions column of the migration task, click Cancel Migration Job to delete the migration task and automatically clean up the intermediate instance.
-
Manually release the intermediate instance. For more information, see Release an instance.
-
References
To migrate a single server, see: