To trace the other user's session in Oracle 10g,
Step 1: Set the init parameter.
SQL> Alter system set TIMED_STATISTICS = TRUE;
SQL> Alter system set MAX_DUMP_SIZE = UNLIMITED;
SQL> Alter system set TRACEFILE_IDENTIFIER = ‘mytrace’;
Step 2: Enable Tracing
SQL> Exec DBMS_MONITOR.session_trace_enable(149,3643, TRUE, TRUE);
Where
1st Parameter: Session ID. (null means current session’s ID)
2nd Parameter: Serial # (null means current session’s serial#)
3rd Parameter: Trace Waits (Default True)
4th Parameter: Bind Variables (Default False)
Step 3: Disable Tracing
SQL> Exec DBMS_MONITOR.SESSION_TRACE_DISABLE(149,3643);
Thanks
Wednesday, July 29, 2009
Subscribe to:
Post Comments (Atom)
1 comment:
We have already learned how to trace your own session in your previous posts. This post describe how to trace others session in 10g. The steps are similar to those were for tracing own session with slight difference. You can try it.
Post a Comment