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

本站中文解释

Oracle视图DBA_HIST_CON_SYSSTAT用来显示连接系统运行统计信息,包括连接活动和每个活动的系统参数,当前会话配置和其它一些统计信息,可用来优化系统连接,检查诊断和监控各个系统资源的使用情况。

使用方法:
1、首先,确保需要监控的SYSSTAT参数是打开的,可以查看v$sysstat参数的值
2、使用如下语句查看当前连接的信息:
SELECT s.timestamp,s.sid,s.username,s.program,s.machine,s.terminal,s.osuser,s.process,g.value,g.name
FROM dba_hist_con_sysstat s,DBA_HIST_GSYSSTAT g
WHERE s.timestamp = g.timestamp
AND s.inst_id = g.inst_id
AND s.sid=g.sid
ORDER BY s.sid;
3、使用如下语句查看特定连接的信息:
SELECT * FROM dba_hist_con_sysstat WHERE sid = AND INST_ID = AND TIMESTAMP BETWEEN and ORDER BY sid;

官方英文解释

DBA_HIST_CON_SYSSTAT displays historical system statistics information, including OLAP kernel statistics. This view contains snapshots of V$CON_SYSSTAT.

Column Datatype NULL Description

SNAP_ID

NUMBER

NOT NULL

Unique snapshot ID

DBID

NUMBER

NOT NULL

Database ID for the snapshot

INSTANCE_NUMBER

NUMBER

NOT NULL

Instance number for the snapshot

STAT_ID

NUMBER

NOT NULL

Statistic identifier

STAT_NAME

VARCHAR2(64)

NOT NULL

Statistic name

VALUE

NUMBER

Statistic value

CON_DBID

NUMBER

NOT NULL

The database ID for the PDB of the sampled session

CON_ID

NUMBER

NOT NULL

The ID of the container that CON_DBID identifies. Possible values include:

  • When queried from a non-CDB, the statistics for that instance are returned, and the CON_ID value is 0.

  • When queried from the root of a CDB, the statistics in every container are returned, and the CON_ID value indicates the container to which the statistics belong.

  • When queried from a PDB, statistics from that PDB are returned, and the CON_ID value is the container ID for that PDB.

See Also:

  • “V$CON_SYSSTAT”

  • “DBA_HIST_SYSSTAT”


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