Update-AzMySqlFlexibleServer
Updates an existing MySQL flexible server. The request body can contain one to many of the properties present in the normal server definition. Use Update-AzMySqlFlexibleServerConfiguration instead if you want update server parameters such as wait_timeout or net_retry_count.
Note
This is the previous version of our documentation. Please consult the most recent version for up-to-date information.
Syntax
Update-AzMySqlFlexibleServer
-Name <String>
-ResourceGroupName <String>
[-SubscriptionId <String>]
[-AdministratorLoginPassword <SecureString>]
[-BackupRetentionDay <Int32>]
[-HighAvailability <String>]
[-MaintenanceWindow <String>]
[-ReplicationRole <String>]
[-Sku <String>]
[-SkuTier <SkuTier>]
[-StorageAutogrow <StorageAutogrow>]
[-StorageInMb <Int32>]
[-Tag <Hashtable>]
[-DefaultProfile <PSObject>]
[-AsJob]
[-NoWait]
[-Confirm]
[-WhatIf]
[<CommonParameters>]
Update-AzMySqlFlexibleServer
-InputObject <IMySqlIdentity>
[-AdministratorLoginPassword <SecureString>]
[-BackupRetentionDay <Int32>]
[-HighAvailability <String>]
[-MaintenanceWindow <String>]
[-ReplicationRole <String>]
[-Sku <String>]
[-SkuTier <SkuTier>]
[-StorageAutogrow <StorageAutogrow>]
[-StorageInMb <Int32>]
[-Tag <Hashtable>]
[-DefaultProfile <PSObject>]
[-AsJob]
[-NoWait]
[-Confirm]
[-WhatIf]
[<CommonParameters>]
Description
Updates an existing MySQL flexible server. The request body can contain one to many of the properties present in the normal server definition. Use Update-AzMySqlFlexibleServerConfiguration instead if you want update server parameters such as wait_timeout or net_retry_count.
Examples
Example 1: Update MySql server by resource group and server name
PS C:\> Update-AzMySqlFlexibleServer -ResourceGroupName PowershellMySqlTest -Name mysql-test -Sku Standard_D4ds_v4
Name Location SkuName SkuTier AdministratorLogin Version StorageSizeGb
---- -------- ------- ------- ------------------ ------- -------------
mysql-test West US 2 Standard_D2ds_v4 GeneralPurpose admin 5.7 32
This cmdlet updates MySql server by resource group and server name.
Example 2: Update MySql server by identity.
PS C:\> Get-AzMySqlFlexibleServer -ResourceGroupName PowershellMySqlTest -ServerName mysql-test | Update-AzMySqlFlexibleServer -BackupRetentionDay 23 -StorageInMb 10240
Name Location SkuName SkuTier AdministratorLogin Version StorageSizeGb
---- -------- ------- ------- ------------------ ------- -------------
mysql-test West US 2 Standard_D2ds_v4 GeneralPurpose admin 5.7 32
This cmdlet updates MySql server by identity.
Parameters
The password of the administrator login.
| Type: | SecureString |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Run the command as a job.
| Type: | SwitchParameter |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Backup retention days for the server. Day count is between 7 and 35.
| Type: | Int32 |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
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 |
The credentials, account, tenant, and subscription used for communication with Azure.
| Type: | PSObject |
| Aliases: | AzureRMContext, AzureCredential |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Enable or disable high availability feature. Default value is Disabled. Default: Disabled.
| Type: | String |
| Aliases: | HaEnabled |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Identity Parameter. To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
| Type: | IMySqlIdentity |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
Period of time (UTC) designated for maintenance. Examples: "Sun:23:30" to schedule on Sunday, 11:30pm UTC. To set back to default pass in "Disabled"
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The name of the server.
| Type: | String |
| Aliases: | ServerName |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Run the command asynchronously.
| Type: | SwitchParameter |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The replication role of the server.
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The name of the sku, typically, tier + family + cores, e.g. Burstable_B1ms, Standard_D2ds_v4
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The tier of the particular SKU. Accepted values: Burstable, GeneralPurpose, Memory Optimized. Default: Burstable.
| Type: | SkuTier |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Enable or disable Storage Auto Grow. The default value is Disabled
| Type: | StorageAutogrow |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Max storage allowed for a server.
| Type: | Int32 |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The subscription ID that identifies an Azure subscription.
| Type: | String |
| Position: | Named |
| Default value: | (Get-AzContext).Subscription.Id |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Application-specific metadata in the form of key-value pairs.
| Type: | Hashtable |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
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
Outputs
Notes
ALIASES
COMPLEX PARAMETER PROPERTIES
To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
INPUTOBJECT : Identity Parameter.
[BackupName <String>]: The name of the backup.[ConfigurationName <String>]: The name of the server configuration.[DatabaseName <String>]: The name of the database.[FirewallRuleName <String>]: The name of the server firewall rule.[Id <String>]: Resource identity path[LocationName <String>]: The name of the location.[ResourceGroupName <String>]: The name of the resource group. The name is case insensitive.[SecurityAlertPolicyName <SecurityAlertPolicyName?>]: The name of the security alert policy.[ServerName <String>]: The name of the server.[SubscriptionId <String>]: The ID of the target subscription.[VirtualNetworkRuleName <String>]: The name of the virtual network rule.