Database Lock

The metrics in this category report information about locks.

Default Collection Interval — Every 15 minutes

Table 2-29 Database Lock Metrics

Metric Description

Server Process Identifier (key column)

Server process ID of the current user process.

Database Identifier (key column)

Database identification number requesting a lock.

Object Identifier (key column)

Object identification number of the object requesting a lock.

Index Identifier (key column)

Deprecated. Always returns 0.

Mode

Lock mode:

  • Shared (S)

  • Update (U)

  • Exclusive (X)

  • Intent

  • Schema

  • Bulk update (BU)

  • RangeS_S — Shared range, shared resource lock; serializable range scan.

  • RangeS_U — Shared range, update resource lock; serializable update scan.

  • RangeI_N — Insert range, null resource lock. Used to test ranges before inserting a new key into an index.

  • RangeX_X — Exclusive range, exclusive resource lock. Used when updating a key in a range.

Resource

Lock resource that corresponds to the value in syslockinfo.restext:

RID, KEY, PAG, EXT, TAB, and DB

Lock Request Status

The current status of the lock:

GRANT, WAIT, and CNVT

Type

The lock type:

  • RID = Lock on a single row in a table identified by a row identifier (RID).

  • KEY = Lock within an index that protects a range of keys in serializable transactions.

  • PAG = Lock on a data or index page.

  • EXT = Lock on an extent.

  • TAB = Lock on an entire table, including all data and indexes.

  • DB = Lock on a database.

  • FIL = Lock on a database file.

  • APP = Lock on an application-specified resource.

  • MD = Locks on metadata, or catalog information.

  • HBT = Lock on a heap or B-Tree index. This information is incomplete in SQL Server.

  • AU = Lock on an allocation unit. This information is incomplete in SQL Server.

Resource Type

Type of resource being locked. This presents the same data as the Type metric:

  • DATABASE

  • FILE

  • OBJECT

  • PAGE

  • KEY

  • EXTENT

  • RID

  • APPLICATION

  • METADATA

  • HOBT

  • ALLOCATION_UNIT