AWR报告生成
2009-10-31 20:20 hyddd 阅读(6987) 评论(0) 编辑 收藏 举报一.生成AWR报告
[ractest@sun880-1 /u01/app/oracle/orahome/rdbms/admin]$ cd $ORACLE_HOME/rdbms/admin
[ractest@sun880-1 /u01/app/oracle/orahome/rdbms/admin]$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.4.0 - Production on Sun Jan 27 20:47:38 2008
Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options
SQL> @awrrpt
......
//根据Oracle提示生成报告......
[ractest@sun880-1 /u01/app/oracle/orahome/rdbms/admin]$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.4.0 - Production on Sun Jan 27 20:47:38 2008
Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options
SQL> @awrrpt
......
//根据Oracle提示生成报告......
注:报告生成在$ORACLE_HOME/rdbms/admin/目录下。
二.修改awr的默认设置
//半小时采集一次,采集信息保存3天。
SQL>exec dbms_workload_repository.modify_snapshot_settings (interval=>30,retention =>3*24*60);
SQL>exec dbms_workload_repository.modify_snapshot_settings (interval=>30,retention =>3*24*60);
三.关闭AWR自动收集
SQL>exec dbms_workload_repository.modify_snapshot_settings (interval=>0,retention =>24*60);
注:10g默认是自动开启awr信息收集的,会对系统有一定的影响(很小);如果要关闭awr信息收集,只需设置interval参数为0即可。但interval设0后,AWR报告无法生成。
作者:hyddd
出处:http://www.cnblogs.com/hyddd/
本文版权归作者所有,欢迎转载,演绎或用于商业目的,但是必须说明本文出处(包含链接)。