Under Linux, how does Oracle operate all SQL that can be monitored by the database, just as SQLServerProfiler can do?

  linux, question

Like SQLServerProfiler, any session that executes a certain SQL can be recorded and displayed?

For versions after 10g, dbms_monitor package commands can be used to start database and session-level tracking. For previous versions, 10046 events can only be used.

dbms_monitor.session_trace_enable(sid => 127, serial => 29)
 dbms_monitor.session_trace_disable(sid => 127, serial => 29)

After trace is finished, a. trc file will be generated, which can be formatted and summarized by using the tkprof tools provided by oracle, such as:

tkprof crm_ora_2960_adam.trc adam.txt aggregate=yes sys=no waits=yes sort=fchela