Professional Documents
Culture Documents
1. 2. 3. '. ). Alerts Metrics AWR ( 7 days of history !A"H#$%" & %i(e Model Wait Classes
6. Misc
#.1
Alerts $et
select (etrics"*a(e alert+ ,ar*i*g"operator op+ ,ar*i*g"-al.e ,ar* + o/0ect"*a(e o/0 fro( d/a"thresholds1
ALERT ----------------------------------Average Users Waiting Counts Concurrency B oc!e" User #ession Count CPU Ti$e Per User Ca Logons Per #ec #ession Li$it ( Ta& es*ace #*ace Usage Ta& es*ace #*ace Usage
Copyright 2006 Kyle Hailey
OP ---GT GT GE GE GT GE GE
#,#TE#.2
Alerts 2.tsta*di*g
select reaso*+ o/0ect"type type+ o/0ect"*a(e *a(e fro( d/a"o.tsta*di*g"alerts1
T,PE
NA-E
#.3
Alerts $etti*g
3B-#4#ER5ER4ALERT6#ET4T7RE#7OL38 METRICS_ID WARN9NG45ALUE -ETR9C#493 CR9T9CAL4OPERATOR WARN9NG4OPERATOR CR9T9CAL45ALUE WARN9NG45ALUE OB#ER5AT9ON4PER9O3 CR9T9CAL4OPERATOR INSTANCE_NAME OB#ER5AT9ON4PER9O3 OBJECT_NAME 9N#TANCE4NA-E OBJECT4T,PE OBJECT4NA-E => DBMS_SERVER_ALERT.CPU_TIME_PER_CALL, :; :; =%000=< "&$s4server4a ert6ta& es*ace4*ct42u :; :; 3B-#4#ER5ER4ALERT6OPERATOR4GE< "&$s4server4a ert6o*erator4ge< :; :; =10000=< )0< :; :; 1< "&$s4server4a ert6o*erator4ge< => :; 'SID' 1< < => :; 'SID') nu < :; :; "&$s4server4a ert6o&@ect4ty*e4ta& es*ace< =#,#TE-=AB WARN9NG4OPERATOR :; 3B-#4#ER5ER4ALERT6OPERATOR4GE< "&$s4server4a ert6set4t?res?o "8 <
http344,,,.pso.g.org4refere*ce4d/(s"ser-"alert.ht(l
Copyright 2006 Kyle Hailey
#.4
5i 10g Metrics
DBA_HIS _S!"S A
Waits
V$eventmetric
V$sessmetric
#.5
Metrics
What i*spired Metrics:
Alerti*g
#.6
#.7
1+)33+7?7
30 (i*.tes
#2@s
30 (i*.tes
ti(e
ti(e
Copyright 2006 Kyle Hailey
#.8
%a<e -al.e at ti(e A %a<e -al.e at ti(e ! elta B (!CA& or Rate B (!CA&4elapsed ti(e
#.9
Methods
2racle 6 Dtl/stat.s7l4Dtlestat.s7l
Creates
2-er<ill to r.* statspac< for o*e or t,o statistics+ *o, 10g gi-es .s (etric ta/les
#.10
#.11
Metrics
#*ter-als
1)
Calc.latio*s
eltas Rates
Ratios Gerce*tages
#.12
Metric %a/les
-ait .vents
Statistics
Fi#es
I6=#9FMF%R#C ( 10 (i*.tes&
S!"
!A"H#$%"$89$%A%
#.13
/ #24sec
30 (i*.tes
1+)33+7?7
01/ #24sec
#2@s
30 (i*.tes
ti(e
ti(e
Copyright 2006 Kyle Hailey
#.14
#.15
v$sysmetric
desc v$sysmetric BEGIN_TIME END_TIME INTSIZE_CSEC interval value in 1/100sec GROU _ID METRIC_ID METRIC_NAME !"#UE METRIC_UNIT
#.16
-6sys(etric 1) $ecs
Per Sec an( Per ransaction !.ffer Cache Hit Ratio Me(ory $orts Ratio FNec.te Witho.t Garse Ratio $oft Garse Ratio ata/ase CGD %i(e Ratio 9i/rary Cache Hit Ratio $hared Gool =ree O %N*s Ger 9ogo* Ghysical Reads Ghysical Writes Ghysical Reads irect Redo Ae*erated "ogons Dser Calls 9ogical Reads Redo Writes %otal %a/le $ca*s =.ll #*deN $ca*s ! !loc< Aets Co*siste*t Read Aets ! !loc< Cha*ges 1onsistent 2ea( 1$anges FNec.tio*s
#.17
-6sys(etric 60 $ec
!.ffer Cache Hit Ratio Me(ory $orts Ratio Redo Allocatio* Hit Ratio Dser Co((its Gerce*tage Dser Roll/ac<s Gerce*tage C.rsor Cache Hit Ratio Ro,s Ger $ort FNec.te Witho.t Garse Ratio $oft Garse Ratio Dser Calls Ratio Alo/al Cache A-erage CR Aet %i(e Alo/al Cache A-erage C.rre*t Aet %i(e Alo/al Cache !loc<s Corr.pted Alo/al Cache !loc<s 9ost C.rre*t 9ogo*s Co.*t C.rre*t 2pe* C.rsors Co.*t Dser 9i(it O $89 $er-ice Respo*se %i(e ata/ase Wait %i(e Ratio ata/ase CGD %i(e Ratio Ro, Cache Hit Ratio Ro, Cache Miss Ratio 9i/rary Cache Hit Ratio 9i/rary Cache Miss Ratio $hared Gool =ree O GAA Cache Hit O Grocess 9i(it O $essio* 9i(it O %N*s Ger 9ogo*
#.18
-6sys(etric 60 $ec
Per Secon( an( ransaction Per Sec Dser Co((its Dser Roll/ac<s Dser %ra*sactio* !WR Chec<poi*ts !ac<gro.*d Chec<poi*ts >et,or< %raffic Iol.(e Per ransaction Respo*se %i(e
Ghysical Reads Ghysical Writes Ghysical Reads irect Ghysical Writes irect Ghysical Reads irect 9o/s Ghysical Writes irect 9o/s Redo Ae*erated "ogons 2pe* C.rsors Dser Calls Rec.rsi-e Calls 9ogical Reads Redo Writes 9o*g %a/le $ca*s %otal %a/le $ca*s =.ll #*deN $ca*s %otal #*deN $ca*s %otal Garse Co.*t Hard Garse Co.*t Garse =ail.re Co.*t
Copyright 2006 Kyle Hailey
is< $ort F*7.e.e %i(eo.ts F*7.e.e Waits F*7.e.e eadloc<s F*7.e.e Re7.ests ! !loc< Aets Co*siste*t Read Aets ! !loc< Cha*ges 1onsistent 2ea( 1$anges 1P3 3sage 12 B#oc4s 1reate( 12 3n(o 2ecor(s A''#ie( 3ser 2o##5ac4 3n(o 2ecor(s A''#ie( 9eaf >ode $plits !ra*ch >ode $plits GK do,*graded 1 to 2)O GK do,*graded 2) to )0O GK do,*graded )0 to 7)O GK do,*graded 7) to 55O .
#.19
-6sess(etric
desc -6sess(etric
!FA#>"%#MF F> "%#MF #>%$#PF"C$FC S.SSI,N_ID $F$$#2>"$FR#A9">DM 1P3 PH6SI1A"_2.ADS P7A_+.+,26 HA2D_PA2S.S $2=%"GAR$F$ GHJ$#CA9"RFA "GC% 92A#CA9"RFA "GC%
#.20
esc -6e-e*t(etric
SQL> desc v eve!"#e"$%c N&#e )))))))))))))))))))))))))))))))))) BE*IN_TIME END_TIME INTSI+E_CSEC EVENT, EVENT_ID NUM_SESS_-AITIN* TIME_-AITED -AIT_COUNT T'(e )))))) DATE DATE NUMBER NUMBER NUMBER NUMBER NUMBER NUMBER
#.21
Historical Metrics
We sol-ed ,hat@s happe*i*g *o,; /.t What if yo.r pro/le( happe*ed 10 (i*.tes ago: Ho, do ,e get History: What happe*ed i* the past:
#.22
delta delta
60 secs
60 secs
60 secs
60 secs
60 secs
60 secs
60 secs
#.23
$tatistics
I6$J$MF%R#C"H#$%2RJ
=ile #2
I6=#9FMF%R#C"H#$%2RJ
Waits
I6WA#%C9A$$MF%R#C"H#$%2RJ
CM2>CJJ HH2'3M#L&+
5ALUE -ETR9C4UN9T
11F'% 11%6D+ Rea"s Per #econ" 11F') 1D6D1DDDD1 Rea"s Per #econ" 11FE0 '6EE1101+' Rea"s Per #econ" 11FE1 >%61 Rea"s Per #econ" 11FE> 1)6D1DDDD1 Rea"s Per #econ"
#.25
fro(
#.26
Metric Alerts
#f Alerts fire o* Metrics+ the* the deltas are <ept i* historical ta/le for 7 days /y defa.lt
$tatistics
!A"H#$%"$J$MF%R#C"H#$%2RJ !A"H#$%"$F$$MF%R#C"H#$%2RJ
Waits
WA#%C9A$$MF%R#C"H#$%2RJ
>ot to /e co*f.sed ,ith the other (etric ta/les+ these o*ly ha-e -al.es ,he* alerts fire
=ile #2
!A"H#$%"=#9FMF%R#C"H#$%2RJ
#.27
Now
V$sysmetric V$S6S+. 2I1 V$S6S+. 2I1_S3++A26 V$S.SS+. 2I1 Session 8 v$sessmetric V$sysmetric_$istory V$sysmetric_summary
v$fi#emetric
v$waitc#assmetric_$istory
v$fi#emetric_$istory
1 Hour
DBA_HIS _S6S+. 2I1_HIS ,26 DBA_HIS _S.SS+. 2I1_HIS ,26 DBA_HIS _ S6S+. 2I1_S3++A26
DBA_HIS _S!"S A
DBA_HIS _S6S .+_.V.N
#.28
A-2
Automatic -or4#oa( 2e'ository
$tatspac< o* $teroids More efficie*t tha* $tatspac<
More
#.29
$*apshoti*g
o*e a.to(atically o.t of the /oN+ /.t ca* /e r.* /y ha*d3 !FA#> !M$"W2RK92A "RFG2$#%2RJ.CRFA%F"$>AG$H2% (&1 F> 1 4
d/(s",or<load"repository.drop"s*apshot"ra*ge
#.30
!A"H#$%
DB"_)IST_D"T"B"SE_INST"NCE DB"_)IST_SN" S)OT * DB"_)IST_SN" _ERROR * DB"_)IST_B"SE#INE * DB"_)IST_+R_CONTRO# , -.'r/ l'a( re0'sit'r% ,1 * DB"_)IST_D"T"2I#E DB"_)IST_2I#EST"T3S 'nl% 4ile nu56er7 n' na5e * DB"_)IST_TEM 2I#E DB"_)IST_TEM ST"T3S 'nl8% 4ile nu56er 9DB"_)IST_S:#ST"T ;r'u0 6% 0arent curs'r 0lus DE#T"s .as -stats<s=l_su55ar%1 DB"_)IST_S:#TE3T 9DB"_)IST_S:#_SUMM"R> i(enti4% litterals -.as stat<s=l_statistics1 DB"_)IST_S:#_ #"N *DB"_)IST_S:#BIND *DBA_HIST_SQLBIND_META - -2H$_S!"_BIND_+. ADA A *DB"_)IST_O TIMIZER_EN! *DB"_)IST_E!ENT_N"ME DB"_)IST_S>STEM_E!ENT DB"_)IST_BG_E!ENT_SUMM"R> su5 '4 6ac/;r'un(s DB"_)IST_+"ITST"T DB"_)IST_EN:UEUE_ST"T *DB"_)IST_#"TC)_N"ME DB"_)IST_#"TC) DB"_)IST_#"TC)_C)I#DREN DB"_)IST_#"TC)_ "RENT DB"_)IST_#"TC)_MISSES_SUMM"R> su55e( 'ver 0arent latc? DB"_)IST_#IBR"R>C"C)E DB"_)IST_DB_C"C)E_"D!ICE DB"_)IST_BU22ER_ OO#_ST"T DB"_)IST_RO+C"C)E_SUMM"R> su55e( 'ver r'.cac?e entries DB"_)IST_SG" DB"_)IST_SG"ST"T DB"_)IST_ G"ST"T DB"_)IST_RESOURCE_#IMIT DB"_)IST_S)"RED_ OO#_"D!ICE ,DB"_)IST_S:#_+OR@"RE"_)STGRM DB"_)IST_ G"_T"RGET_"D!ICE DB"_)IST_INST"NCE_RECO!ER> DB"_)IST_A"!"_ OO#_"D!ICE DB"_)IST_T)RE"D * l';s.itc?es *DB"_)IST_ST"T_N"ME DB"_)IST_S>SST"T *DB"_)IST_S>S_TIME_MODE# *DB"_)IST_OSST"T_N"ME *DB"_)IST_OSST"T DB"_)IST_ "R"METER_N"ME DB"_)IST_ "R"METER DB"_)IST_UNDOST"T DB"_)IST_RO##ST"T DB"_)IST_SEG_ST"T DB"_)IST_SEG_ST"T_OBA '6Bect na5e *DB"_)IST_METRIC_N"ME *DB"_)IST_S>SMETRIC_)ISTOR> alert *DB"_)IST_S>SMETRIC_SUMM"R> 5aC7 5in7 av; stan(ar( (eviati'n *DB"_)IST_SESSMETRIC_)ISTOR> alert *DB"_)IST_2I#EMETRIC_)ISTOR> alert *DB"_)IST_+"ITC#"SSMET_)ISTOR> alert DB"_)IST_D#M_MISC *DB"_)IST_RC!R>_2I#E_DEST_ST"T *DB"_)IST_RM"N_ ER2ORM"NCE *DB"_)IST_"CTI!E_SESS_)ISTOR> ever% 10t? 0'int 4r'5 v<active_sessi'n_?ist'r% *DB"_)IST_T"B#ES "CE_ST"T *DB"_)IST_#OG DB"_)IST_MTTR_T"RGET_"D!ICE *DB"_)IST_TBS C_S "CE_US"GE * ,
>e, i* 10g
#.31
RETENT9ON
#NAP49NTER5AL Mi*.tes
RETENT9ON
#NAP49NTER5AL
#.32
AWR RG%
T:4rd/(s4ad(i*4a,rrpt.s7l
Creates Report =ile $i(ilar to $%A%$GACK report More efficie*t a*d (ore data H%M9 or %FK%
$F9FC% R =R2M %A!9F( d/(s",or<load"repository.a,r"report"teNt( (select d/id fro( -6data/ase&+ 1+ 12'+ CC /egi* id 12) CC e*d id &&
Copyright 2006 Kyle Hailey
#.33
AWR Report
1& 1& Ae*eral Ae*erali*fo i*fo 2& 2& 9oad 9oadGrofile Grofile 3& 3& Wait WaitF-e*ts F-e*ts '& '& 2$ 2$$tats $tats )& )& $er-ice $er-ice$tats $tats 6& 6& %op %op$89 $89 7& 7& $89 $89%eNt %eNt ?& ?& #*sta*ce #*sta*ce$tatistic $tatistic 5& 5& #42 #42$tat $tat 10& 10& !.ffer !.fferGool Gool$tats $tats
11& 11& Ad-isories Ad-isories 1& 1& !.ffer !.fferpool pool 2& 2& GAA GAA 3& 3& $hared $haredGool Gool '& '& $AA $AA )& )& $trea(s $trea(s 6& 6& Ua-a Ua-a
12& 12& !.ffer !.fferGool Gool$tats $tats 13& 13& Wait Wait$tats $tats 1& 1& !.ffer !.ffer!.sy !.sy 2& 2& F*7.e.es F*7.e.es 12& 12& D*do D*do$tats $tats 13& 13& 9atch 9atch$tats $tats 1'& 1'& $eg(e*t $eg(e*t$tats $tats 1)& 1)& ictio*ary ictio*ary$tats $tats 16& 16& 9i/rary 9i/raryCache Cache 17& 17& Me(ory Me(ory$AA4GAA $AA4GAA 1?& 1?& $trea(s $trea(s 15& 15& #*it.ora #*it.ora
#.34
A,r 1C13
#.35
AWR 1'C26
#.36
AWR iff
$F9FC% R =R2M %A!9F( d/(s",or<load"repository.a,r"diff"report"teNt( (select d/id fro( -6data/ase&+ 1+ 120+ 121+ (select d/id fro( -6data/ase&+ 1+ 122+ 123& &1 Also 3 AWR" #=="RFG2R%"H%M9
#.37
>2%F3 Gac<age AWR" #=="RFG2R%"H%M9 #s differe*t fro( 2FM #ts 0.st a ta/.lar o.tp.t
#.38
Also+ A
M report /y Ha*d
select d/(s"ad-isor.get"tas<"report(tas<"*a(e& fro( d/a"ad-isor"tas<s ,here tas<"id B ( select (aN(t.tas<"id& fro( d/a"ad-isor"tas<s t+ d/a"ad-isor"log l ,here t.tas<"id B l.tas<"id a*d t.ad-isor"*a(e B LA ML a*d l.stat.s B LC2MG9F%F L&1
$et lo*g 100000
#.39
$89 deltas $eg(e*t deltas $tats+ (aN+ (i*+ a-g %re*di*g A$H Waits
!A"H#$%"$FA"$%A%
!A"H#$%"$J$MF%R#C"$DMMARJ
!A"H#$%"AC%#IF"$F$$"H#$%2RJ
!A"H#$%"$J$%FM"FIF>%
#.40
!A"H#$%"$>AG$H2%
#HL; "esc !A"H#$%"$>AG$H2% Na$e Ty*e ------------------- ----------------------#NAP493 NU-BER 3B93 NU-BER 9N#TANCE4NU-BER NU-BER #TARTUP4T9-E T9-E#TA-P8'A BEG9N49NTER5AL4T9-E T9-E#TA-P8'A EN349NTER5AL4T9-E T9-E#TA-P8'A /LU#74ELAP#E3 9NTER5AL 3A,8+A TO #ECON381A #NAP4LE5EL NU-BER ERROR4COUNT NU-BER
#.41
!A"H#$%"$89$%A%
$>AG"# !# #>$%A>CF">DM!FR $89"# G9A>"HA$H"IA9DF 2G%#M#PFR"C2$% 2G%#M#PFR"M2 F 2G%#M#PFR"F>I"HA$H"IA9DF $HARA!9F"MFM 92A F "IFR$#2>$ IFR$#2>"C2D>% M2 D9F AC%#2> $89"GR2=#9F =2RCF"MA%CH#>A"$#A>A%DRF GAR$#>A"$CHFMA"# GAR$#>A"$CHFMA">AMF !#> " A%A =F%CHF$" F9%A F> "2="=F%CH"C2D>%" F9%A $2R%$" F9%A FKFCD%#2>$" F9%A GK"$FRIFR$"FKFC$" F9%A 92A $" F9%A #>IA9# A%#2>$" F9%A GAR$F"CA99$" F9%A #$K"RFA $" F9%A !D==FR"AF%$" F9%A R2W$"GR2CF$$F " F9%A 1P3_ I+._D." A ."APS.D_ I+._D." A #2WA#%" F9%A C9WA#%" F9%A AGWA#%" F9%A CCWA#%" F9%A #RFC%"WR#%F$" F9%A G9$FKFC"%#MF" F9%A UAIFKFC"%#MF" F9%A #.42
!A"H#$%"$FA"$%A%
$89S desc !A"H#$%"$FA"$%A% >a(e $>AG"# !# #>$%A>CF">DM!FR %$V 2!UV A%A2!UV 92A#CA9"RFA $"%2%A9 92A#CA9"RFA $" F9%A !D==FR"!D$J"WA#%$"%2%A9 !D==FR"!D$J"WA#%$" F9%A !"!92CK"CHA>AF$"%2%A9 !"!92CK"CHA>AF$" F9%A GHJ$#CA9"RFA $"%2%A9 GHJ$#CA9"RFA $" F9%A
#.43
!A"H#$%"$J$%FM"FIF>%
#HL; "esc 3BA479#T4#,#TE-4E5ENT Na$e Ty*e ---------------------------------#NAP493 NU-BER 3B93 NU-BER 9N#TANCE4NU-BER NU-BER E5ENT493 NU-BER E5ENT4NA-E 5ARC7AR>8DEA WA9T4CLA##493 NU-BER WA9T4CLA## 5ARC7AR>8DEA TOTAL4WA9T# NU-BER TOTAL4T9-EOUT# NU-BER T9-E4WA9TE34-9CRO NU-BER
#.44
#.45
A$H RG%
T:4rd/(s4ad(i*4ashrpt etailed report o* top $89+ $essio*s+ 2/0ects etc R.* o-er $89R>et ,ith
select o.tp.t fro( ta/le(d/(s",or<load"repository.ash"report"teNt( (select d/id fro( -6data/ase&+ 1+ sysdate H 242'+ sysdate H 142'+ 0&& 1
Also A$H"RFG2R%"H%M9
#.46
A$H RG%
1& 1&Ae*eral Ae*erali*fo i*fo 2& 2&%op %opDser DserF-e*ts F-e*tsRRR RRR 3& 3&%op %op!ac<gro.*d !ac<gro.*dF-e*ts F-e*ts '& '&%op %opF-e*t F-e*tG14G24G3 G14G24G3Ial.es Ial.es )& )&%op %op$er-ice4Mod.le $er-ice4Mod.le 6& 6&%op %opClie*t Clie*t## ss 7& 7&%op %op$89 $89Co((a*d Co((a*d%ypes %ypes ?& ?&%op %op$89 $89$tate(e*ts $tate(e*tsRRR RRR 5& 5&%op %op$89 $89.si*g .si*gliterals literals 10& 10&%op %op$essio*s $essio*sRRR RRR 11& 11&%op %op!loc<i*g !loc<i*g$essio*s $essio*s 12& 12&%op %op$essio*s $essio*sr.**i*g r.**i*gG8s G8s 13& 13&%op %op ! !2/0ects 2/0ects 1'& 1'&%op %op ! !=iles =iles 1)& 1)&%op %op9atches 9atches 16& 16&Acti-ity Acti-ity2-er 2-er%i(e %i(eRRR RRR
#.47
#.48
%i(e Model
>e, co*cept W ! %i(e %otal ti(e for all data/ase calls W cp. ti(e $89 W ,ait ti(e Metrics $tats $essio*s
#.49
%i(e Model
Wait
e-ery ) seco*ds
Flapsed %i(e $89 eNec.tio* Gls7l eNec.tio* (s7l eNec.te s./tracted o.t& Ua-a eNec.tio* Co**ectio* ti(e
Gro/a/ly
the (ost i(porta*t as it poi*ts o.t pro/le(s ,ith too (a*y logo*s4sec
#.50
ota# ime
! CGD %i(e DB -ait ! CGD B DB -ait %otal ata/ase ime %i(e Garse ime %i(e Flapsed %i(e
#.52
$ar( 'arse $ar( ?s$aring 'arse criteria: e#a'se e#a'se( ( time time
#.53
#.54
Wait Classes
Ad(i*istrati-e (35&
Co*fig.ratio* (20&
log file siXe F*7.e.es3 $%+ HW+ #%9 9atch3 redo copy+shared pool
Applicatio* (11&
Co*c.rre*cy (12&
#dle ()6& >et,or< (2)& $yste( #42 (15& $ched.ler (6& Dser #42 (12& 2ther ('?)&
#.55
-6,aitclass(etric
C.rre*t
rates
-6,aitclass(etric"history
Ho.r
#.56
Waits Metrics
-ait v$system_ 1#asses
+"IT_C#"SSD +"IT_C#"SS TOT"#_+"ITS TIME_+"ITED
1umu#ative
!it_cl!ss
1urrent (e#tas
v$ !itcl!ssmetric
BEGIN_TIME END_TIME INTSIZE_CSEC +"IT_C#"SS_ID +"IT_C#"SSD NUM_SESS_+"ITING TIME_+"ITED +"IT_COUNT
"ast Hour
v$ !itcl!ssmetric_"istory
BEGIN_TIME END_TIME INTSIZE_CSEC +"IT_C#"SS_ID +"IT_C#"SSD NUM_SESS_+"ITING TIME_+"ITED +"IT_COUNT
"ast 9 (ays
d%!_"ist_ !itcl!ssmetric_"istory
2*ly gets pop.lated ,ith alerts
$"IT_C#"SS_ID
v$eve#t_#!me
E!ENTD E!ENT_ID N"ME "R"METER1 "R"METERE "R"METERF +"IT_C#"SS_ID +"IT_C#"SSD +"IT_C#"SS
-ait .vents
v$system_eve#t
E!ENT TOT"#_+"ITS TOT"#_TIMEOUTS TIME_+"ITED "!ER"GE_+"IT TIME_+"ITED_MICRO E!ENT_ID
v$eve#tmetric
BEGIN_TIME END_TIME INTSIZE_CSEC E!ENT_ID NUM_SESS_+"ITING TIME_+"ITED +"IT_COUNT
d%!_"ist_system_eve#t (C.(.lati-e&
>o i* (e(ory history
#.57
+isce##aneous
I6s7lstats =ield *a(i*g co*-e*tio*s Wait #(pro-e(e*ts
Wait
histogra(s Waits i* -6sessio* a*d -6s7l Waits sho, the /loc<er Wait history of last 10 ,aits
$er-ices Clie*t #d
#.58
v$s<#stats
More efficie*t tha* -6s7l or -6s7larea Dses less CGD =aster $<ips (a*y of the latch gets that -6s7l does Dses M.teNes i*stead of so(e latches
#.59
$89
$89"# *e, hash HA$H"IA9DF still there
#ds
F-e*tV $tatisticV WaitclassV
>a(e Hash
F-e*t"id $tatistic"id Waitclass"id
#.60
Wait Histogra(s
I6e-e*t"histogra( 1(s to 1 ho.r /.c<ets 23 /.c<ets Q 1 (s+ Q 2 (s+ Q ' (s+ Q ? (s+ ...+ Q 2Y22 (s
#.61
Waits i* -6sessio*
!<sessi'n eC0'ses all t?e 4iel(s 4r'5 v<sessi'n_.ait
SEQ# EVENT# EVENT P1TEXT P1 P1RAW P2TEXT P2 P2RAW P3TEXT P3 P3RAW WAIT_CLASS_ID WAIT_CLASS# WAIT_CLASS WAIT_TIME SECONDS_IN_WAIT STATE NUMBER NUMBER VARCHAR2(64) VARCHAR2(64) NUMBER RAW(4) VARCHAR2(64) NUMBER RAW(4) VARCHAR2(64) NUMBER RAW(4) NUMBER NUMBER VARCHAR2(64) NUMBER NUMBER VARCHAR2(19)
#.62
Waits i* I6$89
$89"=D99%FK% $89"# =F%CHF$ F> "2="=F%CH"C2D>% #RFC%"WR#%F$ 1,N1322.N16_-AI _ I+. APP"I1A I,N_-AI _ I+. 1"3S .2_-AI _ I+. 3S.2_I,_-AI _ I+. G9$89"FKFC"%#MF UAIA"FKFC"%#MF CGD"%#MF F9AG$F "%#MF
#.63
#.64
Services
Services is a ne. .a% t' 5easure res'urce usa;e an( statisticsG " sessi'n is ass'ciate( .it? a services .?en t?e sessi'n c'nnects t' t?e (ata6ase via t?e listenerG !M$"$FRI#CF.CRFA%F"$FRI#CF
#.65
$er-ice ZAZ has 1 i*sta*ce(s&. #*sta*ce Z-10gZ+ stat.s RFA J+ has 1 ha*dler(s& for this ser-ice... Ha*dler(s&3 Z F #CA%F Z esta/lished30 ref.sed30 state3ready
Copyright 2006 Kyle Hailey
ls*rctl ser-ices
#.66
Services in ,.+
#.67
1#ient I(
$etti*g Clie*t # d3#s_sess%.!.se"_%de!"%4%e$5c1%e!"_%d) F*a/li*g trace for a clie*t # d3#s_#.!%".$.c1%e!"_%d_"$&ce_e!&31e 5c1%e!"_%d, TRUE, 6ALSE) F*a/li*g statistics aggregatio* /y clie*t id d3#s_#.!%".$.c1%e!"_%d_s"&"_e!&31e5c1%e!"_%d) $cript to FNtract Clie*t %race T$csess ./"(/"=0!&#e> c1%e!"_%d=0!&#e> 2
Copyright 2006 Kyle Hailey
#.68
Session De(icate(
$cott Uoh* $.e Mi<e Ra*dy %i( Mary
2racle $essio*s
$1
$2
$3
2racle
$'
$'
$)
$6
ata/ase Host
#.69
$1
$2
$3
2racle
$'
$'
$)
$6
ata/ase Host
#.70
$1
$2
$3
2racle
$'
$'
$)
$6
$7
ata/ase Host
#.71
Session Poo#ing
$cott Uoh* $.e Mi<e Ra*dy %i( Mary
2racle $essio*s
$1
$2
$3
2racle
$'
$'
$)
$6
$7
ata/ase Host
#.72
!"=#9F"MD9%#"!92CK"RFA "C2D>%
A.to t.*ed i* 10gR2 Reco((e*ded to lea-e .*set i* i*it.ora+ eN+ ,he* .*set o* (y GC
Whe* r.**i*g
/(s"stats.gather"syste("stats(gatheri*g"(ode BS Mi*ter-al@ i*ter-al BS 30 & d/"file"(.lti/loc<"read"co.*t is ig*ored
#.73
#.74
#.75
81
A* A$H report ca* /e r.* o* data co-eri*g ,hat ti(e periods (/y defa.lt& a. a*y 60 seco*ds i* the past ,ee< /. a*y ho.r period i* the past day c. a*y day i* the past ,ee< d. a*y 60 seco*d period i* the past ho.r a*s,ers all the a/o-e
#.76
82
AWR ( a.to(atic ,or<load repository & reports o* data co-eri*g ,hat ti(e periods (/y defa.lt& a. a*y 60 seco*ds i* the past ,ee< /. a*y ho.r period i* the past day c. a*y day i* the past ,ee< d. a*y 60 seco*d period i* the past ho.r a*s,ers / a*d c C AWR o*ly ta<es data e-ery ho.r for a ,ee< /y defa.lt
Copyright 2006 Kyle Hailey
#.77
83
Co**ecti*g to 2racle is a CGD i*te*si-e operatio*. A high logo* rate (ay i*dicate a* applicatio* desig* iss.e that .**ecessarily /.r*s CGD. What perfor(a*ce ta/le(s& i*dicates the ti(e spe*t co**ecti*g to the data/ase : / C o*ly a. -6acti-e"sessio*"history others /. -6sys"ti(e"(odel a+c+d C do*Lt report c. -6,aitclass(etric co**ectio* ti(e or co**ect CGD .sage d. -6sysstat
Copyright 2006 Kyle Hailey
#.78
8'
What is the least reso.rce co*s.(i*g -ie, for getti*g the *.(/er of eNec.tio*s of a* s7l state(e*t a. -6s7llite /. -6s7lstats c. -6s7l d. -6s7larea / C *e, i* 10g+ less latch .sage tha* the other ta/les others a does*Lt eNit c readi*g .ses (a*y of the latches as .sers eNec.ti*g s7l d the ,orst+ li<e -6s7l+ /.t also does a* eNpe*si-e gro.p /y Copyright 2006 Kyle Hailey
#.79
8)
Ho, ca* yo. i((ediately fi*d the top CGD co*s.(i*g sessio* i* the past 1) seco*ds a. -6sess(etric a*s,er /. -6acti-e"sessio*"history a+ / c. -6sesstat others3 d. -6top"sessio*s c C o*ly has c.(.lati-e data+ *eed to ta<e deltas of -al.es to see ,hat is happe*i*g d C does*Lt eNist
Copyright 2006 Kyle Hailey
#.80
86
What script r.*s 16 differe*t 7.eries agai*st -6acti-e"sessio*"history to prod.ce a detailed report o-er a*y ti(e i*ter-al i* the AWR repository a*s,er a. :4rd/(s4ad(i*4spreport.s7l c /. :4rd/(s4ad(i*4a,rrpt.s7l other c. :4rd/(s4ad(i*4ashrpt.s7l a a*d / do*Lt .se A$H d. :4rd/(s4ad(i*4ashreport.s7l d does*Lt eNit
#.81
87
#* 10g+ it is reco((e*ded to set d/"file"(.lti/loc<"read"co.*t to a. .*set /. ? c. 16 d. 32 e. 12? a*s,er a. 2racle ,ill set it a.to(atically to the opti(al -al.e (this ,o*Lt affect $89 opti(iXatio* as 2racle ,ill calc.late s7l opti(iXatio* ,ith "d/"file"opti(iXer"read"co.*t
Copyright 2006 Kyle Hailey
&
#.82
8?
2racle ca* trac< differe*t applicatio*s .si*g the Zser-icesL ide*tifier. After the ser-ice ide*tifier gets created a*d started+ ho, does the ser-ices ide*tifier get set for a co**ectio*. a. call to d/(s"ser-ices /. -ia the t*s*a(es.ora co**ectio* c. i* the i*it.ora d. -ia a (iddle tier co((a*d a*s,er /
#.83
85
%he ide*tifier Zclie*t"idZ allo,s a !A to (o*itor ,hat special sit.atio*3 a. trac< differe*t applicatio*s reso.rce .sage o* a data/ase /. trac< applicatio* .sers i* sessio* pools c. trac< dedicated sessio*s d. is the sa(e as the data/ase Z.ser*a(eZ a*s,er / C set .p specifically to trac< applicatio* .sers that co**ect ,itho.t a dedicated co**ectio* -i a sessio* pool
Copyright 2006 Kyle Hailey
#.84