Upravit

Sdílet prostřednictvím


New-AzAvailabilitySet

Creates an Azure availability set.

Syntax

New-AzAvailabilitySet
   [-ResourceGroupName] <String>
   [-Name] <String>
   [-Location] <String>
   [[-PlatformUpdateDomainCount] <Int32>]
   [[-PlatformFaultDomainCount] <Int32>]
   [[-Sku] <String>]
   [-ProximityPlacementGroupId <String>]
   [-Tag <Hashtable>]
   [-AsJob]
   [-DefaultProfile <IAzureContextContainer>]
   [<CommonParameters>]

Description

The New-AzAvailabilitySet cmdlet creates an Azure availability set.

Examples

Example 1: Create an availability set

New-AzAvailabilitySet -ResourceGroupName "ResourceGroup11" -Name "AvailabilitySet03" -Location "West US"

This command creates an availability set named AvailabilitySet03 in the resource group named ResourceGroup11.

Parameters

-AsJob

Run cmdlet in the background and return a Job to track progress.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with azure.

Type:IAzureContextContainer
Aliases:AzContext, AzureRmContext, AzureCredential
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Location

Specifies the location for the availability set.

Type:String
Position:2
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Name

Specifies a name for the availability set.

Type:String
Aliases:ResourceName, AvailabilitySetName
Position:1
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-PlatformFaultDomainCount

Specifies the platform fault domain count.

Type:Nullable<T>[Int32]
Position:4
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-PlatformUpdateDomainCount

Specifies the platform update domain count.

Type:Nullable<T>[Int32]
Position:3
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-ProximityPlacementGroupId

The resource id of the Proximity Placement Group to use with this availability set.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-ResourceGroupName

Specifies the name of a resource group.

Type:String
Position:0
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Sku

The Name of Sku. The acceptable values for this parameter are:

  • Aligned: For managed disks
  • Classic: For unmanaged disks
Type:String
Position:5
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-Tag

Key-value pairs in the form of a hash table.

Type:Hashtable
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Inputs

String

Nullable<T>[[System.Int32, System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]

Outputs

PSAvailabilitySet