Copyright©2006,Oracle.Allrightsreserved.Introduction1-2Copyright©2006,Oracle.Allrightsreserved.ObjectivesAftercompletingthislesson,youshouldbeableto:•Describecourseobjectives•Describebackupmethods•Describetheformsofdatarecovery•DescribeOracleRecoveryManagerarchitecture•Planarecoverystrategy•Planabackupstrategybasedonyourrecoverystrategy1-3Copyright©2006,Oracle.Allrightsreserved.CourseObjectivesAftercompletingthiscourse,youshouldbeableto:•UseOracleRecoveryManager(RMAN)toperformbackupandrecoveryoperations•Createaduplicatedatabase•Performtablespacepoint-in-timerecovery•CreateandmanageanRMANrecoverycatalog•UseOracleSecureBackuptobackupandrestoreOracledatabasesandfile-systemdatatoandfromtape1-4Copyright©2006,Oracle.Allrightsreserved.WhatIsBackupandRecovery?Backupandrecoveryconstitutesthestrategiesandproceduresyouemployto:•Protectyourdatabaseagainstdataloss•Reconstructyourdatabasefollowingdataloss1-5Copyright©2006,Oracle.Allrightsreserved.PerformingBackupandRecoveryOperationsforanOracleDatabaseForperformingbackupandrecoverybasedonphysicalbackups,thefollowingsolutionsareavailable:•RecoveryManager:Autilitywithacommand-lineclientandanEnterpriseManagerGUIinterface•User-managedbackupandrecovery:AtechniquethatinvolvesusingoperatingsystemcommandstocreatebackupsandusingSQL*Pluscommandsforadditionalbackupandrecoveryoperations1-6Copyright©2006,Oracle.Allrightsreserved.UsingOracleRecoveryManager•RMAN:–Isacommand-lineclientforadvancedfunctions–Haspowerfulcontrolandscriptinglanguage–HasapublishedAPIthatenablesinterfacewithmostpopularbackupsoftware–Backsupdata,control,archivedlog,andserverparameterfiles–Backsupfilestodiskortape•EnterpriseManagerusesRecoveryManager(RMAN)toperformbackupandrecoveryoperations.1-7Copyright©2006,Oracle.Allrightsreserved.RecoveryManagerComponentsServersessionChannelServersessionEnterpriseManagerTargetdatabase(controlfilerepository)RecoverycatalogdatabaseAuxiliarydatabaseDiskFlashRecoveryAreaChannelChannelMMLOptionsRecoveryManager(RMAN)1-9Copyright©2006,Oracle.Allrightsreserved.UsingOracleSecureBackup•OnetooltobackupandrestoreOracledatabasesandfile-systemdatatoandfromtape•IntegratedwithRMANandEnterpriseManager•SupportsOracle9iandOracleDatabase10g1-10Copyright©2006,Oracle.Allrightsreserved.OverviewofOracleBackupMethods•Backupstrategies:–Whole:Abackupofthecontrolfileandalldatafilesthatbelongtoadatabase–Partial:Aportionofthedatabase•Backuptypes:–Full:Anon-incrementalRMANbackup–Incremental:Onlyinformationthathaschangedsincesomepreviousbackup•Backupsmodes:–Offline:Consistent,alsoreferredtoascoldbackup–Online:Inconsistent,alsoreferredtoashotbackup1-12Copyright©2006,Oracle.Allrightsreserved.WhenDoYouNeedtoUseaBackupforRecovery?Theuseofabackuptoperformrecoveryisoftenrequiredforthefollowingtypesoferrors:•Mediafailure:Thefailureofareadorwriteofadatabasefileduetoaphysicalproblemwiththefile•Usererrors:Datainyourdatabaseischangedordeletedincorrectly1-13Copyright©2006,Oracle.Allrightsreserved.RespondingtoUserErrorPossibleresponsestousererrorinclude:•Reenteringthelostdatamanually,ifarecordofthechangesexists•Importingthedroppedobject,ifasuitableexportfileexistsortheobjectisstillavailableonastandbydatabase•Performingtablespacepoint-in-timerecovery(TSPITR)ofoneormoretablespaces•Returningthedatabasetoapaststateusingdatabasepoint-in-timerecovery•UsingoneoftheOracleFlashbackfeaturestorecoverfromlogicalcorruptionbyreturningaffectedobjectstoapaststate1-14Copyright©2006,Oracle.Allrightsreserved.OverviewofDataRecovery•Crashrecovery:Automaticrecoveryafterinstancefailure•Mediarecovery:Recoveryofcurrentdatafiles,controlfiles–Completerecovery:Recoveryofthedatabasetothemostrecentpointintime–Incompleterecovery(point-in-timerecovery):Recoveryofthedatabasetoitsstateataspecifictimeorsystemchangenumber(SCN)1-15Copyright©2006,Oracle.Allrightsreserved.OracleDatabaseArchitecture:CrashRecovery•Theonlineredologfilesareusedtorollthedatabaseforward.•Uncommittedchangesarerolledback.DatabaseattimeofinstancefailureDatabasewithcommittedanduncommittedtransactionsOnlineredologfilesUndoblocksDatabasewithcommittedtransactionsonly1-16Copyright©2006,Oracle.Allrightsreserved.OracleDatabaseArchitecture:RecoveryAfterMediaFailure•Datafilesarerestoredfromabackup.•Archivedandonlineredologfilesareusedtorollthedatabaseforward.DatabasewithrestoreddatafilesDatabasewithcommittedanduncommittedtransactionsOnlineandarchivedredologfilesUndoblocksRecovereddatabase1-17Copyright©2006,Oracle.Allrightsreserved.DevelopingaBackupandRecoveryStrategyforYourOracleDatabase•Assessservice-levelcriteria,including:–Dataavailabilityrequirements–Datacriticality–Recoverypointandtimeobjectives•Anticipatetheerrorsthatwillariseinyourenvironmentandputinplacethebackupproceduresneededtorecoverfromthoseerrors.1-18Copyright©2006,Oracle.Allrightsreserved.OracleSolutionsforHighAvailabilityInadditiontobackupandrecoverystrategiesandprocedures,considerthefollowingOraclesolutions:•OracleDataGuard:Providesacomprehensivesetofservicesthatcreate,maintain,manage,andmonitoroneormorestandbydatabases•Oracl