Oracle AWR报告提取方法
本文旨在用来指导项目人员自行提取Oracle数据库的AWR报告.
1.当前连接实例的AWR报告提取:@?/rdbms/admin/awrrpt
2.RAC的其他实例AWR报告提取:@?/rdbms/admin/awrrpti
1.当前连接实例的AWR报告提取:@?/rdbms/admin/awrrpt
SQL> @?/rdbms/admin/awrrpt //注意输入的@?/rdbms/admin/awrrpt 中间没有任何空格,需要在数据库服务器上Oracle用户登陆,sqlplus / as sysdba 进入SQL> 下执行.
Current Instance
~~~~~~~~~~~~~~~~ DB Id DB Name Inst Num Instance
----------- ------------ -------- ------------
857123342 JY 1 jy1 Specify the Report Type
~~~~~~~~~~~~~~~~~~~~~~~
Would you like an HTML report, or a plain text report?
Enter 'html' for an HTML report, or 'text' for plain text
Defaults to 'html'
Enter value for report_type:
//注意这里直接回车即可,默认就是html格式的
Type Specified: html Instances in this Workload Repository schema
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ DB Id Inst Num DB Name Instance Host
------------ -------- ------------ ------------ ------------
857123342 2 JY jy2 rac2-server
* 857123342 1 JY jy1 rac1-server Using 857123342 for database Id
Using 1 for instance number Specify the number of days of snapshots to choose from
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Entering the number of days (n) will result in the most recent
(n) days of snapshots being listed. Pressing <return> without
specifying a number lists all completed snapshots. Enter value for num_days: 1
//注意这里根据实际需要选择几天的AWR报告,一般取最近的AWR报告选择1天即可
Listing the last day's Completed Snapshots Snap
Instance DB Name Snap Id Snap Started Level
------------ ------------ --------- ------------------ -----
jy1 JY 92 16 Oct 2014 07:32 1
93 16 Oct 2014 09:00 1
94 16 Oct 2014 10:00 1
95 16 Oct 2014 11:00 1 Specify the Begin and End Snapshot Ids
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Enter value for begin_snap: 94
Begin Snapshot Id specified: 94 Enter value for end_snap: 95
End Snapshot Id specified: 95 //注意这里输入的begin_snap 和 end_snap都是根据上面具体时间点对应的实际Snap Id那一列决定的. 比如我要选 09:00 - 10:00的话,那起始就应该是93和94. Specify the Report Name
~~~~~~~~~~~~~~~~~~~~~~~
The default report file name is awrrpt_1_94_95.html. To use this name,
press <return> to continue, otherwise enter an alternative. Enter value for report_name:
//这里默认回车即可,名字会有一个默认值的。
Using the report name awrrpt_1_94_95.html
此处省略大量屏幕输出..
End of Report
</BODY></HTML>
Report written to awrrpt_1_94_95.html
SQL> !pwd
/home/oracle
注:生成的报告文件发送给我即可,例如此处就是指awrrpt_1_94_95.html文件,代表的是2014年10月16日10点~11点这一小时的数据库实例jy1的工作负载报告。
2.RAC的其他实例AWR报告提取:@?/rdbms/admin/awrrpti
SQL> @?/rdbms/admin/awrrpti Specify the Report Type
~~~~~~~~~~~~~~~~~~~~~~~
Would you like an HTML report, or a plain text report?
Enter 'html' for an HTML report, or 'text' for plain text
Defaults to 'html'
Enter value for report_type: Type Specified: html Instances in this Workload Repository schema
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ DB Id Inst Num DB Name Instance Host
------------ -------- ------------ ------------ ------------
857123342 2 JY jy2 rac2-server
* 857123342 1 JY jy1 rac1-server Enter value for dbid: 857123342
Using 857123342 for database Id
Enter value for inst_num: 2
Using 2 for instance number Specify the number of days of snapshots to choose from
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Entering the number of days (n) will result in the most recent
(n) days of snapshots being listed. Pressing <return> without
specifying a number lists all completed snapshots. Enter value for num_days: Listing all Completed Snapshots Snap
Instance DB Name Snap Id Snap Started Level
------------ ------------ --------- ------------------ -----
jy2 JY 91 14 Oct 2014 10:10 1 92 16 Oct 2014 07:32 1
93 16 Oct 2014 09:00 1
94 16 Oct 2014 10:00 1
95 16 Oct 2014 11:00 1 Specify the Begin and End Snapshot Ids
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Enter value for begin_snap: 94
Begin Snapshot Id specified: 94 Enter value for end_snap: 95
End Snapshot Id specified: 95 Specify the Report Name
~~~~~~~~~~~~~~~~~~~~~~~
The default report file name is awrrpt_2_94_95.html. To use this name,
press <return> to continue, otherwise enter an alternative. Enter value for report_name: Using the report name awrrpt_2_94_95.html 此处省略大量屏幕输出.. End of Report
</BODY></HTML>
Report written to awrrpt_2_94_95.html
3.手工生成一个快照:
exec dbms_workload_repository.create_snapshot();
SQL> exec dbms_workload_repository.create_snapshot(); PL/SQL procedure successfully completed.
Oracle AWR报告提取方法的更多相关文章
- AWR报告提取方法
AWR报告提取方法 关键字 AWR报告 内容描述 AWR报告的提取方法 涉及设备 oracle 10g 操作说明 [问题现象描述] 现场提取AWR报告 [分析结论及解决方案] Awr报告生成方法 进入 ...
- Oracle AWR报告指标全解析-11011552
1-5 Top 5 Timed EventsWaits : 该等待事件发生的次数, 对于DB CPU此项不可用Times : 该等待事件消耗的总计时间,单位为秒, 对于DB CPU 而言是前台进程所消 ...
- Oracle AWR 报告详解
转自:http://blog.csdn.net/laoshangxyc/article/details/8615187 持续更新中... Oracle awr报告详解 DB Name DB Id In ...
- (原创)如何在性能测试中自动生成并获取Oracle AWR报告
版权声明:本文为原创文章,转载请先联系并标明出处 由于日常使用最多的数据库为Oracle,因此,最近又打起了Oracle的AWR报告的主意. 过去我们执行测试,都是执行开始和结束分别手动建立一个快照, ...
- ORACLE AWR报告生成步骤
ORACLE AWR报告生成步骤 (以PL/SQL中命令窗口为例) 1.sqlplus或plsql的commod窗口(命令窗口)运行命令 @D:\oracle\product\10.2.0\db_1\ ...
- 快速熟悉 Oracle AWR 报告解读
目录 AWR报告简介 AWR报告结构 基本信息 Report Summary Main Report RAC statistics Wait Event Statistics 参考资料 本文面向没有太 ...
- ORACLE AWR报告数据的导入导出实践
关于AWR的快照数据可以导出.导入,一直没有亲手实践过.今天动手测试了一下如何导出.导入AWR数据,将AWR的数据从一测试服务器,导入到另外一台测试服务器. SQL> @?/rdbms/admi ...
- ORACLE AWR报告生成过程出现多个实例记录分析
在一次生成AWR报告中,发现在"Instances in this Workload Repository schema"部分,出现了多个实例记录信息(host敏感信息被用host ...
- 转: Oracle AWR 报告 每天自动生成并发送邮箱
原贴地址:http://www.cnblogs.com/vigarbuaa/archive/2012/09/05/2671794.html Oracle AWR 介绍http://blog.csdn. ...
随机推荐
- OperateLoger
protected void Page_Load(object sender, EventArgs e) { OperateLoger.FunctionInfo =new FunctionInfo { ...
- HDU5909 Tree Cutting(树形DP + FWT)
题目 Source http://acm.hdu.edu.cn/showproblem.php?pid=5909 Description Byteasar has a tree T with n ve ...
- HTML label标签的一点理解
label标签为input元素定义标注. label元素不呈现任何特殊效果.不过他为鼠标用户改进了可用性.如果你在label元素内点击文本就会触发此控件.就是说当用户选择该标签是,浏览器就会自动的将焦 ...
- 面试题---PHP
1.PHP(外文名: Hypertext Preprocessor,中文名:“超文本预处理器”)是一种通用开源脚本语言. 2.echo,print和print_r的区别: echo和print都可以做 ...
- 给dos命令“.bat”文件换图标
最近客户有个需求:给企业建立一个FTP服务器,并且给不同的部门分配不同的目录和管理权限. 这个好实现!直接安装serv-u,进行一番设置,搞定! 不过客户嫌登陆FTP操作麻烦,输入ip,输入账号什么的 ...
- Socket编程中 setsockopt的作用
功能描述: 获取或者设置与某个套接字关联的选 项.选项可能存在于多层协议中,它们总会出现在最上面的套接字层.当操作套接字选项时,选项位于的层和选项的名称必须给出.为了操作套接字层的选项,应该 将层的值 ...
- linearlayout 中ImageView 居中等问题
linearlayout 下的子控件使用android:layout_gravity=”center” 控件居左,没有达到居中的效果, 父窗体只能指定一种控件摆放方向 横向还是竖向 下面我弄了三个 ...
- 面向对象的JavaScript --- 动态类型语言
面向对象的JavaScript --- 动态类型语言 动态类型语言与面向接口编程 JavaScript 没有提供传统面向对象语言中的类式继承,而是通过原型委托的方式来实现对象与对象之间的继承. Jav ...
- 测试webservice的时候,如果出现这个错误:"The test form is only available for requests from the local machine"
测试webservice的时候,如果出现这个错误:"The test form is only available for requests from the local machine&q ...
- Twitter的SnowFlake分布式id生成算法
二进制相关知识回顾 1.所有的数据都是以二进制的形式存储在硬盘上.对于一个字节的8位到底是什么类型 计算机是如何分辨的呢? 其实计算机并不负责判断数据类型,数据类型是程序告诉计算机该如何解释内存块. ...