强制MMON进程立即收集快照:
execute DBMS_WORKLOAD_REPOSITORY.create_snapshot;
调整快照管理:
execute DBMS_WORKLOAD_REPOSITORY.modify_snapshot_settings(retention =>43200, interval =>30);
快照每30分钟采集一次,保留30天(60*24*30=43200),单位:分钟。
将指定快照无限期地存储为指定的基准:
execute DBMS_WORKLOAD_REPOSITORY.create_baseline(start_snap_id =>487, end_snap_id =>488, baseline_name => 'FridayPM');
列出AWR中的所有快照:
select snap_id, begin_interval_time, from dba_hist_snapshot
order by begin_interval_time desc;
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/81227/viewspace-689245/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/81227/viewspace-689245/