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

本站中文解释

Oracle视图DBA_HIST_IOSTAT_FUNCTION是数据库管理员用于查看I/O统计历史信息的视图,主要用于记录数据库中某段时间内每个节点的I/O状态、每种I/O状态的时间长度,以及每种I/O状态的总时长。数据库管理员可以通过这个视图分析I/O状态情况,早期发现系统中的I/O性能瓶颈,并采取相应的措施调优。

使用DBA_HIST_IOSTAT_FUNCTION视图的方法:

1. 查询当前节点上某段时间内每一种I/O状态的详细信息:

SELECT * FROM DBA_HIST_IOSTAT_FUNCTION WHERE NODE_NUMBER = ‘当前节点编号’ AND SNAP_ID BETWEEN ‘开始时间’ AND ‘结束时间’;

2. 查询某段时间内,每个节点总的I/O时间:

SELECT NODE_NUMBER, SUM(CON_DB_TIME)AS TOTAL_IO_TIME FROM DBA_HIST_IOSTAT_FUNCTION WHERE SNAP_ID BETWEEN ‘开始时间’ AND ‘结束时间’ GROUP BY NODE_NUMBER;

3. 查询某段时间内每一节点,每一种I/O状态的时间比例:

SELECT NODE_NUMBER, FUNCTION_STATUS, SUM(CON_DB_TIME)AS TOTAL_IO_TIME, ROUND(SUM(CON_DB_TIME)/ SUM(OVER(FUNCTION_STATUS)) * 100, 2 )AS IO_STATUS_RATIO FROM DBA_HIST_IOSTAT_FUNCTION WHERE SNAP_ID BETWEEN ‘开始时间’ AND ‘结束时间’ GROUP BY NODE_NUMBER, FUNCTION_STATUS;

官方英文解释

DBA_HIST_IOSTAT_FUNCTION displays historical I/O statistics by function.

This view contains snapshots of V$IOSTAT_FUNCTION.

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

FUNCTION_ID

NUMBER

NOT NULL

Function ID

FUNCTION_NAME

VARCHAR2(128)

NOT NULL

Function name

SMALL_READ_MEGABYTES

NUMBER

NOT NULL

Number of single block megabytes read

SMALL_WRITE_MEGABYTES

NUMBER

NOT NULL

Number of single block megabytes written

LARGE_READ_MEGABYTES

NUMBER

NOT NULL

Number of multiblock megabytes read

LARGE_WRITE_MEGABYTES

NUMBER

NOT NULL

Number of multiblock megabytes written

SMALL_READ_REQS

NUMBER

NOT NULL

Number of single block read requests

SMALL_WRITE_REQS

NUMBER

NOT NULL

Number of single block write requests

LARGE_READ_REQS

NUMBER

NOT NULL

Number of multiblock read requests

LARGE_WRITE_REQS

NUMBER

NOT NULL

Number of multiblock write requests

NUMBER_OF_WAITS

NUMBER

NOT NULL

Number of I/O waits by functionality

WAIT_TIME

NUMBER

NOT NULL

Total wait time (in milliseconds)

CON_DBID

NUMBER

The database ID of the PDB for the sampled session

CON_ID

NUMBER

The ID of the container that CON_DBID identifies. 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$IOSTAT_FUNCTION”


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