Azure Database for MySQL - Flexible Server monitoring data reference
Note
This article contains references to the term slave, a term that Microsoft no longer uses. When the term is removed from the software, we'll remove it from this article.
This article contains all the monitoring reference information for this service.
See Monitor Azure Database for MySQL - Flexible Server for details on the data you can collect for Azure Database for MySQL - Flexible Server and how to use it.
Metrics
This section lists all the automatically collected platform metrics for this service. These metrics are also part of the global list of all platform metrics supported in Azure Monitor.
For information on metric retention, see Azure Monitor Metrics overview.
Supported metrics for Microsoft.DBforMySQL\flexibleServers
The following table lists the metrics available for the Microsoft.DBforMySQL\flexibleServers resource type.
- All columns might not be present in every table.
- Some columns might be beyond the viewing area of the page. Select Expand table to view all available columns.
Table headings
- Category - The metrics group or classification.
- Metric - The metric display name as it appears in the Azure portal.
- Name in REST API - The metric name as referred to in the REST API.
- Unit - Unit of measure.
- Aggregation - The default aggregation type. Valid values: Average (Avg), Minimum (Min), Maximum (Max), Total (Sum), Count.
- Dimensions - Dimensions available for the metric.
- Time Grains - Intervals at which the metric is sampled. For example,
PT1M
indicates that the metric is sampled every minute,PT30M
every 30 minutes,PT1H
every hour, and so on. - DS Export- Whether the metric is exportable to Azure Monitor Logs via diagnostic settings. For information on exporting metrics, see Create diagnostic settings in Azure Monitor.
Category: Availability
Metric | Name in REST API | Unit | Aggregation | Dimensions | Time Grains | DS Export |
---|---|---|---|---|---|---|
HA IO Status Status for replication IO thread running |
HA_IO_status |
Count | Maximum | <none> | PT1M | Yes |
HA SQL Status Status for replication SQL thread running |
HA_SQL_status |
Count | Maximum | <none> | PT1M | Yes |
Replica IO Status Status for replication IO thread running |
Replica_IO_Running |
Count | Maximum | <none> | PT1M | No |
Replica SQL Status Status for replication SQL thread running |
Replica_SQL_Running |
Count | Maximum | <none> | PT1M | No |
Category: Errors
Metric | Name in REST API | Unit | Aggregation | Dimensions | Time Grains | DS Export |
---|---|---|---|---|---|---|
Aborted Connections Aborted Connections |
aborted_connections |
Count | Total (Sum) | <none> | PT1M | Yes |
Category: Latency
Metric | Name in REST API | Unit | Aggregation | Dimensions | Time Grains | DS Export |
---|---|---|---|---|---|---|
HA Replication Lag HA Replication lag in seconds |
HA_replication_lag |
Seconds | Average, Maximum, Minimum | <none> | PT1M | Yes |
Innodb Row Lock Time The total time spent in acquiring row locks for InnoDB tables, in milliseconds. |
Innodb_row_lock_time |
Milliseconds | Average, Maximum, Minimum | <none> | PT1M | Yes |
Innodb Row Lock Waits The number of times operations on InnoDB tables had to wait for a row lock. |
Innodb_row_lock_waits |
Count | Total (Sum), Maximum, Minimum | <none> | PT1M | Yes |
Replication Lag In Seconds Replication lag in seconds |
replication_lag |
Seconds | Average, Maximum, Minimum | <none> | PT1M | Yes |
MySQL Uptime The number of seconds that the server has been up. |
Uptime |
Seconds | Total (Sum), Maximum | <none> | PT1M | Yes |
Category: Saturation
Metric | Name in REST API | Unit | Aggregation | Dimensions | Time Grains | DS Export |
---|---|---|---|---|---|---|
Backup Storage Used Backup Storage Used |
backup_storage_used |
Bytes | Average, Maximum, Minimum | <none> | PT15M, PT30M, PT1H, PT6H, PT12H, P1D | Yes |
Binlog Storage Used Storage used by Binlog files. |
binlog_storage_used |
Bytes | Average, Maximum, Minimum | <none> | PT1M | Yes |
CPU Credits Consumed CPU Credits Consumed |
cpu_credits_consumed |
Count | Average, Maximum, Minimum | <none> | PT15M, PT30M, PT1H, PT6H, PT12H, P1D | Yes |
CPU Credits Remaining CPU Credits Remaining |
cpu_credits_remaining |
Count | Average, Maximum, Minimum | <none> | PT15M, PT30M, PT1H, PT6H, PT12H, P1D | Yes |
Host CPU Percent Host CPU Percent |
cpu_percent |
Percent | Average, Maximum, Minimum | <none> | PT1M | Yes |
Data Storage Used Storage used by data files. |
data_storage_used |
Bytes | Average, Maximum, Minimum | <none> | PT1M | Yes |
Ibdata1 Storage Used Storage used by ibdata1 files. |
ibdata1_storage_used |
Bytes | Average, Maximum, Minimum | <none> | PT1M | Yes |
InnoDB Buffer Pool Pages Data The number of pages in the InnoDB buffer pool containing data. |
Innodb_buffer_pool_pages_data |
Count | Total (Sum), Maximum, Minimum | <none> | PT1M | Yes |
InnoDB Buffer Pool Pages Dirty The current number of dirty pages in the InnoDB buffer pool. |
Innodb_buffer_pool_pages_dirty |
Count | Total (Sum), Maximum, Minimum | <none> | PT1M | Yes |
InnoDB Buffer Pool Pages Free The number of free pages in the InnoDB buffer pool. |
Innodb_buffer_pool_pages_free |
Count | Total (Sum), Maximum, Minimum | <none> | PT1M | Yes |
InnoDB Buffer Pool Read Requests The number of logical read requests. |
Innodb_buffer_pool_read_requests |
Count | Total (Sum), Maximum, Minimum | <none> | PT1M | Yes |
InnoDB Buffer Pool Reads The number of logical reads that InnoDB could not satisfy from the buffer pool, and had to read directly from disk. |
Innodb_buffer_pool_reads |
Count | Total (Sum), Maximum, Minimum | <none> | PT1M | Yes |
Storage IO Percent Storage I/O consumption percent |
io_consumption_percent |
Percent | Average, Maximum, Minimum | <none> | PT1M | Yes |
Memory Percent Memory Percent |
memory_percent |
Percent | Average, Maximum, Minimum | <none> | PT1M | Yes |
Others Storage Used Storage used by other files. |
others_storage_used |
Bytes | Average, Maximum, Minimum | <none> | PT1M | Yes |
Serverlog Storage Limit Serverlog Storage Limit |
serverlog_storage_limit |
Bytes | Maximum | <none> | PT1M | Yes |
Serverlog Storage Percent Serverlog Storage Percent |
serverlog_storage_percent |
Percent | Average, Maximum, Minimum | <none> | PT1M | Yes |
Serverlog Storage Used Serverlog Storage Used |
serverlog_storage_usage |
Bytes | Average, Maximum, Minimum | <none> | PT1M | Yes |
Sort Merge Passes The number of merge passes that the sort algorithm has had to do. If this value is large, you should consider increasing the value of the sort_buffer_size system variable. |
Sort_merge_passes |
Count | Total (Sum), Maximum, Minimum | <none> | PT1M | Yes |
Storage Limit Storage Limit |
storage_limit |
Bytes | Maximum | <none> | PT1M | Yes |
Storage Percent Storage Percent |
storage_percent |
Percent | Average, Maximum, Minimum | <none> | PT1M | Yes |
Storage Used Storage Used |
storage_used |
Bytes | Average, Maximum, Minimum | <none> | PT1M | Yes |
Threads Running The number of threads that are not sleeping. |
Threads_running |
Count | Total (Sum), Maximum, Minimum | <none> | PT1M | Yes |
Category: Traffic
Metric | Name in REST API | Unit | Aggregation | Dimensions | Time Grains | DS Export |
---|---|---|---|---|---|---|
Active Connections Active Connections |
active_connections |
Count | Average, Maximum, Minimum | <none> | PT1M | Yes |
Active Transactions Number of active transactions. |
active_transactions |
Count | Total (Sum), Average, Maximum, Minimum | <none> | PT1M | Yes |
Com Alter Table The number of times ALTER TABLE statement has been executed. |
Com_alter_table |
Count | Total (Sum) | <none> | PT1M | Yes |
Com Create DB The number of times CREATE DB statement has been executed. |
Com_create_db |
Count | Total (Sum) | <none> | PT1M | Yes |
Com Create Table The number of times CREATE TABLE statement has been executed. |
Com_create_table |
Count | Total (Sum) | <none> | PT1M | Yes |
Com Delete The number of times DELETE statement has been executed. |
Com_delete |
Count | Total (Sum) | <none> | PT1M | Yes |
Com Drop DB The number of times DROP DB statement has been executed. |
Com_drop_db |
Count | Total (Sum) | <none> | PT1M | Yes |
Com Drop Table The number of times DROP TABLE statement has been executed. |
Com_drop_table |
Count | Total (Sum) | <none> | PT1M | Yes |
Com Insert The number of times INSERT statement has been executed. |
Com_insert |
Count | Total (Sum) | <none> | PT1M | Yes |
Com Select The number of times SELECT statement has been executed. |
Com_select |
Count | Total (Sum) | <none> | PT1M | Yes |
Com Update The number of times UPDATE statement has been executed. |
Com_update |
Count | Total (Sum) | <none> | PT1M | Yes |
Innodb Buffer Pool Pages Flushed The number of requests to flush pages from the InnoDB buffer pool. |
Innodb_buffer_pool_pages_flushed |
Count | Average, Maximum, Minimum | <none> | PT1M | Yes |
Innodb Data Writes The total number of data writes. |
Innodb_data_writes |
Count | Total (Sum), Maximum, Minimum | <none> | PT1M | Yes |
MySQL Lock Deadlocks Number of deadlocks. |
lock_deadlocks |
Count | Total (Sum), Average, Maximum, Minimum | <none> | PT1M | Yes |
MySQL Lock Timeouts Number of lock timeouts. |
lock_timeouts |
Count | Total (Sum), Average, Maximum, Minimum | <none> | PT1M | Yes |
Host Network Out Host Network egress in bytes |
network_bytes_egress |
Bytes | Total (Sum) | <none> | PT1M | Yes |
Host Network In Host Network ingress in bytes |
network_bytes_ingress |
Bytes | Total (Sum) | <none> | PT1M | Yes |
Queries Queries |
Queries |
Count | Total (Sum) | <none> | PT1M | Yes |
Slow Queries The number of queries that have taken more than long_query_time seconds. |
Slow_queries |
Count | Total (Sum) | <none> | PT1M | Yes |
Storage IO Count The number of storage I/O consumed. |
storage_io_count |
Count | Total (Sum) | <none> | PT1M | No |
Total Connections Total Connections |
total_connections |
Count | Total (Sum) | <none> | PT1M | Yes |
MySQL History List Length Length of the TRX_RSEG_HISTORY list. |
trx_rseg_history_len |
Count | Total (Sum), Average, Maximum, Minimum | <none> | PT1M | Yes |
This table includes more detailed descriptions of some metrics.
Metric display name | Metric | Unit | Description |
---|---|---|---|
MySQL Uptime | This metric indicates the length of time that the MySQL server has been running. | ||
Host CPU percent | Host CPU percent is the total utilization of the CPU to process all the tasks on your server over a selected period. This metric includes the workload of your Azure Database for MySQL Flexible Server instance and Azure MySQL process. High CPU percent can help you find if your database server has a heavier workload than it can handle. This metric is equivalent to total CPU utilization and is similar to CPU utilization on any virtual machine. | ||
CPU Credit Consumed | This is for Burstable Tier Only CPU credit is calculated based on workload. For more information, see B-series burstable virtual machine sizes. | ||
CPU Credit Remaining | This is for Burstable Tier Only CPU remaining is calculated based on workload. For more information, see B-series burstable virtual machine sizes. | ||
Host Network In | Total sum of incoming network traffic on the server for a selected period. This metric includes traffic to your database and Azure Database for MySQL Flexible Server features like monitoring, logs, etc. | ||
Host Network out | Total sum of outgoing network traffic on the server for a selected period. This metric includes traffic from your database and Azure Database for MySQL Flexible Server features like monitoring, logs, etc. | ||
Active Connections | The number of active connections to the server. Active connections are the total number of threads connected to your server, which also includes threads from azure_superuser. | ||
Storage IO percent | The percentage of IO used over a selected period. IO percent is for both read and write IOPS. | ||
Storage IO Counts | The server's total count of I/O operations (both read and write) per minute. | ||
Memory Percent | This metric represents the percentage of memory occupied by the Azure MySQL (mysqld) server process. This metric is calculated from the Total Memory Size (GB) available on your Azure Database for MySQL Flexible Server. | ||
Total connections | The number of client connections to your Azure Database for MySQL Flexible Server instance. Total Connections is the sum of client connections using TCP/IP protocol over a selected period. | ||
Aborted Connections | Total number of failed attempts to connect to your Azure Database for MySQL Flexible Server instance, for example, failed connection due to bad credentials. For more information on aborted connections, see this documentation. | ||
Queries | Total number of queries executed per minute on your server. Total count of queries per minute on your server from your database workload and Azure MySQL processes. | ||
Slow_queries | The total count of slow queries on your server in the selected time range. | ||
Active Transactions | This metric represents the total number of transactions within MySQL. Active transactions include all transactions that started but have yet to be committed or rolled back. |
Storage breakdown metrics provide valuable insights into the storage usage of your Azure Database for MySQL Flexible Server. These metrics give you a detailed breakdown of the storage limit, storage percentage, storage used, data storage used, ibdata1 storage used, binlog storage used, other storage used, and backup storage used. By monitoring these metrics, you can effectively manage your storage resources, optimize storage allocation, and ensure efficient utilization of your server's storage capacity. Understanding the storage breakdown metrics helps you make informed decisions to maintain the performance and availability of your Azure Database for MySQL Flexible Server.
The table below lists descriptions for the storage breakdown metrics available for Azure Database for MySQL Flexible Server:
Metric display name | Description |
---|---|
Storage Limit | The maximum storage size configured for this server. |
Storage Percent | The percentage of storage used out of the server's maximum storage available. |
Storage Used | The amount of storage in use. The storage used by the service might include the database files, transaction logs, and server logs. |
Data Storage Used | The amount of storage used for storing database files. |
ibdata1 Storage Used | The amount of storage used for storing system tablespace (ibdata1) file. |
Binlog Storage Used | The amount of storage used for storing binary log files. |
Other Storage Used | The amount of storage used for other components and metadata files. |
Backup Storage Used | The amount of backup storage used. |
Replication metrics provide valuable insights into the performance and status of replication in Azure Database for MySQL Flexible Server. These metrics allow you to monitor the replication lag, check the status of replica and HA IO/SQL threads, and measure the replication latency. By tracking these metrics, you can ensure the reliability and efficiency of your replication setup, identify any potential issues or delays, and take appropriate actions to maintain data consistency and availability. Let's explore the different replication metrics available for Azure Database for MySQL Flexible Server.
The table below lists the replication metrics available for Azure Database for MySQL Flexible Server:
Metric display name | Description |
---|---|
Replication Lag | Replication lag is the number of seconds behind the replica in replaying the transactions received from the source server. This metric is calculated from "Seconds_behind_Master" from the command "SHOW SLAVE STATUS" command and is only available for replica servers. For more information, see "Troubleshoot replication latency in Azure Database for MySQL - Flexible Server" |
Replica IO Status | Replica IO Status indicates the state of replication I/O thread. The metric value is 1 if the I/O thread runs and 0 if not. |
Replica SQL Status | Replica SQL Status indicates the state of replication SQL thread. The metric value is 1 if the SQL thread runs and 0 if not. |
HA IO Status | HA IO Status indicates the state of High availability concepts in Azure Database for MySQL - Flexible Server. The metric value is 1 if the I/O thread runs and 0 if not. |
HA SQL Status | HA SQL Status indicates the state of High availability concepts in Azure Database for MySQL - Flexible Server. The metric value is 1 if the SQL thread runs and 0 if not. |
HA Replication Lag | HA Replication lag is the number of seconds the HA Standby server is behind in replaying the transactions received from the source server. This metric is calculated from "Seconds_behind_Master" from the command "SHOW SLAVE STATUS" command and is available only for HA standby servers. |
In addition to the standard metrics provided by Azure Database for MySQL Flexible Server, enhanced metrics are available to gain deeper insights into your server's performance. These enhanced metrics provide more granular information about specific aspects of your workload.
The Data Manipulation Language (DML) statistics metrics give you visibility into the number of select, update, insert, and delete statements executed on your server. By monitoring these metrics, you can track the usage and performance of your database operations and identify any potential bottlenecks or inefficiencies.
Metric display name | Description |
---|---|
Com_select | The total count of select statements executed on your server in the selected time range. |
Com_update | The total count of update statements executed on your server in the selected time range. |
Com_insert | The total count of insert statements executed on your server in the selected time range. |
Com_delete | The total count of deleted statements executed on your server in the selected time range. |
The Data Definition Language (DDL) statistics metrics provide information about how often you can create a database, drop a database, create a table, drop a table, and alter table statements run on your server. These metrics help you understand the frequency and impact of schema changes in your database, allowing you to optimize your database design and improve overall performance.
Metric display name | Description |
---|---|
Com_create_db | The total count of created database statements executed on your server in the selected time range. |
Com_drop_db | The total count of drop database statements executed on your server in the selected time range. |
Com_create_table | The total count of create table statements executed on your server in the selected time range. |
Com_drop_table | The total count of drop table statements executed on your server in the selected time range. |
Com_Alter | The total count of alter table statements executed on your server in the selected time range. |
The Innodb metrics focus on the performance of the InnoDB storage engine, which is the default engine for Azure Database for MySQL Flexible Server. These metrics include InnoDB row lock time, InnoDB row lock waits, Innodb buffer pool reads, Innodb buffer pool read requests, and more. By monitoring these metrics, you can gain insights into the efficiency and effectiveness of your database's storage and caching mechanisms.
These enhanced metrics provide valuable information for optimizing your workload and improving the performance of your Azure Database for MySQL Flexible Server. Using these metrics, you can make data-driven decisions to enhance your database operations' scalability, reliability, and efficiency.
Metric display name | Description |
---|---|
InnoDB Row Lock Time | InnoDB row lock time measures the duration of time in milliseconds for InnoDB row-level locks. |
InnoDB Row Lock Waits | InnoDB row lock waits metric counts the number of times a query had to wait for an InnoDB row-level lock. |
Innodb_buffer_pool_reads | The total count of logical reads that the InnoDB engine couldn't satisfy from the Innodb buffer pool and had to be fetched from the disk. |
Innodb_buffer_pool_read_requests | The total count of logical read requests to read from the Innodb Buffer pool. |
Innodb_buffer_pool_pages_free | The total count of free pages in the InnoDB buffer pool. |
Innodb_buffer_pool_pages_data | The total count of pages in the InnoDB buffer pool containing data. The number includes both dirty and clean pages. |
Innodb_buffer_pool_pages_dirty | The total count of pages in the InnoDB buffer pool containing dirty pages. |
MySQL History List Length | This metric calculates the number of changes in the database, specifically the number of records containing previous changes. It's related to the rate of changes to data, causing new row versions to be created. An increasing history list length can affect the performance of the database. |
MySQL Lock Timeouts | This metric represents the number of times a query has timed out due to a lock. This situation typically occurs when a query waits for a lock on a row or table held by another query for a longer time than the innodb_lock_wait_timeout setting. |
MySQL Lock Deadlocks | This metric represents the number of deadlocks on your Azure Database for MySQL Flexible Server instance in the selected period. |
Metric dimensions
For information about what metric dimensions are, see Multi-dimensional metrics.
This service doesn't have any metrics that contain dimensions.
Troubleshoot metrics
Sometimes, you might encounter issues with creating, customizing, or interpreting charts in Azure Metrics Explorer.
A Chart showing no data could arise due to various factors. These issues might include the Microsoft Insights resource provider not being registered for your subscription or you lacking adequate access rights to your Azure Database for MySQL - Flexible Server. Other possibilities could be that your resource didn't generate metrics within the chosen time frame or the selected time range exceeds 30 days.
Several reasons that follow can cause this behavior:
- Microsoft.Insights resource provider isn't registered: Exploring metrics requires Microsoft.Insights resource provider registered in your subscription. Register your server manually by following the steps described in Azure resource providers and types.
- Insufficient access rights to your resource: Ensure you have sufficient permissions for your Azure Database for MySQL - Flexible Server from which you're exploring metrics. Your resource didn't emit metrics during the selected time range. Change the time of the chart to a wider range. In Azure, Azure role-based access control (Azure RBAC) controls access to metrics. You must be a member of monitoring reader, monitoring contributor, or contributor to explore metrics for any resource.
- Your resource didn't emit metrics during the selected time range: This behavior could be due to several reasons. One possibility is that your resource didn't generate metrics within the chosen time frame. Change the time of the chart to a broader range to see if this approach resolves the issue. For more detailed information on troubleshooting this issue, refer to the Azure Monitor metrics troubleshooting guide.
- Time range greater than 30 days: Verify that the difference between the start and end dates in the time picker doesn't exceed the 30-day interval. For more detailed information on troubleshooting metrics, refer to the Azure Monitor metrics troubleshooting guide.
- Dashed Line Indication: In Azure Monitor, a dashed line signifies a gap in data, or a null value, between two points of known time grain data. This aspect is a deliberate design that helps detect missing data points. If your chart displays dashed lines, it indicates missing data. For more information, see Chart shows dashed line.
For more detailed information on troubleshooting metrics, refer to the Azure Monitor metrics troubleshooting guide.
Note
Metrics marked as deprecated are scheduled to be removed from the Azure portal. You should ignore these metrics when monitoring your Azure Database for MySQL Flexible Server.
Resource logs
This section lists the types of resource logs you can collect for this service. The section pulls from the list of all resource logs category types supported in Azure Monitor.
Supported resource logs for Microsoft.DBforMySQL\flexibleServers
Category | Category display name | Log table | Supports basic log plan | Supports ingestion-time transformation | Example queries | Costs to export |
---|---|---|---|---|---|---|
MySqlAuditLogs |
MySQL Audit Logs | AzureDiagnostics Logs from multiple Azure resources. |
No | No | Queries | No |
MySqlSlowLogs |
MySQL Slow Logs | AzureDiagnostics Logs from multiple Azure resources. |
No | No | Queries | No |
Azure Monitor Logs tables
This section lists the Azure Monitor Logs tables relevant to this service, which are available for query by Log Analytics using Kusto queries. The tables contain resource log data and possibly more depending on what is collected and routed to them.
Azure Database for MySQL - Flexible Server Microsoft.DBforMySQL\flexibleServers
Activity log
The linked table lists the operations that can be recorded in the activity log for this service. These operations are a subset of all the possible resource provider operations in the activity log.
For more information on the schema of activity log entries, see Activity Log schema.
Related content
- See Monitor Azure Database for MySQL - Flexible Server for a description of monitoring Azure Database for MySQL - Flexible Server.
- See Monitor Azure resources with Azure Monitor for details on monitoring Azure resources.