Oracle 视图 DBA_HIST_DATABASE_INSTANCE 官方解释,作用,如何使用详细说明
本站中文解释
Oracle视图DBA_HIST_DATABASE_INSTANCE用于查看指定实例时期的数据库实例的性能信息。视图中的字段给出的信息可用于比较数据库实例的系统状况,便于分析系统瓶颈和确定性能优化策略。
使用DBA_HIST_DATABASE_INSTANCE,首先需要在控制台下启用AWR(Automatic Workload Repository),然后收集实例的信息,当任务完成后,即可使用该视图来查看收集的数据,以及系统的性能监控历史数据。
例如,可以使用下面的SQL语句来查询某个时期内的实例性能指标:
SELECT Instance_Number, Snap_Id, Begin_Interval_Time, SGA_Size, Begin_Disk_Reads, End_Disk_Reads, Begin_Disk_Writes, End_Disk_Writes
FROM DBA_HIST_DATABASE_INSTANCE
WHERE Begin_Interval_Time between and ;
以上SQL语句,可以用来查看某个时间段内实例的开始和结束指标,比如SGA大小、磁盘读/写IO数等信息。
官方英文解释
DBA_HIST_DATABASE_INSTANCE
displays the databases and instances in the Workload Repository.
Column | Datatype | NULL | Description |
---|---|---|---|
|
|
|
Database ID |
|
|
|
Instance number |
|
|
|
Startup time of the instance |
|
|
|
Indicates whether the instance is running in an Oracle Real Application Clusters (Oracle RAC) environment ( |
|
|
|
Database version |
|
|
Name of the database |
|
|
|
Name of the instance |
|
|
|
Name of the host |
|
|
|
|
Last sample ID for the active session history |
|
|
Platform on which the instance is running |
|
|
|
Possible values are:
|
|
|
|
The edition of the database. Possible values include:
|
|
|
|
Unique database name |
|
|
|
Current role of the database:
|
|
|
|
The database ID of the CDB root for the sampled session |
|
|
|
The ID of the container to which the data pertains. Possible values include:
|
|
|
|
Startup time of the instance |
See Also:
“DB_UNIQUE_NAME”