Set-​Azure​Rm​Sql​Database​Failover​Group

The Cmdlet that sets properties of the Azure SQL Failover Group

Syntax

Set-AzureRmSqlDatabaseFailoverGroup
   [-AllowReadOnlyFailoverToPrimary <AllowReadOnlyFailoverToPrimary>]
   -FailoverGroupName <String>
   [-FailoverPolicy <FailoverPolicy>]
   [-GracePeriodWithDataLossHours <Int32>]
   -ResourceGroupName <String>
   -ServerName <String>
   [-Tags <Hashtable>]
   [-Confirm]
   [-WhatIf]
   [<CommonParameters>]

Description

This command modifies the configuration of the failover group. Adding or removing servers and databases requires using the specialized cmdlets.

Examples

Example 1

PS C:\> Set-AzureRmSqlDatabaseFailoverGroup -FailoverGroupName testfg -PartnerServerName testsvr -FailoverPolicy Automatic -GracePeriodWithDataLossHours 1 -AllowReadOnlyFailoverToPrimary Disabled -ServerName test1 -ResourceGroupName rg2

Required Parameters

-FailoverGroupName

The name of the Azure SQL Failover Group.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-ResourceGroupName

The name of the resource group.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-ServerName

The name of the Azure SQL Server the Failover Group is in.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Optional Parameters

-AllowReadOnlyFailoverToPrimary

The failover policy for read only endpoint of the failover group.

Type:AllowReadOnlyFailoverToPrimary
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-FailoverPolicy

The failover policy without data loss for the failover group.

Type:FailoverPolicy
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-GracePeriodWithDataLossHours

The grace period for failover with data loss of the failover group.

Type:Int32
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Tags

The tag to associate with the Azure Sql Failover Group

Type:Hashtable
Aliases:Tag
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

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

Inputs

System.String

Outputs

System.Object