WARNING: This web is not used anymore. Please use PDBService.RecycleBinPurging instead!
 

Recycle Bin automatic purging

  • This script creates a job that automatically purges all objects (tables) in recycle bin that are older than 7 days (edit the default in the installation script if necessary)
  • Job, by default, runs every day at 7 a.m.

Installaion

  • connect to pdb-backup
   $ cd ~/production/recyclebin
   $ sqlplus system@<db_name> @purge_old_recyclebin
  • please ignore the error of dropping non-existing job

Enabling/Disabling

  • connect to the target database
  • to disable automatic purging please execute the following command:
exec DBMS_SCHEDULER.DROP_JOB('SYSTEM.PURGE_OLD_RECYCLEBIN_JOB',TRUE);
  • to enable it (please set BYHOUR=... parameter to the hour the purging should start - important in streams environment to allow it to run first on the capture side and then after few hours on the apply side):
exec DBMS_SCHEDULER.CREATE_JOB('SYSTEM.PURGE_OLD_RECYCLEBIN_JOB','PLSQL_BLOCK','PURGE_OLD_RECYCLEBIN(7);',0,sysdate,'FREQ=DAILY;BYDAY=MON,TUE,WED,THU,FRI;BYHOUR=7;BYMINUTE=0;BYSECOND=0;',NULL,'DEFAULT_JOB_CLASS',TRUE,TRUE,NULL);

Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r3 - 2007-09-03 - DawidWojcik
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    PSSGroup All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright &© 2008-2023 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
or Ideas, requests, problems regarding TWiki? use Discourse or Send feedback