diff --git "a/content/docs-lite/zh/docs/SQLReference/\347\273\237\350\256\241\344\277\241\346\201\257\345\207\275\346\225\260.md" "b/content/docs-lite/zh/docs/SQLReference/\347\273\237\350\256\241\344\277\241\346\201\257\345\207\275\346\225\260.md" index 7b068ed73ff6dcb4a04cf340584f8eca0a3a17ad..fb8bd22bab0dd0da0bfc25cb999b6fddacc5aa63 100644 --- "a/content/docs-lite/zh/docs/SQLReference/\347\273\237\350\256\241\344\277\241\346\201\257\345\207\275\346\225\260.md" +++ "b/content/docs-lite/zh/docs/SQLReference/\347\273\237\350\256\241\344\277\241\346\201\257\345\207\275\346\225\260.md" @@ -3511,4 +3511,99 @@ >![](public_sys-resources/icon-note.gif) **说明:** > >该视图不支持release版本轻量版场景。 + + + +- gs_lwlock_status() + + 描述:查看当前系统内轻量级锁的持锁、等锁情况。 + 返回值类型:setofrecord + + 示例: + ```sql + openGauss=# select * from gs_lwlock_status(); + node_name | lock_name | lock_unique_id | pid | sessionid | global_sessionid | mode | granted | start_time + -----------+-----------+----------------+-----+-----------+------------------+------+---------+------------ + (0 rows) + ``` + + 返回字段说明如下: + + **表 1** 返回字段说明 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

字段名称

+

字段类型

+

字段说明

+

node_name

+

text

+

节点名称

+

lock_name

+

text

+

轻量级锁的名字。

+

lock_unique_id

+

bigint

+

轻量级锁的唯一ID。

+

pid

+

bigint

+

持锁或等锁人的线程ID。

+

sessionid

+

bigint

+

持锁或等锁人的会话ID。

+

global_sessionid

+

text

+

资源池化全局会话ID。

+

mode

+

text

+

持锁或等锁的模式。

+

granted

+

boolean

+

是否持锁。true为持锁,false为等锁。

+

start_time

+

timestamp with time zone

+

持锁或等锁的开始时间。

+
+ \ No newline at end of file diff --git "a/content/zh/docs/SQLReference/\347\273\237\350\256\241\344\277\241\346\201\257\345\207\275\346\225\260.md" "b/content/zh/docs/SQLReference/\347\273\237\350\256\241\344\277\241\346\201\257\345\207\275\346\225\260.md" index be250fac97e2fc8f434e17383964aa11279e8bc1..b72a8bf7ec435cbf67815f0a3bf86d91a0ec3bb8 100644 --- "a/content/zh/docs/SQLReference/\347\273\237\350\256\241\344\277\241\346\201\257\345\207\275\346\225\260.md" +++ "b/content/zh/docs/SQLReference/\347\273\237\350\256\241\344\277\241\346\201\257\345\207\275\346\225\260.md" @@ -3646,4 +3646,101 @@ 6 | 163840 | 6 | 3136 | 16 | 147456 (1 row) - ``` \ No newline at end of file + ``` + + + + +- gs_lwlock_status() + + 描述:查看当前系统内轻量级锁的持锁、等锁情况。 + + 返回值类型:setofrecord + + 示例: + ```sql + openGauss=# select * from gs_lwlock_status(); + node_name | lock_name | lock_unique_id | pid | sessionid | global_sessionid | mode | granted | start_time + -----------+-----------+----------------+-----+-----------+------------------+------+---------+------------ + (0 rows) + ``` + + 返回字段说明如下: + + **表 1** 返回字段说明 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

字段名称

+

字段类型

+

字段说明

+

node_name

+

text

+

节点名称

+

lock_name

+

text

+

轻量级锁的名字。

+

lock_unique_id

+

bigint

+

轻量级锁的唯一ID。

+

pid

+

bigint

+

持锁或等锁人的线程ID。

+

sessionid

+

bigint

+

持锁或等锁人的会话ID。

+

global_sessionid

+

text

+

资源池化全局会话ID。

+

mode

+

text

+

持锁或等锁的模式。

+

granted

+

boolean

+

是否持锁。true为持锁,false为等锁。

+

start_time

+

timestamp with time zone

+

持锁或等锁的开始时间。

+
+ \ No newline at end of file