New-AzureStorageAccount

New-AzureStorageAccount

Creates a storage account.

Syntax

Parameter Set: Default
New-AzureStorageAccount [-ResourceGroupName] <String> [-Name] <String> [-Type] <String> {Standard_LRS | Standard_ZRS | Standard_GRS | Standard_RAGRS | Premium_LRS} [-Location] <String> [-Profile <AzureProfile> ] [ <CommonParameters>]

Detailed Description

The New-AzureStorageAccount cmdlet creates a storage account in Azure.

Parameters

-Location<String>

Specifies the location for the new storage account.

Aliases

none

Required?

true

Position?

4

Default Value

none

Accept Pipeline Input?

true(ByPropertyName)

Accept Wildcard Characters?

false

-Name<String>

Specifies the name of the new storage account.

Aliases

StorageAccountName,AccountName

Required?

true

Position?

2

Default Value

none

Accept Pipeline Input?

true(ByPropertyName)

Accept Wildcard Characters?

false

-Profile<AzureProfile>

Specifies an Azure profile.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ResourceGroupName<String>

Specifies the name of a resource group.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

true(ByPropertyName)

Accept Wildcard Characters?

false

-Type<String>

Specifies the type of storage account to create. Valid values are:

-- Standard_LRS. Locally-redundant storage.
-- Standard_ZRS. Zone-redundant storage.
-- Standard_GRS. Geo-redundant storage.
-- Standard_RAGRS. Read access geo-redundant storage.

Aliases

StorageAccountType,AccountType

Required?

true

Position?

3

Default Value

none

Accept Pipeline Input?

true(ByPropertyName)

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see    about_CommonParameters (http://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

Examples

Example 1: Create a geo-redundant storage account

This command creates a geo-redundant storage account in the resource group named ResourceGroup11.

PS C:\> New-AzureStorageAccount -ResourceGroupName "ResourceGroup11" -Name "StorageAccount17" -Location "West US" -AccountType "Standard_GRS"

Get-AzureStorageAccount

Remove-AzureStorageAccount

Set-AzureStorageAccount