You need to enable JavaScript to run this app.
Database Workshop

Database Workshop

Copy page
Download PDF
Operation and maintenance management
Lock analysis management
Copy page
Download PDF
Lock analysis management
Database Workshop DBW provides the Lock Analysis feature for RDS for SQL Server instances. This feature is designed for database administrators and developers to deeply diagnose and resolve deadlock issues in SQL Server environments. Through intuitive form lists and visual deadlock diagrams, you can quickly identify the context of deadlocks, the involved processes, lock resources, and SQL statements, thereby accurately pinpointing performance bottlenecks and formulating optimization solutions. This article describes how to manage lock analysis for RDS for SQL Server instances in Database Workshop DBW.​
Prerequisites​
  • An instance has been created and the instance state is Running. For detailed steps, see Creating an instance.​
Precautions​
  • This feature is currently in beta. You can Submit a ticket to contact technical support for data migration.​
  • Do not modify the instance configuration while using the lock analysis feature, as this may prevent you from viewing the instance's lock information.​
  • Data retention period: Query results are retained for up to 30 days.​
  • Deadlock Diagram Display Rule: The diagram shows the first deadlock by default. To view other deadlocks, click the corresponding item in the deadlock list.​
Procedure​
  1. Log on to the DBW console.​
  1. On the top menu bar, select the project and region.​
  1. On the left navigation bar, select Operation and maintenance management > Observation and diagnosis.​
  1. On the Observation and diagnosis page, switch the instance type and ID.​
  1. In the upper right corner of the Observation and diagnosis page, switch the instance type to RDS for SQL Server.​
  1. In the upper left corner of the Observation and diagnosis page, switch the target instance based on the instance ID or instance name.​
  1. On the Observation and diagnosis page, click Lock analysis.​
  1. On the Lock analysis tab, you can view the following information.​
  • ​
    Deadlock details
    Deadlock diagram
    ​
    In the Deadlock details area, customize the time for querying deadlock information as needed. The default view shows deadlock information from the last 7 days. Specific deadlock information is shown below:​
    • LastTranStarted: The transaction start time, accurate to the millisecond, used to pinpoint the exact moment the deadlock occurred.​
    • SPID: The session process ID, which uniquely identifies a database connection and is a key identifier for tracking deadlock processes.​
    • IsVictim: Indicates whether the process is the deadlock victim. Marked as × means the process was selected by the system as the victim and rolled back; marked as √ means the process was terminated in the deadlock.​
    • Database: The name of the database where the deadlock occurred.​
    • LogUsed: The amount of log space used by this transaction (in bytes), reflecting the transaction's scale.​
    • LockMode: The lock mode, such as X for exclusive lock, indicating the process is holding or requesting an exclusive lock.​
    • WaitResourceDesc: The details of the resource the current transaction is waiting for, typically including the table name, index name, and key value, used to precisely identify the lock conflict object.​
    • ObjectOwned: The ID of the lock object currently held by the process.​
    • ObjectRequested: The ID of the lock object currently being requested by the process.​
    • WaitResource: The resource the current transaction is waiting for.​
    • HostName: The host name of the current transaction.​
    • LoginName: The account name of the current transaction.​
    • Status: The state of the current transaction; "suspended" indicates the process is suspended while waiting for a resource.​
    • ClientApp: The name of the client application currently used by the firm, such as SQLCMD, to identify the source of the call.​
    • SQLText: The text of the SQL statement that caused the deadlock. Click to copy for subsequent analysis and optimization.​
    You can also click the + sign on the left of any row in the table to expand the Deadlocked process sub-table for that row and view detailed information about all related processes in this deadlock event.​
    ​
  • ​
Last updated: 2026.06.02 15:44:51