Use of oradebug (practical part) (in continuous update)


Trace a session

For example, if I want to track a session, I need to obtain the SID, serial ID, and SPID of the session first

SELECT a.username,
  a.sid ,
FROM v$session a,
  v$process b
WHERE a.paddr=b.addr
and a.sid = 285

USERNAME                              SID    SERIAL# SPID
------------------------------ ---------- ---------- ------------------------
APPS                                  285      44645 30468

Then use oradebug to set the event on the target session, trace, and get the name of trace file

SQL > oradebug setospid 30468 -- process SPID

SQL> oradebug event 10046 trace name context forever,level 12

SQL> oradebug event 10046 trace name context off



Recommended Today

1500 lines of typescript code to implement the component keep alive in react

The essence of modern frameworkDomOperation, I like a sentence today. Don’t set limits for yourself. In the end, most of the technical essence is the same. For example, the back endKafka, redis, SQL transaction writing, nginxLoad balancing algorithm,diffAlgorithmGRPC,Pb protocolThe serialization and deserialization, locks, etc. of can be similar to a large number of reuse logic […]