Change the default behaviour and take snapshots EVERY 15 minute


bash-3.2$ sqll
SQL*Plus: Release 11.2.0.3.0 Production on Thu Apr 10 10:43:32 2014
Copyright (c) 1982, 2011, Oracle. All rights reserved.
 Connected to:
 Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
 With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
 Data Mining and Real Application Testing options
 SQL> select name ,open_mode from v$database;
NAME OPEN_MODE
 --------- --------------------
 ANARDB READ WRITE
SQL> SELECT extract(day from snap_interval) *24*60+extract(hour from snap_interval) *60+extract(minute from snap_interval) snapshot_Interval,
 2 extract(day from retention) *24*60+extract(hour from retention) *60+extract(minute from retention) retention_Interval
 3 FROM dba_hist_wr_control;
SNAPSHOT_INTERVAL RETENTION_INTERVAL
 ----------------- ------------------
 60 43200
SQL> BEGIN
 2 DBMS_WORKLOAD_REPOSITORY.modify_snapshot_settings(
 3 interval => 15);
 4 END;
 5 /
PL/SQL procedure successfully completed.
SQL> SELECT extract(day from snap_interval) *24*60+extract(hour from snap_interval) *60+extract(minute from snap_interval) snapshot_Interval,
 2 extract(day from retention) *24*60+extract(hour from retention) *60+extract(minute from retention) retention_Interval
 3 FROM dba_hist_wr_control;
SNAPSHOT_INTERVAL RETENTION_INTERVAL
 ----------------- ------------------
 15 43200

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: