The reason why the oracle task process is not executed after it is submitted is
/* Run the following command in SQL * Plus */-- check steps when the task is not running -- 1. check whether the instance session is RESTRICTED by select instance_name, logins from v $ instance; -- if the message "logins = restricted" is displayed, execute alter system disable RESTRICTED session; -- 2. ensure that job_queue_processes> 0 show parameter job_queue_processes; -- 3. check whether the task is still running select * from dba_jobs_running;
The problem I encountered is that the previously submitted task is still running, so I will not execute the same task again. The number of concurrent task execution processes set by oracle is limited. Therefore, when the last submitted task is not completed, the task submitted again can only wait in the queue and will not be executed directly.
I wrote a view to conveniently query the currently executed tasks.
-- Query a running task/* grant the user permission to select on dba_jobs_running to a2admin under sys logon; grant select on v _ $ session to a2admin; */create or replace view job_run_viewasselect. job,. sid, B. SERIAL #,. failures,. last_date,. this_date,. instance from dba_jobs_running a, v $ session B where. sid = B. sid order by 1;
To disable the task process, run the following code to replace sid and serial #
-- Disable process sid, serial #, and replace it with the corresponding value -- alter system kill session 'sid, serial ';