In Part 2 we are going to look at making use of the trace events that show what was discussed in Part 1.
NB: Oracle no longer adds new numeric trace events, going forward new trace events use the Unified Tracing Service whose grammer is much simpler. The elements we need are:
trace[[x.]y] disk = [ lowest | low | medium | high | highest ]
For example Table Scan tracing is in the DATA hierachy:
[1] DATA
[2] KDS “Kernel Data Scan”
[3] KDSFTS “Full Table Scan”
[3] KDSRID “RowID”
‘trace[KDSFTS] disk low’ – only trace full table scans
‘trace[KDSRID] disk low’ – only trace fetch by rowid
‘trace[KDS.*] disk low’ – trace both table scans and fetch by rowid
NB: don’t use ‘lowest’ with KDS – it is used for memory tracing only
Tracing Full Table Scans: KDSFTS
At the beginning of a granule we see if it is possible to use Turbo Scan (which is a prerequisite for using Exadata Smart Scan) and the data object number being scanned:
Continue reading