Failed to move resource due to InvalidApiVersion

Tsz Hin Jason Mok 15 Reputation points
2023-05-02T10:22:19.33+00:00

Hi,

I have some issue when moving resources from a subscription to another subscription on Azure Portal, with error message below:

(Code: ResourceMoveProviderValidationFailed) The api-version '2023-01-01-privatepreview' is invalid. The supported versions are '2020-02-14-privatepreview','2020-02-14-preview','2020-11-05-preview','2021-04-10-preview','2021-04-10-privatepreview','2020-10-05-privatepreview','2021-05-01-privatepreview','2021-06-01-preview','2021-06-01','2021-06-15-privatepreview','2022-01-20-preview','2022-03-08-privatepreview','2022-03-08-preview','2022-05-01-privatepreview','2022-05-01-preview','2022-06-01-privatepreview','2022-11-01-preview','2022-12-01','2023-01-01-preview','2.0'. (Code: InvalidApiVersionParameter, Target: Microsoft.DBforPostgreSQL/flexibleServers) (Code: ResourceMoveProviderValidationFailed)

There is no PostgreSQL in the resources group.

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,364 questions
Azure Resource Mover
Azure Resource Mover
An Azure service used for moving multiple resources between Azure regions.
217 questions
{count} votes

3 answers

Sort by: Most helpful
  1. Keith Nelson 5 Reputation points
    2023-05-02T19:51:26.8366667+00:00

    I was able to get my resources moved by using CLI. I followed these instructions:

    https://adamtheautomator.com/rename-azure-resource-group/

    In step 2 it uses a command to build a list of resources. That created a "ResourceNotTopLevel" error when I tried to do the move. To fix I put in the id of the main resource I was trying to move:

    az resource move --destination-subscription-id {sub-id} --destination-group {des-group-name} --ids /subscriptions/{sub-id}/resourceGroups/{RS-Group}/providers/Microsoft.Compute/virtualMachines/{name}

    Then I got "MissingMoveDependentResources" errors. I manually listed every child resource that needed to be moved:

    az resource move --destination-subscription-id {sub-id} --destination-group {des-group-name} --ids \

    /subscriptions/{sub-id}/resourceGroups/{RS-Group}/providers/Microsoft.Compute/virtualMachines/{name} \

    /subscriptions/{sub-id}/resourceGroups/{RS-Group}/providers/Microsoft.Compute/virtualMachines/{name} \

    /subscriptions/{sub-id}/resourceGroups/{RS-Group}/providers/Microsoft.Compute/virtualMachines/{name} \

    /subscriptions/{sub-id}/resourceGroups/{RS-Group}/providers/Microsoft.Compute/virtualMachines/{name}

    1 person found this answer helpful.
    0 comments No comments

  2. Oscar Bautista 0 Reputation points
    2023-05-02T22:55:09.9566667+00:00

    I have the same problem:

    {"message":"Error al validar el movimiento del recurso. Vea los detalles. Información de diagnóstico: marca de tiempo "20230501T153242Z", id. de suscripción "12377e06-fb36-4ffd-8ea5-xxxxxxxxx", id. de seguimiento "27d2611e-2968-4c3f-9a36-2xxxxxxxxx", id. de correlación de la solicitud "b9eb1181-9ed5-4008-9f84-44ca757fb7aa". (Código: ResourceMoveProviderValidationFailed) The api-version '2023-01-01-privatepreview' is invalid. The supported versions are '2020-02-14-privatepreview','2020-02-14-preview','2020-11-05-preview','2021-04-10-preview','2021-04-10-privatepreview','2020-10-05-privatepreview','2021-05-01-privatepreview','2021-06-01-preview','2021-06-01','2021-06-15-privatepreview','2022-01-20-preview','2022-03-08-privatepreview','2022-03-08-preview','2022-05-01-privatepreview','2022-05-01-preview','2022-06-01-privatepreview','2022-11-01-preview','2022-12-01','2023-01-01-preview','2.0'. (código: InvalidApiVersionParameter; destino: Microsoft.DBforPostgreSQL/flexibleServers)","name":"a559b557-2d90-4777-b4e2-1aaac50e901b","code":"ResourceMoveProviderValidationFailed","status":409}

    0 comments No comments

  3. Danilo Zappa 5 Reputation points
    2023-05-03T16:15:07.3566667+00:00

    Today i have migrate without problem