Oracle jobs为Oracle开发人员和数据库管理员提供了数据库层面维护的极大便利性。对于Oracle jobs在Oracle 9i之前,是由dbms_jobs来实现,而到了10g之后,多出了dbms_scheduler方式。两者同样可以添加Oracle job,只不过dbms_scheduler的功能更为强大。在使用Oracle jobs时,我们不得不关注job_queue_processes参数,用于设定job队列可以启动的进程数。本文即是围绕此展开。查看该参数命令:
show parameter job;
1、job_queue_processes参数
alter system set job_queue_processes= 0,1000
下面是11g reference的描述:
JOB_QUEUE_PROCESSES specifies the maximum number of job slaves per instance that can be created for the execution of DBMS_JOB jobs and Oracle Scheduler (DBMS_SCHEDULER) jobs. DBMS_JOB and Oracle Scheduler share the same job coordinator and job slaves, and they are both controlled by the JOB_QUEUE_PROCESSES parameter.
If the value of JOB_QUEUE_PROCESSES is set to 0, then DBMS_JOB jobs and Oracle Scheduler jobs will not run on the instance.If JOB_QUEUE_PROCESSES is set to a value in the range of 1 to 1000, then DBMS_JOB jobs and Oracle Scheduler jobs will run. The actual number of job slaves created for Oracle S