Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 3

Chng 1 Kin trc ca oracle bao gm : Kin trc b nh, Kin trc vt l, kin trc client !

erver"

Overview of Primary Components


'ser process Shared Pool Li!rary Cache Server process PGA ata ictionary Cache

Instance SGA
ata!ase Buffer Cache (ava Pool Redo Log Buffer Large Pool

P#O$ S#O$

B"R LG"R

C%P&

Others

Parameter file Password file

atafiles

Control files

Redo Log files

Archived Log files

ata!ase

1-3

Copyright Oracle Corporation, 2001. All rights reserved.

1" #racle !erver : l$ %&' gm in!tance v$ () a" #racle in!tance : *i+, khi-n t.c * ca oracle i" /0c *i-m : l$ th- hi1n ca 1 (), 1 in!tance th,c 1 (), 1 () c2 nhi+, in!tance" ii" C3, trc : c3, trc b nh 4 backgro,n5 6roce!! 7*8i h9i c: ;< 1" C3, trc b nh : ; lo=i a" >?@ : b nh 5Ang ch,ng cho to$n b h1 th.ng" KBch thc >?@ c2 ththaC *Di *ng" Ea c2 th- thaC *Di kBch thc ca tFng th$nh 6hGn" Hhg ko *c vIot J,K SGA_MAX_SIZE 7gii h=n kBch thc ca >?@<" >?@ *c c3, t=o tF cKc kh.i b nh *+, nha, gLi l$ granuel.(ti thiu l 3) " KBch thc ca gran,el tAC th,c v$o SGA_MAX_SIZE. H, SGA_MAX_SIZE<256 MB => granuel = 4KB, nu SGA_MAX_SIZE > 256 th = !6KB. CKc th$nh 6hGn : i" >hare5 6ool 1" 'ibrarC cache : l, l=i cKc cM, l1nh N'>&' *c !O 5Png gGn *MC nh3t7hQ, h=n<, cache t3t c: 7teRt, 6ath"""< ;" (ictionarC cache : cache cKc *Snh nghTa ca cKc *.i tUng trong () !O 5Png gGn *MC nh3t7thVm R2a !Oa< W" KBch thc ca !hare5 6ool l$ : Shared_pool_size , ko chX *Snh rY kBch thc ca ; th$nh 6hGn m$ tI 6hMn chia" Z" '1nh : Show parameter shared_pool_size ; alter system set shared_pool_size=64M ;

ii" (ata b,[[er cache : cache 5ata block tF 5ata [ile lVn \@] ^_ l1nh ,65ate *c t`ng cang" >O 5Png th,t t2an '\b *- lo=i b9 cKc 5ata block Bt 5Ang nh3t" C c3, ho=t *ng : khi ngai 5Ang thIc hi1n 1 cM, tr,C v3n, oracle !c tdm trong 5ata b,[[er cache c2 5ata liVn J,an haC ko, n, c2 thd tr: v+" H, ko c2, !c R,.ng 5ata [ile tdm kim 5ata cGn thit7theng J,a >?@< v$ *em lVn \@]" KBch thc : 1. DB_cache_size ;" DB_keep_cache_size: ko 5Ang th,t toKn '\b" 3. DB_rec cle_cache_size iii" \e5o log b,[[er 7ko 5Ang '\b< 1" ghi nhn mLi !I thaC *Di ca 5b ;" mPc *Bch chBnh l$ recoverC W" CKc thaC *Di *c l, trVn re5o log gLi l$ re5o entrC Z" kBch thc : !"#_B$%%&' f" Khi re5o log b,[[er *GC n2 !c l, 5ata R,.ng re5o log [ile iv" #ther !tr,ct,re v" 'arge 6ool7ko bgt b,c<: l$ th$nh 6hGn b nh tAC chLn" /c !O 5Png khi 5c 5Ang theo c cht client !erver theo m,lti threa5, khi back,6 v$ recoverC theo th,t t2an \]@H, khi !erver c2 nhi+, mKC tBnh thIc thi theo c cht 6arallel" KBch thc : !('#&_)""!_S*+& vi" hava 6ool7ko bgt b,c< : l6 trdnh vi hava thd t`ng theng !. n$C : ,(-(_)""!_S*+& b" N?@ : b nh R,3t hi1n khi c2 kt n.i R:C ra, 5Ang cho tFng !erver 6roce!!" ) nh n$C m3t *i khi m3t kt n.i" Hhg >?@ ko m3t" NhPc th,c v$o !erver 6roce!!, 1 !erver 6roce!! c2 1 N?@" CKc N?@ *c l6 vi nha," N?@ *c c36 6hKt khi c2 1 !erver 6roce!! v$ bS th, hi khi !erver 6roce!! n$C kt thc75e5icache !erver<" ;" )ackgro,n5 6roce!! : cGn * f th$nh 6hGn chBnh a" () iriter : ghi nhn 5ata 5irtC tF 5ata b,[[er cache R,.ng 5ata [ile, khi : i" (ata b,[[er cache *GC" ii" Khi 5ro6 table iii" Khi 5ata !6ace o[[line iv" Khi check 6oint R:C ra" b" 'og iriter : ghi 5ata tF re5o log b,[[er R,.ng re5o log [ile, khi : i" Kt thc 1 Eran bjg commit" ii" 1kW re5o log b,[[er *c !O 5Png" iii" Khi tn t=i 1 ]) 5ata trong re5o log b,[[er" iv" Erc !I ki1n () iriter ghi 5ata tF (ata b,[[er cache R,.ng 5ata [ile" c" >]#H : l$ !C!tem monitor 5Ang *- J,an !Kt cKc v3n *+ liVn J,an *n h1 th.ng" lB 5P : !erver bS c6 *i1n *t ngt" >]#H !c a66lC nhQg vi1c *m commit tF re5o log [ile R,2ng 5ata [ile v$ rollback nhQg Eran cha commit" 5" N]#H : l$ 6roce!! monitor" &,an !Kt cKc giao thnc client !erver" lB 5I : khi ; mKC @ v$ ) cAng tr,C v3n gi.ng nha, lVn !erver, gi: !O @ kt ni trc v$ vAng 5ata @ CV, cG, *m bS kh2a nVn ) 6h:i cha" Hhg khi @ cha commit thd @ bS nggt kVt n.i *t ngt" Khi *2, N]#H !c gi:i 6h2ng cKc b nh liVn J,an *n !e!!ion, ,nlock cKc t$i ng,CVn @ *ang giQ"

e" Check6oint l$ thai *i-m cKc 5ata trVn \@] ghi nhn ht R,.ng 5ata [ile" H2 c6 nht t3t c: cKc hea5er [ile v+ cAng 1 giK trS" C6 nht v$o control [ile giK trS thai gian vFa check6oint 75Ang *- recoverC !a, n$C< [" @rchive 7@\Cn< : 5Ang *- ghi re5o log [ile ra th$nh 1 b:n mi trnoc khi ghi *o lVn n27khi bS *GC b nh< iii" CKch thit l6 1 !e!!ion : khi kt n.i vi !erver, 6hBa client !inh ra ,!er 6roce!!, 6hBa !erver !inh ra !erver 6roce!!" >e!!ion l$ !I kt n.i tF client *n !erver haC l$ c,c n.i ch,C1n giQa ,!er 6roce!! v$ !erver 6roce!!" C2 W tr=ng thKi : active, inactive, kill" b" #racle () : njm trVn %/% 71 [ile oracle c2 th- njm trVn nhi+, %/%< gm W ki-, [ile bgt b,c v$ W ki-, [ile mp rng i" (ata [ile : l, trQ 5ata thIc t ca 5b" ii" Control [ile : 5Ang *- *i+, khi-n v$ ghi nhn tr=ng thKi oracle" iii" \e5o log [ile : ghi nhn mLi !I, thaC *Di ca 5b nVn c2 chnc n`ng 6hPc hi 5b" iv" Narameter [ile : v" Na!!ior5 [ile vi" @rchive log [ile ;" C3, trc logic

Logical Structure
ictates how the physical space of a data!ase is used )ierarchy consisting of ta!lespaces* segments* e+tents* and !loc,s &a!lespace
atafile Segment Segment

-+tent

Bloc,s

1-39

Copyright Oracle Corporation, 2001. All rights reserved.

a" Ehn tI 6hGn c36 : block _eRtent _!egment _table !6ace" b" ]0c *Snh : 1 block qK), 1 eRtent q )lockm 1 !egment 1 eRtent" c" 1 block ko njm trong ; eRtent khKc nha,, 1 eRtent ko njm trong ; table !6ace khKc nha,, 1 table !6ace c2 1 ho0c nhi+, 5ata [ile" 5" l+ m0 logical 1 b:ng l$ 1 !egment" e" 1 5ata [ile chna nhi+, eRtent nhg chX th,c 1 5ata [ile" [" 1 () c2 nhi+, table !6ace"

You might also like