@?/rdbms/admin/awrrpt.sql //awr报告
@?/rdbms/admin/awrsqrpt.sql //执行计划
cd $ORACLE_HOME/rdbms/admin/
SQL> conn /as sysdba;
Connected.
SQL> show user;
USER is "SYS"
SQL> @awrrpt.sql
Enter value for report_type: html //输出为html
Enter value for num_days: 1 //1天
Listing the last day's Completed Snapshots
Snap
Instance DB Name Snap Id Snap Started Level
------------ ------------ --------- ------------------ -----
jrtdbtest JRTDBTES 2494 08 Sep 2011 00:00 1
2495 08 Sep 2011 01:00 1
2496 08 Sep 2011 02:00 1
2497 08 Sep 2011 03:00 1
2498 08 Sep 2011 04:00 1
2499 08 Sep 2011 05:00 1
2500 08 Sep 2011 06:00 1
2501 08 Sep 2011 07:00 1
2502 08 Sep 2011 08:00 1
2503 08 Sep 2011 09:00 1
2504 08 Sep 2011 10:00 1
2505 08 Sep 2011 11:00 1
2506 08 Sep 2011 12:00 1
2507 08 Sep 2011 13:00 1
2508 08 Sep 2011 14:00 1
2509 08 Sep 2011 15:00 1
2510 08 Sep 2011 16:00 1
Specify the Begin and End Snapshot Ids
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Enter value for begin_snap: 2494 //开始
Begin Snapshot Id specified: 2494
Enter value for end_snap: 2510 //结束
End Snapshot Id specified: 2510
Specify the Report Name
~~~~~~~~~~~~~~~~~~~~~~~
The default report file name is awrrpt_1_1796_1813.html. To use this name,
press <return> to continue, otherwise enter an alternative.
Enter value for report_name: feng //文件的名字
SQL>quit
ls |grep feng 找到你文件
参考:
http://space.itpub.net/17203031/viewspace-700471