Complete the code to create an Azure Database for MySQL server using Azure CLI.
az mysql server create --resource-group myResourceGroup --name mydemoserver --location eastus --admin-user myadmin [1] --sku-name GP_Gen5_2The --admin-password flag is used to specify the administrator password when creating an Azure Database for MySQL server.
Complete the code to configure the firewall rule to allow access from a specific IP address.
az mysql server firewall-rule create --resource-group myResourceGroup --server mydemoserver --name AllowMyIP --start-ip-address [1] --end-ip-address [1]
The --start-ip-address and --end-ip-address flags specify the IP range allowed to access the MySQL server. To allow a single IP, both should be the same.
Fix the error in the command to update the MySQL server's backup retention period.
az mysql server update --resource-group myResourceGroup --name mydemoserver --backup-retention [1]The --backup-retention flag expects an integer number of days, such as 30. Text or units like 'days' are invalid.
Fill both blanks to create a new database on the MySQL server with the correct charset and collation.
az mysql db create --resource-group myResourceGroup --server-name mydemoserver --name mydatabase --charset [1] --collation [2]
utf8 charset which is limited.For best compatibility and support of emojis and special characters, use utf8mb4 charset and utf8mb4_unicode_ci collation.
Fill all three blanks to configure the MySQL server's performance tier, storage size, and backup retention.
az mysql server update --resource-group myResourceGroup --name mydemoserver --sku-name [1] --storage-size [2] --backup-retention [3]
The --sku-name sets the performance tier and compute size, --storage-size is in MB (5120 MB = 5 GB), and --backup-retention is the number of days backups are kept.