Escolar Documentos
Profissional Documentos
Cultura Documentos
Flashback
Copyright 2008, Oracle. All rights reserved.
Objectives
After completing this lesson, you should be able to: Query the recycle bin Configure Flashback Database erform Flashback Database to a point in time !onitor flashback log statistics "nable and disable the Flashback Database feature #se the "nterprise !anager $ecovery %i&ard to perform Flashback Database #se guaranteed restore points 'ith Flashback Database
6-2
(r,"cate table- )"desired +atabase %,ltitable cha"ges %ade +rop table )pdate /ith the /ro"g WHERE cla,se +rop (able
&lashbac' logs(.)#
(able
.ecycle bi" )"do data )"do data )"do data )"do data
Co%pare c,rre"t data /ith 0,ery data *ro% the past Co%pare versio"s o* a ro/ 1ersio" ($ 2"vestigate several historical states o* data (ra"sactio"
6-3
6-3
$ecycle (in
BIN$zbj B'p#==$$ BIN$zbj !"#y==$$ (SER&OB)ECTS / DBA&FREE&SPACE E%PLOYEES , E%PLOYEES&PK Objects are: 5 $enamed 5 0ot moved BIN$zbj !"#y==$$ BIN$zbj B'p#==$$ E%PLOYEES E%PLOYEES&PK
$ecycle bin
6-4
6-6
6-9
DBA&FREE&SPACE 0 RECYCLEBIN
Autoe8tend ,
6-8
6-:
6 - <0
DROP TABLE *+!ble&,!me- .P(R1E/ ; DROP TABLESPACE *+s&,!me.INCL(DIN1 CONTENTS/ ; DROP (SER *8se &,!me- .CASCADE/ ;
6 - <<
SELECT o#,e 9 o 5:5,!l&,!me9 obje;+&,!me9 +ype9 +s&,!me9 ' op+5me9 el!+e'9 sp!;e FRO% 'b!& e;y;leb5, <HERE ;!,&8,' op = =YES=; SELECT o 5:5,!l&,!me9 obje;+&,!me9 +ype9 +s&,!me9 ' op+5me9 el!+e'9 sp!;e FRO% 8se & e;y;leb5, <HERE ;!,&8,' op = =YES=; S>L- SHO< RECYCLEBIN
6 - <2
NO YES YES NO
D$O "D
E%PLOYEES E%PLOYEES&PK
$ecycle bin
(SER&INDE4ES
+he Flashback Database operation: %orks like a re'ind button for the database Can be used in cases of logical data corruptions made by users
6 - <3
(uffer cache
5*%$
Flashback logs
$?%$
$edo logs
. @
6 - <4
S>L- SH(TDO<N I%%EDIATE; S>L- START(P %O(NT E4CL(SIAE; S>L- ALTER SYSTE% SET B DB&FLASHBACK&RETENTION&TAR1ET=BCC$ SCOPE=BOTH; S>L- ALTER DATABASE FLASHBACK ON; S>L- ALTER DATABASE OPEN;
6 - <6 Copyright 2008, Oracle. All rights reserved.
6 - <9
6 - <8
6 - 20
6 - 2<
6 - 22
+he opposite of ;flash back< is ;recover)< =ou cannot use Flashback Database in the follo'ing situations:
5 +he control file has been restored or re3created) 5 A tablespace has been dropped) 5 A data file has been shrunk)
6 - 23
#se the TO BEFORE RESETLO1S to flash back to before the last RESETLO1S operation)
Copyright 2008, Oracle. All rights reserved.
6 - 23
+o monitor the ability to meet your retention target: ?ie' the flash recovery area disk 2uota:
S>L- SELECT es+5m!+e'&Nl!sOb!;P&s5ze9 B Nl!sOb!;P&s5ze K FRO% A$FLASHBACK&DATABASE&LO1;
6 - 26
6 - 29
A guaranteed restore point ensures that you can perform a FLASHBACK DATABASE command to that 7C0 at any time)
6 - 28
7ummary
1n this lesson, you should have learned ho' to: Query the recycle bin Configure Flashback Database erform Flashback Database to a point in time using "nterprise !anager or $!A0 !onitor flashback log statistics "nable and disable the Flashback Database feature #se guaranteed restore points 'ith Flashback Database
6 - 2:
6 - 30