AWS Aurora MySQL
Use the TrueWatch Cloud Sync script packages in the script market to sync cloud monitoring and cloud asset data to TrueWatch
Configuration¶
Install Func¶
It is recommended to enable the TrueWatch Integration - Extension - DataFlux Func (Automata): All prerequisites are automatically installed, please proceed with the script installation.
If you are deploying Func yourself, refer to Self-deploying Func
Install Script¶
Note: Please prepare the required Amazon AK in advance (for simplicity, you can directly grant global read-only permissions
ReadOnlyAccess
)
Enable Script for Automata¶
- Log in to the TrueWatch console
- Click the 【Integration】 menu and select 【Cloud Account Management】
- Click 【Add Cloud Account】, select 【AWS】, and fill in the required information on the interface. If you have already configured cloud account information before, ignore this step
- Click 【Test】, and after successful testing, click 【Save】. If the test fails, please check if the relevant configuration information is correct and test again
- Click 【Cloud Account Management】, and you can see the added cloud account in the list. Click the corresponding cloud account to enter the details page
- Click the 【Integration】 button on the cloud account details page, find
AWS Aurora MySQL
under theNot Installed
list, click the 【Install】 button, and the installation interface will pop up for installation.
Manually Enable Script¶
-
Log in to the Func console, click 【Script Market】, enter the TrueWatch script market, and search:
integration_aws_aurora_mysql
-
Click 【Install】, and enter the corresponding parameters: AWS AK ID, AK Secret, and account name.
-
Click 【Deploy Startup Script】, the system will automatically create the
Startup
script set and automatically configure the corresponding startup script. -
After enabling, you can see the corresponding automatic trigger configuration in 「Management / Automatic Trigger Configuration」. Click 【Execute】 to execute immediately without waiting for the scheduled time. Wait a moment, and you can view the execution task records and corresponding logs.
Verification¶
- In 「Management / Automatic Trigger Configuration」, confirm whether the corresponding task has the corresponding automatic trigger configuration, and you can also check the corresponding task records and logs to check for any abnormalities
- In TrueWatch, check if asset information exists in 「Infrastructure - Resource Catalog」
- In TrueWatch, check if there is corresponding monitoring data in 「Metrics」
Metrics¶
Configure Amazon CloudWatch to collect more metrics Amazon CloudWatch Metrics Details
Amazon CloudWatch Metrics for Amazon RDS¶
The AWS/RDS
namespace includes the following metrics, which apply to database entities running on Amazon Aurora. Some metrics apply to Aurora MySQL and/or Aurora PostgreSQL. Additionally, some metrics are specific to database clusters, primary database instances, replica database instances, or all database instances.
Cluster-level Metrics for Amazon Aurora¶
Metric | Description | Applies To | Unit |
---|---|---|---|
AuroraGlobalDBDataTransferBytes |
In Aurora Global Database, this is the amount of redo log data transferred from the source AWS region to the secondary AWS region. Note: This metric only applies to the secondary AWS region. | Aurora MySQL and Aurora PostgreSQL | Bytes |
AuroraGlobalDBProgressLag |
In Aurora Global Database, measures how far behind the secondary cluster is from the primary cluster in terms of user transactions and system transactions. Note: This metric only applies to the secondary AWS region. | Aurora MySQL and Aurora PostgreSQL | Milliseconds |
AuroraGlobalDBReplicatedWriteIO |
In Aurora Global Database, this is the number of write input/output operations replicated from the primary AWS region to the cluster volume in the secondary AWS region. The billing calculation for the secondary AWS region in the global database uses VolumeWriteIOPs to account for writes performed in the cluster. The billing calculation for the primary AWS region in the global database uses VolumeWriteIOPs to account for write activity in that cluster and AuroraGlobalDBReplicatedWriteIO to account for cross-region replication in the global database. Note: This metric only applies to the secondary AWS region. | Aurora MySQL and Aurora PostgreSQL | Count |
AuroraGlobalDBReplicationLag |
For Aurora Global Database, this is the lag time when replicating updates from the primary AWS region. Note: This metric only applies to the secondary AWS region. | Aurora MySQL and Aurora PostgreSQL | Milliseconds |
AuroraGlobalDBRPOLag |
In Aurora Global Database, the recovery point objective (RPO) lag time. This metric measures how far behind the secondary cluster is from the primary cluster in terms of user transactions. Note: This metric only applies to the secondary AWS region. | Aurora MySQL and Aurora PostgreSQL | Milliseconds |
AuroraVolumeBytesLeftTotal |
The remaining available space in the cluster volume. This value decreases as the cluster volume grows. If it reaches zero, the cluster reports out-of-space errors. If you want to detect whether an Aurora MySQL cluster is approaching the 128TiB size limit, you can monitor this value more easily and reliably than VolumeBytesUsed. AuroraVolumeBytesLeftTotal takes into account storage used for internal transaction management and other allocations that do not affect storage billing. | Aurora MySQL | Bytes |
BacktrackChangeRecordsCreationRate |
The number of backtrack change records created for your database cluster in 5 minutes. | Aurora MySQL | Count per 5 minutes |
BacktrackChangeRecordsStored |
The number of backtrack change records used by your database cluster | Aurora MySQL | Count |
BackupRetentionPeriodStorageUsed |
The total amount of backup storage used to support the point-in-time restore functionality within the backup retention period of an Aurora database cluster. This amount is included in the total reported by the TotalBackupStorageBilled metric. Calculated separately for each Aurora cluster. | Aurora MySQL and Aurora PostgreSQL | Bytes |
ServerlessDatabaseCapacity |
The current capacity of an Aurora Serverless database cluster. | Aurora MySQL and Aurora PostgreSQL | Count |
SnapshotStorageUsed |
The total amount of backup storage consumed by all Aurora snapshots of an Aurora database cluster outside its backup retention period. This amount is included in the total reported by the TotalBackupStorageBilled metric. Calculated separately for each Aurora cluster. | Aurora MySQL and Aurora PostgreSQL | Bytes |
VolumeWriteIOPs |
The number of write disk I/O operations to the cluster volume, reported every 5 minutes. For a detailed explanation of how billing write operations are calculated, see VolumeReadIOPs. Note that choosing a small --period value is not meaningful because Amazon RDS collects these metrics at intervals, not continuously. | Aurora MySQL and Aurora PostgreSQL | Count per 5 minutes |
Instance-level Metrics for Amazon Aurora¶
Unless otherwise noted, the following instance-specific Amazon CloudWatch metrics apply to all Aurora MySQL and Aurora PostgreSQL instances.
Metric | Description | Applies To | Unit |
---|---|---|---|
AbortedClients |
The number of client connections that were not closed properly. | Aurora MySQL | Count |
ActiveTransactions |
The average number of current transactions executed per second on an Aurora database instance. By default, this metric is not enabled in Aurora. To start measuring this value, set innodb_monitor_enable='all' in the database parameter group of the specific database instance. | Aurora MySQL | Count per second |
ACUUtilization |
The value of the ServerlessDatabaseCapacity metric divided by the maximum ACU value of the database cluster. This metric only applies to Aurora Serverless v2. | Aurora MySQL and Aurora PostgreSQL | Percentage |
AuroraDMLRejectedMasterFull |
The number of forwarded queries that were rejected because the session on the writer database instance was full. | Applies to primary instances of Aurora MySQL version 2 | Count |
AuroraDMLRejectedWriterFull |
The number of forwarded queries that were rejected because the session on the writer database instance was full. | Applies to primary instances of Aurora MySQL version 3 | Count |
AuroraEstimatedSharedMemoryBytes |
The estimated amount of shared buffer or buffer pool memory actively used during the last configured polling interval. | Aurora PostgreSQL | Bytes |
AuroraMemoryHealthState |
Indicates memory health. A value of 0 represents NORMAL. A value of 10 represents RESERVED, which indicates that the server's memory usage is approaching a critical level. | Aurora MySQL version 3.06.1 and later | Count |
AuroraMemoryNumDeclinedSqlTotal |
The number of incremental queries rejected to avoid out-of-memory (OOM). | Aurora MySQL version 3.06.1 and later | Count |
AuroraMemoryNumKillConnTotal |
The number of incremental connections closed to avoid OOM. | Aurora MySQL version 3.06.1 and later | Count |
AuroraReplicaLag |
For Aurora replicas, the amount of lag when replicating updates from the primary instance. | Applies to replica instances of Aurora MySQL and Aurora PostgreSQL | Milliseconds |
AuroraReplicaLagMaximum |
The maximum lag between the primary instance and any Aurora database instance in the database cluster. When a read-only replica is deleted or renamed, the replication lag may temporarily spike as the old resource undergoes a recycling process. To obtain an accurate representation of the replication lag during this period, it is recommended to monitor the AuroraReplicaLag metric on each read-only replica instance. | Applies to primary instances of Aurora MySQL and Aurora PostgreSQL | Milliseconds |
AuroraReplicaLagMinimum |
The minimum lag between the primary instance and any Aurora database instance in the database cluster. | Applies to primary instances of Aurora MySQL and Aurora PostgreSQL | Milliseconds |
AuroraSlowConnectionHandleCount |
The number of connections that waited two seconds or more to start a handshake. This metric only applies to Aurora MySQL version 3. | Aurora MySQL | Count |
BacktrackWindowActual |
The difference between the target backtrack window and the actual backtrack window. | Applies to primary instances of Aurora MySQL | Minutes |
BacktrackWindowAlert |
For a given period, the number of times the actual backtrack window was less than the target backtrack window. | Applies to primary instances of Aurora MySQL | Count |
BlockedTransactions |
The average number of blocked transactions in the database per second. | Aurora MySQL | Count per second |
BufferCacheHitRatio |
The percentage of requests served by the buffer cache. | Aurora MySQL and Aurora PostgreSQL | Percentage |
CommitLatency |
The average duration taken by the engine and storage to complete a commit operation. | Aurora MySQL and Aurora PostgreSQL | Milliseconds |
CommitThroughput |
The average number of commit operations per second. | Aurora MySQL and Aurora PostgreSQL | Count per second |
ConnectionAttempts |
The number of attempts to connect to the instance, regardless of success. | Aurora MySQL | Count |
CPUUtilization |
The percentage of CPU utilized by the Aurora database instance. | Aurora MySQL and Aurora PostgreSQL | Percentage |
DatabaseConnections |
The number of client network connections to the database instance. The number of database sessions may be higher than the metric value because the metric value does not include the following: sessions that no longer have a network connection but have not yet been cleaned up by the database, sessions created by the database engine for its own purposes, sessions created by the database engine's parallel execution feature, sessions created by the database engine's task scheduler, Amazon Aurora connections | Applies to primary instances of Aurora MySQL and Aurora PostgreSQL | Count |
DDLLatency |
The average duration of requests such as sample, create, alter, and delete requests. | Aurora MySQL | Milliseconds |
DDLThroughput |
The average number of DDL requests per second. | Aurora MySQL | Count per second |
Deadlocks |
The average number of deadlocks in the database per second. | Aurora MySQL and Aurora PostgreSQL | Count per second |
DeleteLatency |
The average duration of delete operations. | Aurora MySQL | Milliseconds |
DeleteThroughput |
The average number of delete queries per second. | Aurora MySQL | Count per second |
DiskQueueDepth |
The number of outstanding read/write requests waiting to access the disk. | Aurora MySQL and Aurora PostgreSQL | Count |
DMLLatency |
The average duration of inserts, updates, and deletes. | Aurora MySQL | Milliseconds |
DMLThroughput |
The average number of inserts, updates, and deletes per second. | Aurora MySQL | Count per second |
EngineUptime |
The length of time the instance has been running. | Aurora MySQL and Aurora PostgreSQL | Seconds |
FreeableMemory |
The available size of random access memory. For Aurora MySQL and Aurora PostgreSQL databases, this metric reports the value of the MemAvailable field in /proc/meminfo. | Aurora MySQL and Aurora PostgreSQL | Bytes |
FreeEphemeralStorage |
The size of available temporary NVMe storage | Aurora PostgreSQL | Bytes |
InsertLatency |
The average duration of insert operations. | Aurora MySQL | Milliseconds |
Objects¶
The collected AWS Aurora MySQL object data structure can be seen in 「Infrastructure - Resource Catalog」
{
"measurement": "aws_rds",
"tags": {
"name" : "xxxxx",
"RegionId" : "cn-northwest-1",
"Engine" : "aurora-mysql",
"DBInstanceClass" : "db.t3.medium",
"DBInstanceIdentifier" : "xxxxxx",
"AvailabilityZone" : "ap-southeast-1b",
"SecondaryAvailabilityZone": "ap-southeast-1c"
},
"fields": {
"InstanceCreateTime" : "2025/05/26 22:45:02",
"LatestRestorableTime": "2025/05/26 22:15:26",
"Endpoint" : "{Connection Address JSON Data}",
"AllocatedStorage" : 1,
"message" : "{Instance JSON Data}",
}
}
Note: The fields in
tags
,fields
may change with subsequent updatesTip 1: The value of
tags.name
is the instance ID, used as a unique identifierTip 2:
fields.message
,fields.Endpoint
are JSON serialized strings ```