Oracle RAC环境下配置Statspack(3)

BEGIN
  DBMS_SCHEDULER.create_job (
      job_name          => 'ORCL_PERFSTAT_COLLECT_N2',
      program_name      => 'PROC_RAC_STATSPACK',
      start_date        => SYSTIMESTAMP,
      repeat_interval  => 'FREQ=hourly; INTERVAL=1; BYMINUTE=30',
      job_class        => 'statspack_suse11b_class',
      comments          => 'This job will run on suse11b',
      enabled          => TRUE);

DBMS_SCHEDULER.create_job (
      job_name          => 'ORCL_PERFSTAT_PURGE_N2',
      job_type          => 'PLSQL_BLOCK',
      job_action        => 'begin STATSPACK.PURGE(31); end;',
      start_date        => SYSTIMESTAMP,
      repeat_interval  => 'FREQ=DAILY; BYHOUR=23; BYMINUTE=30',
      job_class        => 'statspack_suse11b_class',
      enabled          => TRUE);
END;
/

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/1b813002984f8ee946134010907ab29b.html