Sometimes users need to migrate classic cloud services to different subscriptions for better resources management. This blog will introduce the details and constraints of classic cloud service migration across subscriptions.
Constraints
When moving classic cloud services to a new subscription, the following restrictions apply:
Migration Steps
To move classic cloud services to a new subscription, use the REST operations to check the subscriptions validation and realize the migration.
POST https://management.azure.com/subscriptions/{sourceSubscriptionId}/providers/Microsoft.ClassicCompute/validateSubscriptionMoveAvailability?api-version=2016-04-01
In the request body, include:{
"role": "source"
}
The response for the validation operation is in the following format:
{
"status": "{status}",
"reasons": [
"reason1",
"reason2"
]
}
Example:
Subscription A is the source one and it owned the classic cloud service “yitest” with publc IP 20.xx.xx.161.
Run the validation REST API in the Postman. The source subscription passed the validation and showed “Available”.
Possible Error Message in the Source Subscription Validation Stage:
POST https://management.azure.com/subscriptions/{destinationSubscriptionId}/providers/Microsoft.ClassicCompute/validateSubscriptionMoveAvailability?api-version=2016-04-01
In the request body, include:{
"role": "target"
}
The response is in the same format as the source subscription validation.
POST https://management.azure.com/subscriptions/{subscription-id}/providers/Microsoft.ClassicCompute/moveSubscriptionResources?api-version=2016-04-01
In the request body, include:
{
"target": "/subscriptions/{target-subscription-id}"
}
Example:
Run the above REST API in the Postman and there should be no response after running It.
After sending this REST API request, the classic cloud service in the source subscription is shown below. Some information is hidden, such as site URL and public IP.
After some time, the classic cloud service in the source subscription is not available anymore.
Then the migrated classic cloud service is available now in the target subscription.
More Information
The domain name and the public IP are still the same as before, for normal cases, there should not be downtime for the cloud service during the migration.
Reference documents Move Azure Classic deployment resources | Microsoft Docs
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.