You can enable Transfer Associated Resources and configure rules so that associated resources automatically move into the same resource group as their primary resource.
Use cases
For example, an ECS instance's associated resources, such as cloud disks, ENIs, and EIPs, can automatically follow it to a new resource group. The following trigger conditions are supported:
-
Transfer on attachment: When an associated resource is attached to an ECS instance, the resource is automatically moved to the resource group of the ECS instance.
-
Transfer on move: When an ECS instance is moved to a different resource group, its associated resources are automatically moved with it.
Prerequisites
You have enabled Automatic Resource Transfer. Enable Automatic Resource Transfer.
Configure transfer rules
-
Log on to the Resource Management console.
-
In the navigation pane on the left, choose .
-
On the Transfer of Associated Resources tab, click Edit.
-
Configure the transfer rules.
-
Select the associated resource types to transfer.
Supported resource types are listed in Cloud resources that support the Transfer Associated Resources feature.
-
Recommended: Select Transfer Existing Associated Resources to move existing associated resources to their primary resource's group.
Existing associated resources are resources that were created before you enabled Transfer Associated Resources.
If an existing associated resource belongs to a different resource group than its primary resource, start this task to move it. Otherwise, the resource moves only when its primary resource is moved to a new group.
This task uses the service-linked role AliyunServiceRoleForResourceGroup to access Cloud Config for resource detection and transfer. This does not count against your Cloud Config quota or incur additional fees.
-
-
Click OK.
After the configuration is complete, associated resources automatically follow their primary resource when a trigger condition is met. For details about trigger conditions, see the Trigger rule column in Cloud resources that support the Transfer Associated Resources feature.
Modify transfer rules
-
Log on to the Resource Management console.
-
In the navigation pane on the left, choose .
-
On the Transfer of Associated Resources tab, click Edit to modify the rules.
-
Click OK.
Supported cloud resources
|
Primary resource |
Associated resource |
Trigger rule |
|
ECS instance |
cloud disk (including data disks and system disks) |
|
|
ENI (including primary ENI and secondary ENI) |
||
|
EIP |
||
|
cloud disk |
snapshot |
|
|
NAT Gateway |
ENI |
Transfer on move: When a NAT Gateway is moved to a new resource group, its associated ENIs are automatically moved with it. |
|
EIP |
|
|
|
SLB instance |
EIP |
|
Limitations
-
While a transfer task is running, you cannot move the primary resource or its associated resources by using the console or API. Wait for the task to complete before performing any move operations.
-
After you enable Transfer Associated Resources, we recommend that you move only the primary resource to avoid conflicts. Associated resources are moved automatically.
-
Transfer Associated Resources is available in the following regions: Indonesia (Jakarta), Malaysia (Kuala Lumpur), China (Hohhot), Singapore, Germany (Frankfurt), US (Virginia), US (Silicon Valley), China (Hong Kong), China (Qingdao), Japan (Tokyo), China (Zhangjiakou), China (Shenzhen), China (Beijing), China (Shanghai), China (Hangzhou), China (Chengdu), UK (London), China (Heyuan), China (Ulanqab), China (Guangzhou), Philippines (Manila), Thailand (Bangkok), China (Nanjing - Local Region - Phasing out), and China (Fuzhou - Local Region - Phasing out).