Slow queries decrease the stability of Tair (Redis OSS-compatible) instances. To monitor and analyze slow queries, you can view the details about slow query logs in CloudDBA.
Procedure
Log on to the console and go to the Instances page. In the top navigation bar, select the region in which the instance is deployed. Then, find the instance and click its ID.
In the left-side navigation pane, choose .
On the Slow Queries page, you can view Slow Log Trend and Slow Log Details.
Slow Log Trend
In the Slow Log Trend section, you can view the number of slow query logs and CPU utilization of the instance in a specific time range. You can click a specific point in time to view the slog query log details.
NoteFor cluster and read/write splitting instances, the following information is displayed: the slow query log details of data nodes and proxy nodes and the number of slow queries of each node.
Slow Log Details
By default, the details of all slow queries are displayed in the following columns: Execution End Time, Database Name, Slow Query Statement, Execution Duration, and Host Address. You can click Set to filter the columns.
NoteYou can click Export Slow Log in the upper-right corner to export slow query logs to a local storage for analysis.
By default, the Host Address parameter for cluster and read/write splitting instances displays the IP addresses of proxy nodes. To obtain the IP address of a specific client, set the ptod_enabled parameter to
1
in the Parameter Settings section. For more information, see Configure instance parameters.