第一范文网 - 专业文章范例文档资料分享平台

ASH和AWR

来源:用户分享 时间:2025/7/30 2:05:17 本文由loading 分享 下载这篇文档手机版
说明:文章内容仅供预览,部分内容可能不全,需要完整文档或者需要复制内容,请下载word后使用。下载word有问题请添加微信号:xxxxxxx或QQ:xxxxxx 处理(尽可能给您提供完整文档),感谢您的支持与谅解。

-- Examples: -1:15 (SYSDATE - 1 Hr 15 Mins) -- -25 (SYSDATE - 25 Mins) Defaults to -15 mins

Enter value for begin_time: -10

输入报表分析的开始时间,这里即可以输入一个时间类型的字串,比如

09/23/2009 14:30:15,也可以直接输入时间,甚至更简单的,输入一个负整数例如-10,表示当前时间前10分钟做为开始时间。

Report begin time specified: -10

Enter duration in minutes starting from begin time: Defaults to SYSDATE - begin_time Press Enter to analyze till current time Enter value for duration: 8

然后要输入统计的时间段,注意哟,不是让输入结束时间,而是说在前面输入的开始时间的基础上,希望收集多长时间内的信息做统计,默认情况下为sysdate-begin_time,即从开始时间到当前时间,这里为了显的与众不同,我就随便敲了个8。

Report duration specified: 8

Using 05-11 月-09 09:33:44 as report begin time Using 05-11 月-09 09:41:44 as report end time ........................ ........................

Specify the Report Name ~~~~~~~~~~~~~~~~~~~~~~~

The default report file name is ashrpt_1_1105_0941.html. To use this name, press to continue, otherwise enter an alternative.

Enter value for report_name:

输入报表的名称,默认会根据前面输入的值来生成一个名称,比如这里默认生成的名称为ashrpt_1_1105_0941.html。

Using the report name ashrpt_1_1105_0941.html Summary of All User Input ------------------------- Format : HTML DB Id : 3812548755 Inst num : 1

Begin time : 05-11 月-09 09:33:44 End time : 05-11 月-09 09:41:44 Slot width : Default Report targets : 0

Report name : ashrpt_1_1105_0941.html

报表成功生成,可以随时打开ashrpt_1_1105_0941.html浏览详细信息了。

2、生成指定数据库实例的指定时间段时的统计报表

对于RAC架构的数据库,有时候DBA可能会希望看到其中某个节点(或实例)的负载情况,这种情况下,可以使用ashwrpi.sql(附加的i应该是表示instance),例如:

SQL> @$ORACLE_HOME/rdbms/admin/ashrpti.sql Specify the Report Type ~~~~~~~~~~~~~~~~~~~~~~~

Enter ¨html¨ for an HTML report, or ¨text¨ for plain text Defaults to ¨html¨

Enter value for report_type: html

选择生成的报表文件类型,仍然选择html类型。

Type Specified: html

Instances in this Workload Repository schema

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ DB Id Inst Num DB Name Instance Host ------------ -------- ------------ ------------ ------------ 948405229 2 JSSDB jssdbn2 jssdbn2 * 948405229 1 JSSDB jssdbn1 jssdbn1 Defaults to current database Enter value for dbid: 948405229

这里多了两步,首先是要选择数据库的DBID,接下来是选择实例ID。

Using database id: 948405229 Defaults to current instance Enter value for inst_num: 1 Using instance number: 1

ASH Samples in this Workload Repository schema

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Oldest ASH sample available: 15-Oct-09 21:24:53 [ 29499 mins in the past] Latest ASH sample available: 05-Nov-09 09:00:56 [ 3 mins in the past] Specify the timeframe to generate the ASH report

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Enter begin time for report: -- Valid input formats:

-- To specify absolute begin time: -- [MM/DD[/YY]] HH24:MI[:SS] -- Examples: 02/23/03 14:30:15 -- 02/23 14:30:15 -- 14:30:15 -- 14:30

-- To specify relative begin time: (start with ¨-¨ sign) -- -[HH24:]MI

-- Examples: -1:15 (SYSDATE - 1 Hr 15 Mins) -- -25 (SYSDATE - 25 Mins) Defaults to -15 mins Enter value for begin_time:

输入开始的时间,后面的步骤与前面生成数据库级的操作完全相同,不再演示。 前面介绍的这种种特性以及脚本均是工具,工具永远都只是起辅助的作用,能不能用

好,还是取决于使用工具的人,祝好运吧。

搜索更多关于: ASH和AWR 的文档
ASH和AWR.doc 将本文的Word文档下载到电脑,方便复制、编辑、收藏和打印
本文链接:https://www.diyifanwen.net/c04744926fg79ew80p2vj_11.html(转载请注明文章来源)
热门推荐
Copyright © 2012-2023 第一范文网 版权所有 免责声明 | 联系我们
声明 :本网站尊重并保护知识产权,根据《信息网络传播权保护条例》,如果我们转载的作品侵犯了您的权利,请在一个月内通知我们,我们会及时删除。
客服QQ:xxxxxx 邮箱:xxxxxx@qq.com
渝ICP备2023013149号
Top