Monday, 1 April 2019

How to purge old AWR Snapshots??

Make sure there is adequate space for Archive Generation.

Procedure for AWR Purging

 1) Run following script as SYS user to take export backup
    cd $ORACLE_HOME/rdbms/admin
    @awrextr.sql

@?/rdbms/admin/awrextr


 2) It will ask for dbid
    Give dbid for database

3) It will ask for num_days
    press enter,by default it will give all snaps generated

4) It will ask for begin_snap(Snap_id from where u want start export backup)

5) It will ask for end_snap(Snap_id upto which u want to take export backup)

    export dump will be taken from begin_snap to end_snap
6) It will ask for Directory name
    Give AWR_PURGE

7) It will ask for file_name,For file name use following conventions
    awr_dbname_(begin_snap_date)_(end_snap_date)

8) It will generate export backup from begin_snap to end_snap
    once export backup completed successfully.

Do following Steps for deleting snaps

Ex.

exec  dbms_workload_repository.DROP_SNAPSHOT_RANGE(115112,115440);

Once it will complete successfully please run  awrrpt.sql to confirm.





How to login on Oracle Cloud Console?

Login Steps for Oracle Cloud Console To sign in to Oracle Cloud Console, We need to open up the corresponding region console URL for Free Ti...