dba_scheduler_running_jobs

Using DBA_SCHEDULER_RUNNING_JOBS one can see jobs currently running. In the example below it shows the oracle session id and corresponding OS process id.

22:20:51 sys@TESTDB> select job_name, session_id from dba_scheduler_running_jobs;

JOB_NAME SESSION_ID
—————————— ———-
GATHER_STATS_JOB 364

1 row selected.

sys@TESTDB> select program from v$session where sid = 364;

PROGRAM
————————————————
oracle@hostname (J002)

1 row selected.

sys@TESTDB> select vs.program, spid from v$session vs, v$process vp where vs.sid = 364 and vs.paddr = vp.addr

PROGRAM SPID
———————————————— ————
oracle@hostname (J002) 1642698

1 row selected.

Oracle j000 shadow processes are DBMS_SCHEDULER sessions

sys@TESTDB> !ps -ef | grep 1642698
oracle 1642698 1 120 00:00:07 – 1071:14 ora_j002_TESTDB
oracle 13836458 11677872 2 22:23:06 pts/5 0:00 grep 1642698

One thought on “dba_scheduler_running_jobs

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.