时间:2021-07-01 10:21:17 帮助过:24人阅读
2) 正确设置AWR快照
select * from cdb_hist_wr_control; DBID SNAP_INTERVAL RETENTION TOPNSQL CON_ID 2580889417 +40150 00:01:00.0 +00008 00:00:00.0 DEFAULT 3 execute dbms_workload_repository.modify_snapshot_settings(interval => 60); select * from cdb_hist_wr_control; DBID SNAP_INTERVAL RETENTION TOPNSQL CON_ID 2580889417 +00000 01:00:00.0 +00008 00:00:00.0 DEFAULT 3
3) 另请将AWR_SNAPSHOT_TIME_OFFSET设置为1000000,以避免多个PDB同时创建快照时出现性能问题。
alter system set AWR_SNAPSHOT_TIME_OFFSET=1000000 scope=both;
4) 等待1-2小时以自动生成快照:
select * from awr_pdb_snapshot;
或者您可以手动创建快照:
SQL> connect / as sysdba SQL> alter session set container=PDB1; SQL> exec dbms_workload_repository.create_snapshot();
创建AWR报告:
@?/rdbms/admin/awrrpt Specify the location of AWR Data ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ AWR_ROOT - Use AWR data from root (default) AWR_PDB - Use AWR data from PDB ** Use the location AWR_PDB for a PDB level report
Oracle 12.2 或更高版本的PDB级别创建AWR报告
标签:font 启用 repos 功能 enabled 详细步骤 sele containe evel