Skip to content

Commit c2145fd

Browse files
author
Sudheesh Narayanaswamy
committed
Server Logs
1 parent 51e9c9b commit c2145fd

File tree

3 files changed

+27
-27
lines changed

3 files changed

+27
-27
lines changed

articles/mysql/flexible-server/how-to-server-logs-cli.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,5 +66,5 @@ az mysql flexible-server server-logs download --resource-group <myresourcegroup>
6666
```
6767

6868
## Next Steps
69-
- To enable and disable Server logs from portal, click [here.](./how-to-server-logs-portal.md)
69+
- To enable and disable Server logs from portal, you can refer to the [article].(./how-to-server-logs-portal.md)
7070
- Learn more about [Configure slow logs using Azure CLI](./tutorial-query-performance-insights.md#configure-slow-query-logs-by-using-the-azure-cli)

articles/mysql/flexible-server/how-to-server-logs-portal.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: 'How to enable and download server logs for Azure Database for MySQL - Flexible Server'
3-
description: This article describes how to download and list server logs using Azure Portal.
3+
description: This article describes how to download and list server logs using Azure portal.
44
ms.service: mysql
55
ms.subservice: flexible-server
66
ms.topic: conceptual
@@ -23,7 +23,7 @@ In this tutorial, you’ll learn how to:
2323

2424
## Prerequisites
2525

26-
To complete this tutorial, you an existing Azure Database for MySQL flexible server. If you need to create a new server, see [Create an Azure Database for MySQL flexible server](./quickstart-create-server-portal.md).
26+
To complete this tutorial, you need an existing Azure Database for MySQL flexible server. If you need to create a new server, see [Create an Azure Database for MySQL flexible server](./quickstart-create-server-portal.md).
2727

2828
## Enable Server logs
2929

@@ -60,7 +60,7 @@ To download server logs, perform the following steps.
6060

6161
:::image type="content" source="./media/how-to-server-logs-portal/4-how-to-serverlog.png" alt-text="Server Logs - Download":::
6262

63-
For HA enabled Azure database for MySQL Flexible server, server logs for standby server can be identified by additional four-letter identifier after the hostname of the server as shown below.
63+
For HA enabled Azure database for MySQL Flexible server, server logs for standby server can be identified by another four-letter identifier after the hostname of the server as shown below.
6464

6565
:::image type="content" source="./media/how-to-server-logs-portal/5-how-to-serverlog.png" alt-text="Server Logs - HA -logs":::
6666

@@ -71,9 +71,9 @@ To download server logs, perform the following steps.
7171

7272
## Disable Server Logs
7373

74-
1. From your Azure portal, select Server logs from Monitoring server blade.
74+
1. From your Azure portal, select Server logs from Monitoring server pane.
7575

76-
2. For disabling Server logs to file, Uncheck Enable. (This will disable logging for all the log_types available)
76+
2. For disabling Server logs to file, Uncheck Enable. (The setting will disable logging for all the log_types available)
7777

7878
:::image type="content" source="./media/how-to-server-logs-portal/7-how-to-serverlog.png" alt-text="Server Logs - Disable":::
7979

articles/mysql/single-server/concepts-migrate-dump-restore.md

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,9 @@ To step through this how-to guide, you need to have:
3434
Most common use-cases are:
3535

3636
- **Moving from other managed service provider** - Most managed service provider may not provide access to the physical storage file for security reasons so logical backup and restore is the only option to migrate.
37-
- **Migrating from on-premises environment or Virtual machine** - Azure Database for MySQL doesn't support restore of physical backups which makes logical backup and restore as the ONLY approach.
38-
- **Moving your backup storage from locally redundant to geo-redundant storage** - Azure Database for MySQL allows configuring locally redundant or geo-redundant storage for backup is only allowed during server create. Once the server is provisioned, you cannot change the backup storage redundancy option. In order to move your backup storage from locally redundant storage to geo-redundant storage, dump and restore is the ONLY option.
39-
- **Migrating from alternative storage engines to InnoDB** - Azure Database for MySQL supports only InnoDB Storage engine, and therefore does not support alternative storage engines. If your tables are configured with other storage engines, convert them into the InnoDB engine format before migration to Azure Database for MySQL.
37+
- **Migrating from on-premises environment or Virtual machine** - Azure Database for MySQL doesn't support restore of physical backups, which makes logical backup and restore as the ONLY approach.
38+
- **Moving your backup storage from locally redundant to geo-redundant storage** - Azure Database for MySQL allows configuring locally redundant or geo-redundant storage for backup is only allowed during server create. Once the server is provisioned, you can't change the backup storage redundancy option. In order to move your backup storage from locally redundant storage to geo-redundant storage, dump and restore is the ONLY option.
39+
- **Migrating from alternative storage engines to InnoDB** - Azure Database for MySQL supports only InnoDB Storage engine, and therefore doesn't support alternative storage engines. If your tables are configured with other storage engines, convert them into the InnoDB engine format before migration to Azure Database for MySQL.
4040

4141
For example, if you have a WordPress or WebApp using the MyISAM tables, first convert those tables by migrating into InnoDB format before restoring to Azure Database for MySQL. Use the clause `ENGINE=InnoDB` to set the engine used when creating a new table, then transfer the data into the compatible table before the restore.
4242

@@ -73,13 +73,13 @@ Add the connection information into your MySQL Workbench.
7373

7474
## Preparing the target Azure Database for MySQL server for fast data loads
7575
To prepare the target Azure Database for MySQL server for faster data loads, the following server parameters and configuration needs to be changed.
76-
- max_allowed_packet – set to 1073741824 (i.e. 1GB) to prevent any overflow issue due to long rows.
76+
- max_allowed_packet – set to 1073741824 (that is, 1 GB) to prevent any overflow issue due to long rows.
7777
- slow_query_log – set to OFF to turn off the slow query log. This will eliminate the overhead caused by slow query logging during data loads.
7878
- query_store_capture_mode – set to NONE to turn off the Query Store. This will eliminate the overhead caused by sampling activities by Query Store.
7979
- innodb_buffer_pool_size – Scale up the server to 32 vCore Memory Optimized SKU from the Pricing tier of the portal during migration to increase the innodb_buffer_pool_size. Innodb_buffer_pool_size can only be increased by scaling up compute for Azure Database for MySQL server.
8080
- innodb_io_capacity & innodb_io_capacity_max - Change to 9000 from the Server parameters in Azure portal to improve the IO utilization to optimize for migration speed.
8181
- innodb_write_io_threads & innodb_write_io_threads - Change to 4 from the Server parameters in Azure portal to improve the speed of migration.
82-
- Scale up Storage tier – The IOPs for Azure Database for MySQL server increases progressively with the increase in storage tier. For faster loads, you may want to increase the storage tier to increase the IOPs provisioned. Please do remember the storage can only be scaled up, not down.
82+
- Scale up Storage tier – The IOPs for Azure Database for MySQL server increases progressively with the increase in storage tier. For faster loads, you may want to increase the storage tier to increase the IOPs provisioned. Do remember the storage can only be scaled up, not down.
8383

8484
Once the migration is completed, you can revert back the server parameters and compute tier configuration to its previous values.
8585

@@ -93,12 +93,12 @@ $ mysqldump --opt -u [uname] -p[pass] [dbname] > [backupfile.sql]
9393

9494
The parameters to provide are:
9595
- [uname] Your database username
96-
- [pass] The password for your database (note there is no space between -p and the password)
96+
- [pass] The password for your database (note there's no space between -p and the password)
9797
- [dbname] The name of your database
9898
- [backupfile.sql] The filename for your database backup
9999
- [--opt] The mysqldump option
100100

101-
For example, to back up a database named 'testdb' on your MySQL server with the username 'testuser' and with no password to a file testdb_backup.sql, use the following command. The command backs up the `testdb` database into a file called `testdb_backup.sql`, which contains all the SQL statements needed to re-create the database. Make sure that the username 'testuser' has at least the SELECT privilege for dumped tables, SHOW VIEW for dumped views, TRIGGER for dumped triggers, and LOCK TABLES if the --single-transaction option is not used.
101+
For example, to back up a database named 'testdb' on your MySQL server with the username 'testuser' and with no password to a file testdb_backup.sql, use the following command. The command backs up the `testdb` database into a file called `testdb_backup.sql`, which contains all the SQL statements needed to re-create the database. Make sure that the username 'testuser' has at least the SELECT privilege for dumped tables, SHOW VIEW for dumped views, TRIGGER for dumped triggers, and LOCK TABLES if the `--single-transaction` option isn't used.
102102

103103
```bash
104104
GRANT SELECT, LOCK TABLES, SHOW VIEW ON *.* TO 'testuser'@'hostname' IDENTIFIED BY 'password';
@@ -113,24 +113,24 @@ To select specific tables in your database to back up, list the table names sepa
113113
```bash
114114
$ mysqldump -u root -p testdb table1 table2 > testdb_tables_backup.sql
115115
```
116-
To back up more than one database at once, use the --database switch and list the database names separated by spaces.
116+
To back up more than one database at once, use the `--database` switch and list the database names separated by spaces.
117117
```bash
118118
$ mysqldump -u root -p --databases testdb1 testdb3 testdb5 > testdb135_backup.sql
119119
```
120120

121121
### Restore your MySQL database using command-line
122-
Once you have created the target database, you can use the mysql command to restore the data into the specific newly created database from the dump file.
122+
Once you've created the target database, you can use the mysql command to restore the data into the specific newly created database from the dump file.
123123
```bash
124124
mysql -h [hostname] -u [uname] -p[pass] [db_to_restore] < [backupfile.sql]
125125
```
126126
In this example, restore the data into the newly created database on the target Azure Database for MySQL server.
127127

128-
Here is an example for how to use this **mysql** for **Single Server** :
128+
Here's an example for how to use this **mysql** for **Single Server** :
129129

130130
```bash
131131
$ mysql -h mydemoserver.mysql.database.azure.com -u myadmin@mydemoserver -p testdb < testdb_backup.sql
132132
```
133-
Here is an example for how to use this **mysql** for **Flexible Server** :
133+
Here's an example for how to use this **mysql** for **Flexible Server** :
134134

135135
```bash
136136
$ mysql -h mydemoserver.mysql.database.azure.com -u myadmin -p testdb < testdb_backup.sql
@@ -148,25 +148,25 @@ Follow these steps to dump and restore a database using PHPMyadmin.
148148
### Export with PHPMyadmin
149149
To export, you can use the common tool phpMyAdmin, which you may already have installed locally in your environment. To export your MySQL database using PHPMyAdmin:
150150
1. Open phpMyAdmin.
151-
2. Select your database. Click the database name in the list on the left.
152-
3. Click the **Export** link. A new page appears to view the dump of database.
153-
4. In the Export area, click the **Select All** link to choose the tables in your database.
154-
5. In the SQL options area, click the appropriate options.
155-
6. Click the **Save as file** option and the corresponding compression option and then click the **Go** button. A dialog box should appear prompting you to save the file locally.
151+
2. Select your database. Select the database name in the list on the left.
152+
3. Select the **Export** link. A new page appears to view the dump of database.
153+
4. In the Export area, select the **Select All** link to choose the tables in your database.
154+
5. In the SQL options area, select the appropriate options.
155+
6. Select the **Save as file** option and the corresponding compression option and then select the **Go** button. A dialog box should appear prompting you to save the file locally.
156156

157157
### Import using PHPMyAdmin
158158
Importing your database is similar to exporting. Do the following actions:
159159
1. Open phpMyAdmin.
160-
2. In the phpMyAdmin setup page, click **Add** to add your Azure Database for MySQL server. Provide the connection details and login information.
161-
3. Create an appropriately named database and select it on the left of the screen. To rewrite the existing database, click the database name, select all the check boxes beside the table names, and select **Drop** to delete the existing tables.
162-
4. Click the **SQL** link to show the page where you can type in SQL commands, or upload your SQL file.
160+
2. In the phpMyAdmin setup page, select **Add** to add your Azure Database for MySQL server. Provide the connection details and log in information.
161+
3. Create an appropriately named database and select it on the left of the screen. To rewrite the existing database, select the database name, select all the check boxes beside the table names, and select **Drop** to delete the existing tables.
162+
4. Select the **SQL** link to show the page where you can type in SQL commands, or upload your SQL file.
163163
5. Use the **browse** button to find the database file.
164-
6. Click the **Go** button to export the backup, execute the SQL commands, and re-create your database.
164+
6. Select the **Go** button to export the backup, execute the SQL commands, and re-create your database.
165165

166166
## Known Issues
167167
For known issues, tips and tricks, we recommend you to look at our [techcommunity blog](https://techcommunity.microsoft.com/t5/azure-database-for-mysql/tips-and-tricks-in-using-mysqldump-and-mysql-restore-to-azure/ba-p/916912).
168168

169169
## Next steps
170170
- [Connect applications to Azure Database for MySQL](./how-to-connection-string.md).
171171
- For more information about migrating databases to Azure Database for MySQL, see the [Database Migration Guide](https://github.com/Azure/azure-mysql/tree/master/MigrationGuide).
172-
- If you are looking to migrate large databases with database sizes more than 1 TBs, you may want to consider using community tools like **mydumper/myloader** which supports parallel export and import. Learn [how to migrate large MySQL databases](https://techcommunity.microsoft.com/t5/azure-database-for-mysql/best-practices-for-migrating-large-databases-to-azure-database/ba-p/1362699).
172+
- If you're looking to migrate large databases with database sizes more than 1 TBs, you may want to consider using community tools like **mydumper/myloader** which supports parallel export and import. Learn [how to migrate large MySQL databases](https://techcommunity.microsoft.com/t5/azure-database-for-mysql/best-practices-for-migrating-large-databases-to-azure-database/ba-p/1362699).

0 commit comments

Comments
 (0)