Open zoeperryman opened 5 days ago
Thank you for opening this issue, we will look into it.
Ok so I get the same error when running az sql mi update
which I guess az resource tag
must be a wrapper around.
Command
az sql mi update -g MyGroup -n MyServer --tags MyTag=TagValue
Error
(GPTargetEditionAndUnspecifiedGPV2NotAllowedInUpdateOFGPV2MI) Combination of General Purpose target edition (sku.name/sku.tier parameters) and unspecified value for the isGeneralPurposeV2 parameter is not allowed in the update operation of General Purpose V2 Managed Instance.
Code: GPTargetEditionAndUnspecifiedGPV2NotAllowedInUpdateOFGPV2MI
Message: Combination of General Purpose target edition (sku.name/sku.tier parameters) and unspecified value for the isGeneralPurposeV2 parameter is not allowed in the update operation of General Purpose V2 Managed Instance.
A work around appears to be to supply the --gpv2
parameter on the update even though it is not being updated and should be optional.
az sql mi update -g MyGroup -n MyServer --tags MyTag=TagValue --gpv2 true
Describe the bug
Attempting to update the tags on a General Purpose V2 SQL Managed Instance fails using
az resource tag
. The managed instance itself is deployed and updated via bicep templates, but at the end of our deployment script we update some tags on it.Command
az resource tag -g MyGroup -n MyServer --tags MyTag=TagValue --resource-type "Microsoft.Sql/managedInstances"
Errors:
Server Details Running
az sql mi show
on the managed instance shows the following details (snipped to just relevant details)We can see that the error is complaining that there is an
unspecified value for the isGeneralPurposeV2 parameter
. I'm not sure what the command is doing internally and why updating tags is triggering this, but you can see that the isGeneralPurposeV2 is specified on the current server details.To Reproduce:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.
az resource tag -g MyGroup -n MyServer --tags MyTag=TagValue --resource-type "Microsoft.Sql/managedInstances"
Expected Behavior
Tags are updated without an error being raised.
This works correctly on our non-V2 managed instances, or though I notice that updating the tags seems to trigger a scaling event instead of just adding some tags.
Environment Summary
Additional Context
Related Issues
This seems similar to https://github.com/Azure/azure-cli/issues/29013