Queries primary/backup switch logs

Last updated: 2025-02-27 17:33:03

TencentDB for SQL Server supports recording the primary/backup switch logs of instances. Through these logs, you can understand the detailed time and method of the switch, determine whether the switch was successful, and optimize the primary/backup switch strategy. This article introduces how to query primary/backup switch logs.

Operation step

1. Log in to SQL Server Console.
2. Select the region at the top, find the instance for which you need to query the primary/backup switch logs, click Instance ID or click Operation in the Management column to enter the instance management page.


3. On the instance management page, select Operation Log > Primary/Backup Switch Log to view the list of primary/backup switch logs.
The fields you can view are: Switch Event ID, Switch Start Time, Switch End Time, Switching Method (System Automatic Switchover, Manual Switch).
You can filter logs by time.


Related APIs

API
Description
The interface (DescribeHASwitchLog) is used for manual primary/backup switching.