I am trying to set same name to all my Key Vault in different Subscription but getting below error.
New-AzureRmKeyVault : VaultAlreadyExists: The name 'AKeyVault' is already in use.
At line:1 char:1
+ New-AzureRmKeyVault -VaultName AKeyVault -ResourceGroupName PS ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : CloseError: (:) [New-AzureRmKeyVault], CloudException
+ FullyQualifiedErrorId : Microsoft.Azure.Commands.KeyVault.NewAzureKeyVault
can someone please let me know if key vault name should be unique across all subscriptions?
Yes, the Key Vault
name should be universally unique as key vault and keys/secrets inside it are accessed via https://{vault-name}.vault.azure.net
URI. It's very much like storage account name. If I create a storage account by the name nkdev
, then you can't use that name.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With