Originally posted by jwhite
Nice explanation of TKProf. This is related, as I need the raw trace files to use with TKProf...

I have no problem starting the first trace session using: DBMS_SYSTEM.SET_SQL_TRACE_IN_SESSION(SID, Serial#, TRUE);

When I stop the trace that is fine as well.

The problem is if I delete the trace files, then try to re-start the trace, nothing happens. I have to kill the connection, and then re-start the trace. Does anyone know why? This is on Unix. I would expect Oracle to find the files not there and then re-create them.
Hello friends
Shreyas here. All the steps related are really upto the mark.
No issues. But some suggestions to add.
We can also know which is the trace file by joining v$session and
v$process which will give you the spid. So this spid.trc would be the
trace file for your session.
I more thing I would like to mention .
Do not try explain= with your trace file. Because maybe the explain plan would show you a different execution path rather than it really
took which you will see in the trace file.
Just look closely towards the end of the trace file if you are also
considering the explain= parameter in your output file.
The difference is noticeable.
You can also find whether a query is using the BIND variable
which could be a very important factor related to the performance of
that query or database.
Check for the wait events also.
The XCENTD would also show you some more related statistics
Well maybe this part could be useful. Correct me if I am wrong.
Thanks and Regards,
Shreyas.