Oracle 视图 V$LATCHNAME 官方解释,作用,如何使用详细说明

本站中文解释

Oracle视图V$LATCHNAME是内部视图,展示系统中所有可用的latch(锁)。每个latch都有唯一的名称(latchname),它可以帮助数据库管理员对数据库做出更好的调整,从而提高数据库性能。

使用方法:

1、可以使用以下sql语句查询V$LATCHNAME视图:

Select Latch#, Latchname, Gets, Misses, Sleeps From V$Latchname;

2、使用V$LATCHNAME视图,你可以获得某一个latch的 hits 计数,以及把latch等待的次数。所获得的信息可以用来判断某一个数据库的性能情况。

3、还可以使用V$LATCHNAME视图,对数据库中比较繁杂的操作手段进行跟踪。使用此视图,可以找出性能可能出现问题的latch,并且可以采取有效的优化措施。

官方英文解释

V$LATCHNAME displays information about decoded latch names for the latches shown in V$LATCH.

The rows of V$LATCHNAME have a one-to-one correspondence to the rows of V$LATCH.

Column Datatype Description

LATCH#

NUMBER

Latch number

NAME

VARCHAR2(64)

Latch name

DISPLAY_NAME

VARCHAR2(64)

A clearer and more descriptive name for the latch that appears in the NAME column. Names that appear in the DISPLAY_NAME column can change across Oracle Database releases, therefore customer scripts should not rely on names that appear in the DISPLAY_NAME column across releases.

HASH

NUMBER

Latch hash

TYPE

VARCHAR2(4)

Type of the latch (SGA, PDB, or OSP):

CON_ID

NUMBER

The ID of the container to which the data pertains. Possible values include:

  • 0: This value is used for rows containing data that pertain to the entire CDB. This value is also used for rows in non-CDBs.

  • 1: This value is used for rows containing data that pertain to only the root

  • n: Where n is the applicable container ID for the rows containing data

See Also:

“V$LATCH”


数据运维技术 » Oracle 视图 V$LATCHNAME 官方解释,作用,如何使用详细说明