az mysql
Note
This command group has commands that are defined in both Azure CLI and at least one extension. Install each extension to benefit from its extended capabilities. Learn more about extensions.
Manage Azure Database for MySQL servers.
Commands
Name | Description | Type | Status |
---|---|---|---|
az mysql db |
Manage MySQL databases on a server. |
Core | GA |
az mysql db create |
Create a MySQL database. |
Core | GA |
az mysql db delete |
Delete a database. |
Core | GA |
az mysql db list |
List the databases for a server. |
Core | GA |
az mysql db show |
Show the details of a database. |
Core | GA |
az mysql down |
Delete the MySQL server and its cached information. |
Extension | Deprecated |
az mysql flexible-server |
Manage Azure Database for MySQL Flexible Servers. |
Core and Extension | GA |
az mysql flexible-server ad-admin |
Manage server Active Directory administrator. |
Core | GA |
az mysql flexible-server ad-admin create |
Create an Active Directory administrator. |
Core | GA |
az mysql flexible-server ad-admin delete |
Delete an Active Directory administrator. |
Core | GA |
az mysql flexible-server ad-admin list |
List all Active Directory administrators. |
Core | GA |
az mysql flexible-server ad-admin show |
Get an Active Directory administrator. |
Core | GA |
az mysql flexible-server ad-admin wait |
Wait for the Active Directory administrator to satisfy certain conditions. |
Core | GA |
az mysql flexible-server advanced-threat-protection-setting |
Manage the server's advanced threat protection setting. |
Core | GA |
az mysql flexible-server advanced-threat-protection-setting show |
Get the server's advanced threat protection setting. |
Core | GA |
az mysql flexible-server advanced-threat-protection-setting update |
Update the server's advanced threat protection setting. |
Core | GA |
az mysql flexible-server backup |
Manage flexible server backups. |
Core | GA |
az mysql flexible-server backup create |
Create a backup for a given server with specified backup name. |
Core | GA |
az mysql flexible-server backup list |
List all the backups for a given server. |
Core | GA |
az mysql flexible-server backup show |
Show the details of a specific backup for a given server. |
Core | GA |
az mysql flexible-server connect |
Connect to a flexible server. |
Extension | GA |
az mysql flexible-server create |
Create a MySQL flexible server. |
Core | GA |
az mysql flexible-server db |
Manage MySQL databases on a flexible server. |
Core | GA |
az mysql flexible-server db create |
Create a MySQL database on a flexible server. |
Core | GA |
az mysql flexible-server db delete |
Delete a database on a flexible server. |
Core | GA |
az mysql flexible-server db list |
List the databases for a flexible server. |
Core | GA |
az mysql flexible-server db show |
Show the details of a database. |
Core | GA |
az mysql flexible-server delete |
Delete a flexible server. |
Core | GA |
az mysql flexible-server deploy |
Enable and run GitHub Actions workflow for MySQL server. |
Core | GA |
az mysql flexible-server deploy run |
Run an existing workflow in your github repository. |
Core | GA |
az mysql flexible-server deploy setup |
Create GitHub Actions workflow file for MySQL server. |
Core | GA |
az mysql flexible-server detach-vnet |
Detach vnet for a flexible server. |
Core | GA |
az mysql flexible-server execute |
Connect to a flexible server. |
Extension | GA |
az mysql flexible-server export |
Manage export backup on a server. |
Core | Preview |
az mysql flexible-server export create |
Create an export backup for a given server with specified backup name. |
Core | Preview |
az mysql flexible-server firewall-rule |
Manage firewall rules for a server. |
Core | GA |
az mysql flexible-server firewall-rule create |
Create a new firewall rule for a flexible server. |
Core | GA |
az mysql flexible-server firewall-rule delete |
Delete a firewall rule. |
Core | GA |
az mysql flexible-server firewall-rule list |
List all firewall rules for a flexible server. |
Core | GA |
az mysql flexible-server firewall-rule show |
Get the details of a firewall rule. |
Core | GA |
az mysql flexible-server firewall-rule update |
Update a firewall rule. |
Core | GA |
az mysql flexible-server geo-restore |
Geo-restore a flexible server from backup. |
Core | GA |
az mysql flexible-server gtid |
Manage GTID on a server. |
Core | GA |
az mysql flexible-server gtid reset |
Resets GTID on a server. |
Core | GA |
az mysql flexible-server identity |
Manage server user assigned identities. |
Core | GA |
az mysql flexible-server identity assign |
Add user asigned managed identities to the server. |
Core | GA |
az mysql flexible-server identity list |
List all user assigned managed identities from the server. |
Core | GA |
az mysql flexible-server identity remove |
Remove user asigned managed identites from the server. |
Core | GA |
az mysql flexible-server identity show |
Get an user assigned managed identity from the server. |
Core | GA |
az mysql flexible-server import |
Manage import workflows for MySQL Flexible Servers. |
Core | GA |
az mysql flexible-server import create |
Create a new import workflow for flexible server. |
Core | GA |
az mysql flexible-server import stop-replication |
To stop replication between the source single server and target flexible server. |
Core | GA |
az mysql flexible-server list |
List available flexible servers. |
Core | GA |
az mysql flexible-server list-skus |
Lists available sku's in the given region. |
Core | GA |
az mysql flexible-server maintenance |
Manage maintenance on a flexible server. |
Core | GA |
az mysql flexible-server maintenance list |
List all of the maintenances of a flexible server. |
Core | GA |
az mysql flexible-server maintenance reschedule |
Reschedule the ongoing planned maintenance of a flexible server. |
Core | GA |
az mysql flexible-server maintenance show |
Get the specific maintenance of a flexible server by maintenance name. |
Core | GA |
az mysql flexible-server parameter |
Commands for managing server parameter values for flexible server. |
Core | GA |
az mysql flexible-server parameter list |
List the parameter values for a flexible server. |
Core | GA |
az mysql flexible-server parameter set |
Update the parameter of a flexible server. |
Core | GA |
az mysql flexible-server parameter set-batch |
Batch update parameters of a flexible server. |
Core | GA |
az mysql flexible-server parameter show |
Get the parameter for a flexible server.". |
Core | GA |
az mysql flexible-server replica |
Manage read replicas. |
Core | GA |
az mysql flexible-server replica create |
Create a read replica for a server. |
Core | GA |
az mysql flexible-server replica list |
List all read replicas for a given server. |
Core | GA |
az mysql flexible-server replica stop-replication |
Stop replication to a read replica and make it a read/write server. |
Core | GA |
az mysql flexible-server restart |
Restart a flexible server. |
Core | GA |
az mysql flexible-server restore |
Restore a flexible server from backup. |
Core | GA |
az mysql flexible-server server-logs |
Manage server logs. |
Core | GA |
az mysql flexible-server server-logs download |
Download log files. |
Core | GA |
az mysql flexible-server server-logs list |
List log files for a server. |
Core | GA |
az mysql flexible-server show |
Get the details of a flexible server. |
Core | GA |
az mysql flexible-server show-connection-string |
Show the connection strings for a MySQL flexible-server database. |
Core | GA |
az mysql flexible-server start |
Start a flexible server. |
Core | GA |
az mysql flexible-server stop |
Stop a flexible server. |
Core | GA |
az mysql flexible-server update |
Update a flexible server. |
Core | GA |
az mysql flexible-server upgrade |
Upgrade the major version of a flexible server. |
Core | GA |
az mysql flexible-server wait |
Wait for the flexible server to satisfy certain conditions. |
Core | GA |
az mysql server |
Manage MySQL servers. |
Core | GA |
az mysql server-logs |
Manage server logs. |
Core | GA |
az mysql server-logs download |
Download log files. |
Core | GA |
az mysql server-logs list |
List log files for a server. |
Core | GA |
az mysql server ad-admin |
Manage a MySQL server's Active Directory administrator. |
Core | GA |
az mysql server ad-admin create |
Create an Active Directory administrator for MySQL server. |
Core | GA |
az mysql server ad-admin delete |
Delete an Active Directory Administrator for MySQL server. |
Core | GA |
az mysql server ad-admin list |
List all Active Directory Administrators for MySQL server. |
Core | GA |
az mysql server ad-admin show |
Get Active Directory Administrator information for a MySQL server. |
Core | GA |
az mysql server ad-admin wait |
Place the CLI in a waiting state until a condition of the MySQL server Active Directory Administrator is met. |
Core | GA |
az mysql server configuration |
Manage configuration values for a server. |
Core | GA |
az mysql server configuration list |
List the configuration values for a server. |
Core | GA |
az mysql server configuration set |
Update the configuration of a server. |
Core | GA |
az mysql server configuration show |
Get the configuration for a server.". |
Core | GA |
az mysql server create |
Create a server. |
Core | GA |
az mysql server delete |
Delete a server. |
Core | GA |
az mysql server firewall-rule |
Manage firewall rules for a server. |
Core | GA |
az mysql server firewall-rule create |
Create a new firewall rule for a server. |
Core | GA |
az mysql server firewall-rule delete |
Delete a firewall rule. |
Core | GA |
az mysql server firewall-rule list |
List all firewall rules for a server. |
Core | GA |
az mysql server firewall-rule show |
Get the details of a firewall rule. |
Core | GA |
az mysql server firewall-rule update |
Update a firewall rule. |
Core | GA |
az mysql server georestore |
Geo-restore a server from backup. |
Core | GA |
az mysql server key |
Manage MySQL server keys. |
Core | GA |
az mysql server key create |
Create server key. |
Core | GA |
az mysql server key delete |
Delete server key. |
Core | GA |
az mysql server key list |
Gets a list of Server keys. |
Core | GA |
az mysql server key show |
Show server key. |
Core | GA |
az mysql server list |
List available servers. |
Core | GA |
az mysql server list-skus |
List available sku's in the given region. |
Core | GA |
az mysql server private-endpoint-connection |
Manage MySQL server private endpoint connections. |
Core | GA |
az mysql server private-endpoint-connection approve |
Approve the specified private endpoint connection associated with a MySQL server. |
Core | GA |
az mysql server private-endpoint-connection delete |
Delete the specified private endpoint connection associated with a MySQL server. |
Core | GA |
az mysql server private-endpoint-connection reject |
Reject the specified private endpoint connection associated with a MySQL server. |
Core | GA |
az mysql server private-endpoint-connection show |
Show details of a private endpoint connection associated with a MySQL server. |
Core | GA |
az mysql server private-link-resource |
Manage MySQL server private link resources. |
Core | GA |
az mysql server private-link-resource list |
List the private link resources supported for a MySQL server. |
Core | GA |
az mysql server replica |
Manage read replicas. |
Core | GA |
az mysql server replica create |
Create a read replica for a server. |
Core | GA |
az mysql server replica list |
List all read replicas for a given server. |
Core | GA |
az mysql server replica stop |
Stop replication to a read replica and make it a read/write server. |
Core | GA |
az mysql server restart |
Restart a server. |
Core | GA |
az mysql server restore |
Restore a server from backup. |
Core | GA |
az mysql server show |
Get the details of a server. |
Core | GA |
az mysql server show-connection-string |
Show the connection strings for a MySQL server database. |
Core | GA |
az mysql server start |
Start a stopped server. |
Core | GA |
az mysql server stop |
Stop a running server. |
Core | GA |
az mysql server update |
Update a server. |
Core | GA |
az mysql server upgrade |
Upgrade mysql server to a higher version, like 5.6 to 5.7. |
Core | GA |
az mysql server vnet-rule |
Manage a server's virtual network rules. |
Core | GA |
az mysql server vnet-rule create |
Create a virtual network rule to allows access to a MySQL server. |
Core | GA |
az mysql server vnet-rule delete |
Deletes the virtual network rule with the given name. |
Core | GA |
az mysql server vnet-rule list |
Gets a list of virtual network rules in a server. |
Core | GA |
az mysql server vnet-rule show |
Gets a virtual network rule. |
Core | GA |
az mysql server vnet-rule update |
Update a virtual network rule. |
Core | GA |
az mysql server wait |
Wait for server to satisfy certain conditions. |
Core | GA |
az mysql show-connection-string |
Show the connection strings for a MySQL server database. |
Extension | Deprecated |
az mysql up |
Set up an Azure Database for MySQL server and configurations. |
Extension | Deprecated |
az mysql down
'db-up' extension will be retired on November 20, 2024, please consider using the create command associated with the respective database
Delete the MySQL server and its cached information.
az mysql down [--delete-group]
[--no-wait]
[--resource-group]
[--server-name]
[--yes]
Examples
Delete the server and the cached data, aside from the resource group.
az mysql down
Delete the resource group and the full cache.
az mysql down --delete-group
Optional Parameters
Delete the resource group.
Do not wait for the long-running operation to finish.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Name of the server.
Do not prompt for confirmation.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az mysql show-connection-string
'db-up' extension will be retired on November 20, 2024, please consider using the create command associated with the respective database
Show the connection strings for a MySQL server database.
az mysql show-connection-string [--admin-password]
[--admin-user]
[--database-name]
[--server-name]
Optional Parameters
The login password of the administrator.
The login username of the administrator.
The name of a database.
Name of the server.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az mysql up
'db-up' extension will be retired on November 20, 2024, please consider using the create command associated with the respective database
Set up an Azure Database for MySQL server and configurations.
az mysql up [--admin-password]
[--admin-user]
[--backup-retention]
[--database-name]
[--generate-password]
[--geo-redundant-backup {Disabled, Enabled}]
[--location]
[--resource-group]
[--server-name]
[--sku-name]
[--ssl-enforcement {Disabled, Enabled}]
[--storage-size]
[--tags]
[--version]
Examples
Ensure that an Azure Database for MySQL server is up and running and configured for immediate use.
az mysql up
To override default names, provide parameters indicating desired values/existing resources.
az mysql up -g MyResourceGroup -s MyServer -d MyDatabase -u MyUsername -p MyPassword
Optional Parameters
The login password of the administrator. Minimum 8 characters and maximum 128 characters. Password must contain characters from three of the following categories: English uppercase letters, English lowercase letters, numbers, and non-alphanumeric characters.Your password cannot contain all or part of the login name. Part of a login name is defined as three or more consecutive alphanumeric characters.
The login username of the administrator.
The number of days a backup is retained.
The name of a database to initialize.
Generate a password.
Enable Geo-redundant or not for server backup.
Location. Values from: az account list-locations
. You can configure the default location using az configure --defaults location=<location>
.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Name of the server.
The name of the sku, typically, tier + family + cores, e.g. B_Gen4_1, GP_Gen5_8.
Enable ssl enforcement or not when connect to server.
The max storage size of the server. Unit is megabytes.
Space-separated tags: key[=value] [key[=value] ...]. Use "" to clear existing tags.
Server version.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.