Azure / azure-cli

Azure Command-Line Interface
MIT License
4.01k stars 2.98k forks source link

cannot list or purge keyvault #27694

Open karlrissland opened 1 year ago

karlrissland commented 1 year ago

Describe the bug

Issue #25444 is marked as closed, yet my team is getting the same error in AzCLI verion 2.53.1

**

image

**

Related command

az keyvault list-deleted az keyvault purge --name

Errors

(ProviderError) Resource provider 'Microsoft.KeyVault' failed to return collection response for type 'deletedManagedHSMs'. Code: ProviderError Message: Resource provider 'Microsoft.KeyVault' failed to return collection response for type 'deletedManagedHSMs'.

Issue script & Debug output

az keyvault list-deleted (ProviderError) Resource provider 'Microsoft.KeyVault' failed to return collection response for type 'deletedManagedHSMs'. Code: ProviderError Message: Resource provider 'Microsoft.KeyVault' failed to return collection response for type 'deletedManagedHSMs'.

Expected behavior

I can list and purge my keyvaults

Environment Summary

azure-cli 2.53.1

Additional context

No response

azure-client-tools-bot-prd[bot] commented 1 year ago
Hi @karlrissland Find similar issue https://github.com/Azure/azure-cli/issues/25444.
Issue title az keyvault list-deleted: Resource provider 'Microsoft.KeyVault' failed to return collection response for type 'deletedManagedHSMs'
Create time 2023-02-13
Comment number 13

Possible solution: According to the previous issue, the command az keyvault list-deleted seems to be broken for the resource type 'hsm'. However, specifying '--resource-type vault' seems to work still with v.2.45 of azure-cli. So, you can try running the command az keyvault list-deleted --subscription "<name of your subscription>" --resource-type vault to list the deleted keyvaults.


Please confirm if this resolves your issue.

yonzhan commented 1 year ago

Thank you for opening this issue, we will look into it.

microsoft-github-policy-service[bot] commented 12 months ago

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @RandalliLama, @schaabs, @jlichwa.