Anda di halaman 1dari 98

1

2
3
4
5
6
7
8
9
10
Oracleinstance: AnOracleinstanceisasetofsharedmemory,calledthesystem
globalarea(SGA),andprocessesthatprovideaccesstothedatabase.
Oracledatabasefiles:ThedatabaseisthephysicaldatabasefilesonDisk.The
databasefilesstoretheinformationthatiscontainedbythedatabase,aswellas
databasemetadataandconfigurationsettings,anddatabaselogs,whichprovide
forrollback,recovery,andperformance.

11
Everydatabasehasoneormorephysicaldatafiles.Thedatafilescontaina
physicalcopyoftheuserdataandthedatadictionary,whichisthedescriptionof
thestructureoftheuserdata.
Withinthedatabase,userdataisorganizedlogicallyintotablespaces.Atablespace
isacollectionofoneormoredatafiles.Adatafilecanonlycontaindatafora
singletablespace.
Adatafileisstructuredintodatablocks,whicharethesmallestunitsofspace
withinanOracledatabase.
Allreadandwriteactionsperformedonadatabaseareattheblocklevel.
extentisacontiguoussetofdatablocksobtainedinasingleallocation
segmentisacollectionofallextentsforaspecificstructure.Therearedifferent
typesof
segments,includingdatasegments,indexsegments,androllbacksegments.

12
Everydatabasehastwoormoreredologfiles.Thecompletesetofredologfiles
foradatabaseiscollectivelyknownasthedatabasesredolog.Theprimary
functionoftheredologistorecordallchangesmadetothedatabase.Ifafailure
preventsmodifieddatafrombeingwrittenpermanentlytoadatafile,changesare
stillavailablefromtheredolog.Therefore,thereislesslikelihoodofdataloss.
Redologsareusedduringrecoveryoperations.Theprocessofapplyingtheredo
logduringarecoveryoperationiscalledrollingforward.
OracleautomaticallygeneratesOnlineRedoLogs. Youcan'thaveanOracle
instancewithoutonlineredologs.
RedologfilesarearchivedonlywhenthedatabaseisconfiguredinARCHIVELOG
modeandcontainredoentriesandarecopiedtooneormorearchivedestinations
beforereuse.

13
OracleBasics AdditionalFilesfordataprotection
Controlfiles
Parameterfiles
Passwordfile
Theparameterfileisoftenreferredtoastheinit.ora file.BeginningwithOracle9i,
therearetwotypesofparameterfiles:APFILE(ParameterFILE),thetraditional
typeofparameterfile,isanordinarytextfilethatcanbedirectlymodifiedwitha
texteditor.AnSPFILE(ServerParameterFILE)isabinaryfileinitiallybuiltfroma
PFILEusingtheCREATESPFILEstatement.
Apasswordfileisoptionalforadatabaseexceptincaseswhereremoteusers
connectthroughOracleNetwithadministrativeprivileges

14
Nomount
Theinstanceisrunning,butnofilesareopened.Usethestartupnomount command
whenfirstcreatingthedatabaseorrestoringthecontrolfile.
Mount
Theinstanceisrunningandthecontrolfileisopened.Nootherfilesareopen.Use
thestartupmountcommandforDBAoperations,suchasrecoveryorchanging
betweenARCHIVELOGmodeandNOARCHIVELOGmode.
Open
Theinstanceisrunning,thecontrolfileisopened,andallotherfilesareopened.Use
thestartupopencommandfornormalstartupofadatabase.Thedefaultparameter
forthestartupcommandisopen

15
Offline=closed.

16
17
CrosscheckingtheinformationintheRMANrepository:
Useoneofthefollowingcommandstocheckthespecifiedfiles.Youneedtorun
separatecommandstodeleteimagesorrepositoryrecords.
ThecrosscheckcommandqueriesMediaManagertodetermineifabackuppieceis
available.Ifnot,RMANmarksthebackuppieceasexpired.Ifitwasexpiredbutis
nowavailable,RMANmarksthebackuppieceasavailable.

CrosscheckingAllBackupsandCopies:Example
Thefollowingexample,whichassumesthatthedefaultconfiguredchannel
is DEVICE TYPE sbt,queriesthestatusofallbackupsandcopiesontapeanddisk.
BecauseRMANpreconfiguresadiskchannel,youdonotneedtomanuallyallocatea
diskchannel:
CROSSCHECKBACKUP;
CROSSCHECKCOPY;

CrosscheckingWithinaRangeofDates:Example
Thefollowingexamplequeriesthemediamanagerforthestatusofthebackupsetsin
agivensixmonthrange.NotethatRMANusesthedateformatspecifiedin
the NLS_DATE_FORMAT parameter,whichis'DDMONYY'inthisexample:

#ifyoumanuallyallocateansbt channel,thenRMANdoesnotcrosscheckdisk
ALLOCATECHANNELFORMAINTENANCEDEVICETYPEsbt;

18
CROSSCHECKBACKUPCOMPLETEDBETWEEN'01JAN01'AND'01SEP01';
RELEASECHANNEL;

#tocrosscheckonlydisk,specifyCROSSCHECKDEVICETYPEDISK
CROSSCHECKBACKUPDEVICETYPEDISKCOMPLETEDBETWEEN'01JAN01'AND
'01SEP01';

#assumingthatthedefaultchannelissbt,youcancrosscheckonbothdisk
#andsbt backupsbysimplyrunningCROSSCHECKwiththedefaultchannels
CROSSCHECKBACKUPCOMPLETEDBETWEEN'01JAN01'AND'01SEP01';

18
19
20
TheOraclearchitecturecomponentsshowninthegraphiconthisslide
>>RMANcanbackupdatatodiskortoastandalonetapedriveunderitsown
control,butitrequirestheassistanceofathirdpartymediamanagertousearobotic
tapelibraryforbackups.NetBackup servesasthismediamanager.Theprimary
functionofamediamanageristotrackallofthetapesusedbyRMANforbackups
andtomanagethemountingandunmounting ofthosetapes.
TheOracleserverprocessallocatedforachannelinvokestheAPItoopenadata
stream.ThecallisthenservicedbyNBUO,whichlocatesandmountsatape.

21
NetBackup integratesthedatabasebackupandrecoverycapabilitiesoftheOracle
RecoveryManager(RMAN)withthebackupandrecoverymanagement
capabilitiesofNetBackup.NetBackup forOraclealsoletsyouexportandimport
OracledatainXMLformatforlongtermarchivalandretrieval.
TheserverthathoststheOracledatabasemustbeaNetBackup client.Themaster
servermustalsohaveNetBackup forOraclelicensed.

22
23
24
Oracledatabasescanbebackedupwithfilesystembasedbackuppolicies,however
Oraclepolicies,withtheNetBackup forOracleagent,arepreferred. Thisismainlydue
totheirabilitytoperformonlinebackupsintegratedwithOraclesRecoveryManager
(RMAN).
>>>InNetBackup 7.5andprior,theNetBackup forOracleagentsupportsbothstream
basedbackupsandproxycopybackups.
>>>Eachmethodhasdifferentbehaviorandschedules,andtheRMANsyntaxis
different.

25
Withstreambasedbackups,RMANistoldtogenerateabackupdatastreamfromthe
correspondingdatabase,whichissenttoNetBackup.
>>>AspecificNetBackup policyandApplicationBackupschedulecanbetargetedby
OraclebyspecifyingenvironmentvariablesreadbyRMAN.TheApplicationSchedule
isusedbyNetBackup togiveRMANtheabilitytocontrolthebackuptiming.>>>Ifno
specificscheduleisspecified,thanNetBackup looksforanyApplicationBackup
schedulewithanopenstartwindow.
>>>AnAutomaticbackupschedulecanoptionallybeusedtoallowNetBackup to
scheduleandrunthescriptsthattellRMANtoinitiatethesebackups,insteadof
havingRMANschedulethebackupsitself.
>>>Withproxycopybackups,RMANgeneratesalistofdatabasefiles,whicharethen
passedtoNetBackup forbackup.>>>Unlikestreambasedbackups,thisbackuptype
requiressometypeofsnapshotmechanism,anddoesnotuseApplicationSchedules.
>>>Instead,anAutomaticscheduleisused,whichisgivenbyanenvironment
variable.>>>Ifthevariableisnotset,thenwhateverAutomaticFullschedulethatis
found,isused.
>>>Notethatproxycopybackupscannotbeusedtobackupcertaintypesof
databaseobjects,suchascontrolfiles,SPfiles,archivelogs,andlevel1differentialor
cumulativeincrementalbackups.NotethatOracle10doesallowproxycopyfor
ArchivedLogbackups,andproxycopycanperformincrementalbackups,butonlyas

26
BlockLevelIncrementalbackupsonUNIX(usingVeritasStorageFoundationfor
Oracle).

26
Oracledatabasescanbebackedupwithfilesystembasedbackuppolicies,however
Oraclepolicies,withtheNetBackup forOracleagent,arepreferred. Thisismainlydue
totheirabilitytoperformonlinebackupsintegratedwithOraclesRecoveryManager
(RMAN).
>>>InNetBackup 7.6andprior,theNetBackup forOracleagentsupportsbothstream
basedbackupsandproxycopybackups.
>>>Eachmethodhasdifferentbehaviorandschedules,andtheRMANsyntaxis
different.

27
>>APPLICATIONscheduleistheequivalentofaUSERscheduleinFilesystembased
policiesand itallowsanRMANDBAtomanuallyrunabackupofanoracledatabase
andsendthebackuptoNetBackup.
>>APPLICATIONschedulecanonlyrunwhenoneofit'sstartwindowsareopen.

28
>>AUTOMATIC schedulesallowNetBackup tocontrolwhenthebackupkicksoff
>>AUTOMATICschedulescanbeusedastargetsifRMANisperformingaPROXY
COPYbackup.

29
>>TheslideshowstheNetBackup activitymonitordetailsforstream basedbackups.
>>IfusingProxycopybackupsthereisno ApplicationBackupschedule.
>>AControlFilebackupneedsanApplication scheduleasitcannotbebackedupvia
aProxyCopybackuptypeandusestheSTREAMmethod.

30
31
32
ScriptsareusedbyNetBackup forOracletoallowtheNetBackup schedulertokickoff
anOraclebackup.WhentheNetBackup schedulerrunsanAutomaticscheduleofan
Oraclepolicyandseesascriptinthepolicysbackupselectionlist,>>>itexecutesthe
scriptpassingthescriptinformationthroughenvironmentvariables,suchasthose
shownontheslide.
>>>Thesescriptscanbewrittenbyhand,butareoftengeneratedfromtemplates,
whicharediscussedonthefollowingslide.
>>>Althoughtemplatescreatescriptsthathandlesimplescenarios,backingup
multipledatabaseswithonescript,andothermorecomplexscenarios,canbe
performed.>>>Notethatthisusuallyrequiresmanualscriptmodifications,andthat
scriptscanbepronetocodingerrors,sotestingshouldbeperformed.
MoreinformationonscriptsforOraclebackupscanbefoundintheNetBackup 7.6
forOracleAdministrator'sGuide
http://www.symantec.com/docs/DOC6481

33
Templates areusedtogeneratecommandorshellscriptsthatwillinvokeRMANwith
correctsyntaxfortheclientonwhichthescriptisgenerated,foreitherstreambased
orproxycopybasedbackups.Backuptemplatesarestoredonthemasterserverbut
restoretemplatesarestoredontheclient.
>>>TemplatesaregeneratedusingtheBackup,ArchiveandRestore(BAR)Console,by
runningawizardthatleadstheuserthroughtheircreation.Theirpurposeisto
correctlygeneratethescriptrunbyanautomaticscheduletoperformthebackup.
>>>Bpdbsbora canbeusedontheclienttoeithergenerateandrunthescript,or
simplygeneratethescripttobeexamined.
>>>Whengeneratingascriptbasedonatemplate,youhavetheabilitytotiethe
templatetoaspecificpolicy,schedule,masterserverandclient,andtoasingle
database.Ifsuchtemplatesareusedinotherpolicies,thebehaviormaybe
unpredictable,unlessthescriptismanuallymodified.

34
35
36
37
Beforeaninstancecanbeincludedinapolicyforbackup,NetBackup needstoknow
informationabouttheinstance.Thisinformationisstoredinacentralrepositorythat
ispartoftheNBDBdatabase,notaspartofthepolicy.
>>>Thereisanautodiscoveryprocessthatwillautomaticallydiscoverinstancesof
Oracledatabases.NetBackup administratorsalsohavetheabilitytoaddinstancesto
thisrepositoryeitherusingtheNetBackup Administrationconsoleoracommandline
utility.
>>>Thedatabasenotonlyneedstobelistedinthisrepositorybutitalsohastobe
registered.Registrationistheprocessofassigningcredentialstotheinstancesothat
NetBackup isabletologintothedatabaseandbackitup.Thiscredentialinformation
canincludetheoperatingsystemlogincredentialsofthehostwheretheinstance
resides,theOraclelogincredentials,andifaRecoveryCatalogisgoingtobeused,the
identityoftherecoverycataloganditslogincredentials.

Aninstance groupisacollectionof
>>>

instancesthatshareacommonsetof
credentials(os,db,RecoveryCatalog).
>>>InstanceGroupscanbemanuallycreatedtosimplifyregistration

>>>Autodiscoveredinstancescanbe

38
automaticallyassignedtoaninstance
group

38
Instancegroupsareusedtoeasetheinstanceregistrationprocess.Ifyouhave
hundredsofinstancestoregisterbuttheyuseallofthesamecredentials,itcouldbe
alotofworktospecify,foreachoneofthoseinstances,thesamesetofcredentials
overandoverandoveragain.
>>>Tomakethisregistrationprocessmoreconvenient,aninstancegroupcanbe
created.EachinstancegroupcanhaveasetofUnixHostcredentials,WindowsHost
credentials,InstanceLogincredentialsandRecoveryCatalogcredentials.Oncethese
aredefined,allthatisneededtoregisteraninstanceistoassociatethedesired
instancewiththeinstancegroup.UNIXbasedinstanceswillusethegroupsUnixHost
Logincredentials,whileWindowsbasedinstanceswillusethegroupsWindowsHost
credentials.TheInstanceCredentialsandRecoveryCatalogCredentialswillbeused
byallinstanceswithinthegroup.
>>>Registrationcanstillbeatediousoperation,sinceinstanceswouldstillneedtobe
manuallyassignedtoinstancegroups.However,youcanconfigureaninstancegroup
asanautoregistrationinstancegroup.Anytimeautodiscoveryfindsandaddsanew
instancetotherepository,thatinstancewillautomaticallyberegisteredtotheauto
registrationinstancegroup.
>>>InstancegroupsaremanagedviatheNetBackup AdminConsoleorviaoptionsto
thenboraadm commandintroducedinNetBackup 7.6thatallowinstancegroupsto
becreated,havecredentialsassociatedwiththem,andassigninstancestothem.
>>>Someexamplesofmanaginginstancegroupsusingnboraadm areshownhere:
nboraadm add_instance_group

39
nboraadm list_instance_group
nboraadm delete_instance_group
nboraadm modify_instance_group
nboraadm auto_registration
nboraadm disable_auto_registration
nboraadm register_instance instance_group

For moreinformationonusingavailableoptionstousewithnboraadm pleaserefer


NetBackup 7.6CommandReferenceGuide.

39
StartinginNetBackup 7.6,theNetBackup Administrationconsoleallowsyoutoview
andmanipulatetheOracleinstancerepository,underNetBackup Management>
Applications>Oracle.Twosubtabs existunderthis,calledInstances andInstance
Groups.

40
ByhighlightingtheInstance subtabandclickingthestarbursticon,youcanaddan
instancetotherepository.Noticethethreepiecesofinformationthatisbeing
collected:Thenameoftheinstance,thehostitexiston,andthepathtotheOracle
softwareneededbytheinstance.
ClickingOK willaddtheunregisteredinstanceintotherepository.
>>>ClickingtheProvideCredentialsbuttonallowstheadministratortoregisterthe
instanceatthetimetheinstanceisaddedtotherepository.

41
Whetheryouregistertheinstancewhenyouaddittotherepositoryorafterithas
beenadded,thesamedialogboxisused.
Onewaytoregistertheinstanceisbyassociatingtheinstancewithanexisting
instancegroup.InstanceGroupswillallusethesamesetofCredentials,soinstances
thatusethesamelogincredentialscanbeaddedtothesameInstancegroup. Ifthe
radiobuttonisselectedatthetopofthedialogbox,thedropdownboxwillbeactive
andyouwillbeabletoselectfromtheexistinginstancegroups.
>>>Alternatively,youcanregistertheinstancebyusinginstancecredentials, aswas
doneinthisexampleontheslide.
InstanceCredentialswillrequireanoperatingsystemusernameandpassword, andif
theoperatingsystemisWindows,thedomainwillneedtobespecified.
>>>TheAuthentication framedetermineswhatcredentialswillbeused:eitherthe
OScredentialsorOraclecredentialsasdeterminedbytheradiobuttons.
>>>TheOracleRMANRecoveryCatalogCredentials frameallowsyoutospecify
whetherornotanOracleRecoveryCatalogwillbeused.Checktheboxinthisframe
andfillintherestoftheinformationliketheusername,password,andTNSidentifier
fortherecoverycatalog.
Finally,clickingOK willvalidatethecredentialsandsavetheregistration.

42
Registrationcredentialvalidationensuresthatthecredentialswillworkforthat
instance.This validationoccurswhenaninstanceisregistered,modified,oraddedto
aninstancegroup,orwhenaninstancegroupismodified,andwilloccurforall
instancesinthegroup,evenifonlyoneinstanceismodifiedoradded.
>>>Registrationcredentialvalidationfailurewillidentifywhichcredentialsfailed,to
maketroubleshootingeasier. Ifafailureoccurs,theregistrationcanbeaborted,orbe
allowedtocontinueregardless.

43
WhencreatinganInstanceGroupyoucanhaveitcontainuptofoursetsof
credentials: WindowsCredentials,Unix/LinuxCredentials,OracleCredentials,and
RMANCredentials.
NetBackup willeitheruseOracleorOScredentialstoaccessthedatabase.IfOS
credentialsareused,NetBackup willusetheOScredentialsthatapplytothehostthe
instanceisrunningon.IftheInstancegroupdoesnotcontain credentialsforthe
requiredOS,thenaccesstothedatabase,andvalidation,willfail.
>>>Hereweseethevalidationbutton.Inthisscreenshotitisgreyedoutbecausewe
arecreatinganinstancegroup.Instancegroupvalidationoccursagainsttheinstances
addedtothegroup,andcanonlyrunagainstinstancegroupsthathaveinstances
associatedwiththem.Thisbuttonwillbecomeactivewhenatleastoneinstanceuses
thisgroupforregistration.

44
Whencredentialsarevalidatedagainstaninstancegroup, thevalidationactually
occursagainstall theinstancesassociatedwiththatgroup.Areportisgeneratedfor
eachinstancethatfailedthevalidationspecifyingwhatcredentialsinthegroups
causedthevalidationfailure.
ValidationoftheGroupoccursbyclickingtheValidatebuttonwhenchangingthe
group,whenaninstanceassociatedwiththegroupischanged,orwhenoneormore
setsofcredentialsofthegrouparechanged.

45
Thescreenshot ontheslideshowstheresultofattemptingtoregisteraninstance
wherethecredentialvalidationfailed.Theerrormessagespecifiesexactlywhich
credentialscausedtheissue.Inthiscasetheproblemiswiththe operatingsystem
credentials.
Theadministratorcandooneoftwothings:ClickOK andstillsavetheregistrationor
clickCancel inwhichcasetheregistrationisnotsaved.
Remember,onlyinstancesthatareregisteredcanbeusedinpolicies.

46
TosetupautoregistrationinNetBackup for newlyidentifiedOracleinstances,select
eitherNetBackup Management>Applications>Oracle,orNetBackup Management
>Applications>Oracle>Instances intheobjecttree,>>>thenclickActions>Auto
Registrationfromthemenu bar.>>>ThisbringsuptheAutomaticRegistration
propertybox.Clickon theAutomaticallyRegisterNewlyDiscoveredInstances,and
thenselecttheinstancegroupyouwanttheseinstancestojoin.

47
NetBackup willattempttoautomaticallydiscovernewinstancesofOracledatabases.
Thisprocessofinstancediscoveryisarecurringoperationthatrunsevery5minutes
(300seconds)bydefault.Thiscanbechangedbyusingbpsetconfig tochangethe
valueofNBARS_DISCOVERY_TIMER whichspecifiesthediscoveryintervalperiod,in
seconds.
>>>Twonewprocessesexistthatactuallyperformthediscoveryoperations.
nbdisco,whichrunsonboththemasterserverandclients,isresponsiblefor
collectingtheinformationfromtheclients.Itprovidesageneralclientdiscovery
infrastructure.
Forexample,onLinuxclientswhenlookingforOracleinstances,itconsultsthe
/etc/oratab file,soanyinstancesthatarenotreferencedinthisfilewillnotbeauto
discoveredandwillhavetobeaddedmanually.
Theinformationthatiscollectedabouteachinstanceincludesthepathtotheoracle
installationforthatinstance,thenameoftheinstance(SID),andthenameofthe
hostwheretheinstanceresides.
nbars,whichrunsonlyonthemasterserver,isresponsiblefortakingthis data,
checkingiftheinstanceisalreadyknowntothemasterserver,andaddingthe
informationabouttheinstanceintotherepositoryintheNetBackup relational
database(NBDB).

48
NetBackup maintainsanOracleinstancestate.InstancescanbeActive orInactive.
OnlyActive instanceswillbebackedup.Anyregisteredinstance,regardlessofits
state,canbeaddedtoapolicy.
ThestateofaninstancecanbemanagedusingtheNetBackupAdministration
Console, orthenboraadm utility introducedinNetBackup7.6.
Bydefault,instancesareactive.Anexamplewouldbetomakeaninstanceinactiveif
youknowitwillbemadeofflineforalongperiodoftime,forexamplefor
maintenance,anddontwantfailedjobstooccurwhileitisoffline.

49
>>>SinceOracleIntelligentPolicies generatethescripts,OracleIntelligentPolicies
havetocollectmoreinformationupfrontthanregularorclassic Oraclepolicies. This
additionaldatagetsstoredaspartofthepolicydefinitionasopposedtothescript
definitionasoccursinclassicOraclepolices.
>>>ByDefaultin7.6NetBackup createsanOracleIntelligentPolicy,producingan
extraOracletabandhavingan"Instances"tab inplaceoftheClientstab. Tochange
thepolicytoaregularorclassicOraclepolicy,editthe"Instances"informationto
backup"Clientsforusewithscriptsortemplate".

50
InNetBackup 7.6,anOraclepolicyhasthreetypesofclientliststhatcanbechosen
from.
>>>Oneisalistofhosts,orservers,anddeterminesthatthispolicyistreatedthe
sameasanOraclepolicypriortoNetBackup 7.6.TheselegacyOraclepolicieshave
notchanged,andtheavailablescheduletypesarestillAutomaticFull,Automatic
DifferentialIncremental,AutomaticCumulativeIncrementalandApplicationBackup.
Likewise,thetypesofbackupselectionsforhostbasedpoliciesarestilleitherScripts
orTemplates.Theselectionforthesein theconsoleisshown asClientforusewith
scriptsortemplates.
>>>TheothertwoclientlistsareInstances,orInstanceGroups,andbothdetermine
thatthepolicyisconsideredanewOracleIntelligentPolicy,introducedin
NetBackup 7.6.TheseOraclepolicieshavedifferentscheduletypesandbackup
selectionliststhatwillbediscussedinthefollowingslides.
>>>Notethatwhichevertypeofclientlistisdesired,apolicycanonlyhaveoneclient
listtypeselected.

51
ToaddaninstanceorinstancegroupfromwithintheINSTANCES tabinthepolicy,
simplyclicktheNew button.ThiswillbringupalistoftheOracleInstancesor
InstanceGroupsthatareknowntothemasterserver.

52
Thisslideshowsthewarningonegetswhentheclientlisttypeischangedfroma
instancebasedtohostbased.Thewarningreads:ExistingBackupSelections and
InstanceSelectionswillbeerasedifyouselectthisoption.TheOracletabwillalsobe
removedsincethoseoptionsmustnowbesetintheRMANscriptsuppliedbythe
user.

53
Noticethatwhentheclientlisttypeischangedfrominstancebasedtohostbased,
changestotheinterfacearemade.TheInstances tabisrelabeledtoClients, andthe
Oracle tabisremoved.ThispolicyisnowalegacyOraclepolicy,similartoNetBackup
priorto7.6.

54
Iftheclientlisttypeiseitherinstanceorinstancegroup,thepolicyisconsidered
anOracleintelligentpolicy,alsoknownasaninstancebasedOraclepolicy.
TheavailablebackupselectionsforaninstancebasedOraclepolicyaredifferentthan
legacy,hostbasedOraclepolicies:
>>>Thewholedatabasebacksupalldatafiles ofthedatabaseandthedatabase's
controlfile.NetBackup willalsoautomaticallyincludeasecond,separatecontrolfile
backupbecausethefirstcontrolfilebackupdoesnotcontainenoughinformationto
performrestores.
>>>Tablespaces allowsforspecificallynamedtablespacestobebackedupinthe
instances.Again,NetBackup willincludeaseparatecontrolfilebackupthatfacilitates
restores.
>>>Datafile allowsspecificdatafilepathstobebackedup.Again,likethefirsttwo
typesofselectionlists,Datafile selectionlistswillcauseNetBackup toincludea
separatecontrolfilebackup.
>>>AFlashRecoveryAreaisadirectoryorfolderusedbyOracletostorearchiveredo
logs,andpossiblyusedasadefaultlocationforRMANbackups.TheOracleDBAcan
useRMANtobackupthedatabasetodisk,iftheinstancehasaflashrecoveryarea,
andhavethebackupregisteredinthedatabasecontrolfile.
>>>HavingNetBackup performaFlashRecoveryAreabackuptellsRMANtomakea

55
copyofthebackupthatalreadyexistsintheFRA,andsendthecopytoNetBackup.
Thisnewbackupwillberegisteredinthedatabasecontrolfileasacopyofthefirst
backup,soRMANwillrecognizetwocopiesofthebackup.NetBackup willnot be
awareofthebackupthatexistsintheFRA,onlyofthecopythatitwassent.
>>>Unliketheotherbackupselectiontypes,backinguptheFRAdoesnot includea
separatebackupofthecontrolfile.

55
WhenaninstancebasedOraclepolicyiscreated,the defaultbackupselectionlistis
setuptobackupthewholedatabase.

56
ChangingthebackupselectiontoeitherPartialDatabase Tablespaces orPartial
Database Datafiles, andclickingBrowse, allowsyoutoselectfromavailable
tablespaces ordatafiles.
InthisexampleweclickedtheBrowse buttonandareselectingtheORCL2_TEXT
tablespace foundintheORCL2 instance.

57
Noreferencetowhatinstanceanobjectcamefromisretainedinthebackup
selectionlist.NetBackup willattempttobackupalltheobjectsintheinstanceslisted
intheInstances tabfromalldatabasesselected.

58
Fortablespace anddatafile backups,notallobjectsneedtofoundinallinstances.
Thebackupjobswillsucceedifatleastoneitemfromthebackupselectionlistis
foundineachinstance,whichisbehaviorthatissimilartofilesystembackupsand
backupselectionlists.
Jobsthathavenoobjectsthatmatchthebackupselectionlist,terminatewithstatus
code 5400.Thisdoesnotaffectotherjobsbackingupinstanceswhichfindobjectsto
backup,whichcompletesuccessfully.
Althoughsnapshotsandblocklevelincrementalbackupsaresupported,theremaybe
somescheduletypes thatdonotsupportthisfunctionality,suchasarchivelog
backups.

59
60
Hostbased Oraclepolicieshavebackuptypesthatincludethosethatwearefamiliar
with:FullBackup,DifferentialandCumulativeIncrementalBackups,andApplication
Backup.
>>>InstancebasedOraclepoliciesintroducetheArchivedRedoLogBackuptype,and
nolongersupportApplicationBackups.
>>>Thefrequenciesavailableformostschedulesaresimilartootherpolicytypes,
whichallowfrequenciesasshortasperhour.
>>>TheexceptiontothisistheArchivedRedoLogBackup,whichallowsafrequency
granularitydowntominutes.

61
TheOracle tabcontainsOraclespecificparametersthat,withlegacypolicies,would
havetobespecifiedintheRMANscript.Viewthedocumentation,orclickonthe
Help buttontogetmoreinformationontheseparameters.
Newoptionsforbpplinfo havebeenaddedthatallowforthemodificationofthese
valuesonthecommandline.

62
63
64
65
66
67
TheRecoveryWizardsolicitsinformationfromtheuseraboutthedesiredRMAN
restoreandrecoveryoperationstocreateatemplatewhichissavedinauser
specifiedlocation.
PasswordsforOracledatabaseaccessarestoredencryptedinthetemplateand
decryptedatruntime.
Therestorebrowserisusedtodisplaydatabaseobjects.Ahierarchicaldisplayis
providedwhereobjectscanbeselectedforrecovery.
LimitationsofusingRecoverywizardforOraclerestore:
Thedatabaseisdisplayedonlyinitscurrentstate.Ifobjectshavebeendeleted
fromthedatabasesincethelastbackup,theseobjectsdonotappearamongthe
objectsyoucanselectforrestore.Torestoretheobjectsthathavebeendeleted,you
needtorestoretheentiredatabasepointintimebeforetheobjectsweredeleted.
Dataisrestoredtotheoriginallocation.Thewizarddoesnotprovideawayforthe
usertospecifyalternatefilenames.
Thewizarddoesnotrestorecontrolfiles

68
69
70
>>>IfeithertheArchivedortheOnlineredologsaremissingthenyoumayhaveto
doaRESETLOGS operation.
>>>Adatabase incarnation iscreatedwheneveryouopenthedatabasewith
the RESETLOGS option.Aftercompleterecovery,youcanresumenormaloperations
withoutan OPENRESETLOGS.AfteraDBPITR orrecoverywithabackupcontrolfile,
however,youmustopenthedatabasewiththeRESETLOGS option,therebycreatinga
newincarnationofthedatabase.Thedatabaserequiresanewincarnationtoavoid
confusionwhentwodifferentredostreamshavethesameSCNs,butoccurredat
differenttimes.Ifyouapplythewrongredotoyourdatabase,thenyouwillcorruptit.
TheexistenceofmultipleincarnationsofasingledatabasedetermineshowRMAN
treatsbackupsthatarenotinthecurrentincarnationpath.Inalmostallcases,the
currentdatabaseincarnationisthecorrectonetouse.Nevertheless,insomecases
resettingthedatabasetoapreviousincarnationisthebestapproach.Forexample,
youmaybedissatisfiedwiththeresultsofapointintimerecoverythatyouhave
alreadyperformedandwanttoreturnthedatabasetoatimebeforethe RESETLOGS.
Anunderstandingofdatabaseincarnationsishelpfultoprepareforsuchsituations.
>>>OPENRESETLOGoperations
Whenyouopenthedatabasewiththe RESETLOGS option,thedatabaseperformsthe
followingactions:
Archivesthecurrentonlineredologs(iftheyareaccessible)andthenerasesthe
contentsoftheonlineredologsandresetsthelogsequencenumberto1.
Forexample,ifthecurrentonlineredologsaresequence1000and1001whenyou

71
open RESETLOGS,
thenthedatabasearchiveslogs1000and1001andthenresetstheonlineredologs
to
sequence1and2.
Createstheonlineredologfilesiftheydonotcurrentlyexist.
Initializesredothreadrecordsandonlineredologrecordsinthecontrolfiletothe
beginningofthenewdatabaseincarnation.Morespecifically,thedatabasesets
theredothreadstatustoclosed,setsthecurrentthreadsequenceintheredo
threadrecordsto1,setsthethreadcheckpointofeachredothreadtothe
beginningoflogsequence1,choosesoneredologfromeachthreadandinitialize
itssequenceto1,andsoon.
Updatesallcurrentdatafiles andonlineredologsandallsubsequentarchivedredo
logswithanew RESETLOGS SCN andtimestamp.Becausethedatabasewillnot
applyanarchivedredologtoadatafile unlessthe RESETLOGS SCN andtime
stampsmatch,the RESETLOGS requirementpreventsyoufromcorruptingdatafiles
witharchivedlogsthatarenotfromdirectparentincarnationsofthecurrent
incarnation.
Toperformrecoverythrough RESETLOGS youmusthaveallarchivedlogsgenerated
afterthemostrecentbackupandatleastonecontrolfile(current,backup,or
created).

71
72
73
74
75
76
77
Moreinformationonprotecting OracleDatabasesinclusteredenvironmentsis
availableinNetBackup 7.6forOracleAdministrator'sGuide
http://www.symantec.com/docs/DOC6481

78
>>>ToconfigureaproxycopyOraclebackup,youneedtoedittheRMANscriptand
configureNetBackup forOracle
NOTE:OneoftheproblemswithFILESPERSET=1isthat,forlargedatabaseses,it
causesalotof"Objects"tobecreatedindeduplicated storageandthereisaknown
issuewithDeduplicationandOraclebackupswhererestoresfailbecauseoftimeouts
causedbyanexcessivenumberof"Objects".

79
80
MuchoftheloggingforajobfromaninstancebasedOracle policyisthesameasitis
forahostbased(legacy)Oraclepolicy,howevertherearesomenewtasksthathave
someadditionalloggingconsiderations,asshownontheslide.

81
Themainpurposeofbphdb istorunanOracleIntelligentPolicyoratemplateora
shellscriptthatcallsrman,bporaexp,orbporaimp
orasbt.dll/libobk
a sharedlibrarymodulethatcontainsthefunctionsthatRMANcancall
ThislibraryisloadedwhenRMANisstarted.
Thenameofthisbinarydependsontheoperatingsystem.

82
83
84
SomelimitationsforinstancebasedOraclepoliciesarelistedontheslide, which
includeOracle9inolongerbeingsupported,aswellasthePLinuxOracleclient
platform.
ArchiveLogBackupschedulesarestreambasedanddonotsupportproxycopy
operations.
Also,unlikelegacyOraclepolicybehavior,backupscannotbeinitiatedbyrunning
scriptcommandsinRMAN.Toallowthisbehavior,createahostbasedOraclepolicy
withanApplicationBackupschedulewithanopenstartwindow.Inotherwords,
createatraditionalhostbasedOraclepolicy.

85
Inthefollowingslides,anexamplescenarioisusedtoshowscreenshotswiththe
results andoutputfromthisscenario.
>>>TheOraclepolicyusedhasselectedthreeinstancestobackup,asshownonthe
slide.
>>>TheOraclepolicyusesabackupselectionlisttobackuponlyspecificlisted
tablespaces,insteadofbackingupthewholedatabase.Inthiscase,thetwo
tablespaces selectedareORCL_TEST,andORCL2_TEST.Thepolicywillattemptto
backupbothofthesetablespaces fromallthreeOracleinstances.
>>>However,theactualtablespaces thatexistinOracleareshownontheslide.
InstanceORCLcontainsonlythetablespace ORCL_TEST.InstanceORCL2containsonly
thetablespace ORCL2_TEST.Finally,instanceRMANCATdoesnotcontainany
tablespaces witheitherofthesenames.
Letsseewhatbackupjobsresultfromthisscenario.

86
Thisslideshowsthejobhierarchyofourbackupjob.
>>>First,thereisaparentjobwhichmanagestheotherbackupjobs,andwill
continuetoremainintheRunningstateuntilallbackupjobshavecompleted.
>>>Next,foreachinstance,thereisadiscoveryjobthatfiguresoutwhatwillbe
backedupfromeachinstance.NoticethatsincetheRMANCATinstancedoesnot
containsanyoftheobjectsfromthebackupselectionlist,itsdiscoveryjobfailswith
statuscode5400,whiletheotherdiscoveryjobsaresuccessful.
>>>Thediscoveryjobsthatsucceedspawnadditionaljobstoperformtheactual
backups.Notethatbyexaminingtheparentjobcolumn,wecanseethehierarchyof
jobcreation.
Inthiscasejob114spawneddiscoveryjobs115,116and117.Job115,whichisthe
discoveryjobforinstanceORCL2,spawnsjob118tobackupthefoundobjects(inthis
casetablespace ORCL2_TEST)andthenspawnsjob120tobackupthecontrolfilefor
instanceORCL2.
Similarly,job116,thediscoveryjobforORCL,spawnsjob119and121tobackupthe
foundobjectsandthecontrolfileforinstanceORCL.

87
Thisslideshowsthediscoveryjobdetailsofjob115.Thisisthediscoveryjobforthe
ORCL2instance.>>>ThedetailsshowthattheORCL2_TESTtablespace wasfoundbut
thattheORCL_TESTtablespace wasnotfound.
>>>Scrollingfurtherinthejobdetails, you canseethegeneratedRMANsyntaxthat
willbeusedtobackuptheORCL2_TESTtablespace.

88
Thisslideshowsthedetailsforafaileddiscoveryjob.Inthiscase,theOracleinstance
doesnotcontainanyofthenamedobjectsforthispolicy, whichinthiscasewas
tablespaces with thenameORCL2_TESTandORCL_TEST.>>>Sincethediscoveryjob
couldnotfindany oftheobjectsrequested,itreturnsa5400error.Unlike successful
discoveryjobsthathavebackupjobsassociatedwiththem,thisdiscoveryjobhasno
backupjobsassociatedwithit.

89
Thisslideshowsbackupjob118,whichisthejobthatbacksupthetablespace data
frominstanceORCL2.TheFilelistshowsanOraclehandlecreatedbyNetBackup for
thisbackupjob.TheformatofthishandlecanbespecifiedintheOracletabofthe
policy.
>>>Thejobdetails,whichshow informationaboutthebackup,arealsoshownonthe
slide.

90
91
92

Anda mungkin juga menyukai