For how many years have you been working
with physical servers? Software Defined Servers can improve performance and
security while lowering complexity and cost. With Software Defined Servers
you define servers with an optimum configuration to your environment rather
than being memory starved and cpu over-provisioned. Find out how you can
improve your computing environment with
TidalScale. your friends.
Purpose
This package contains procedures which get called during the import phase and export phase of point-in-time recovery (PITR).
During the export phase, EXP calls this package to obtain the text of 2 anonymous PL/SQL blocks. The first block goes at the front of the .dmp file, and the second block goes at the end.
In between the 2 blocks are the DDL commands created by EXP to reconstruct the dictionary for the tablespaces being PITR'd.
The emitted PL/SQL code contains calls to other procedures in this package. IMP must read each anonymous PL/SQL block from the .dmp file, collect it into a single contiguous memory buffer, and then parse and execute the PL/SQL block.
The parsed SQL statement (the PL/SQL anonymous block) must precisely the lines of text that were returned to EXP from this package, with no characters added or deleted.
The order in which the "emit" procedures should be called is in the source file header.
Called from an anonymous PL/SQL block embedded at the beginning of the .dmp file. The anonymous block is parsed and executed by IMP.
dbms_pitr.beginTablespace(
tsid IN BINARY_INTEGER,
createSCN IN NUMBER,
tsBitmap IN NUMBER,
tsFlags IN NUMBER,
tsSegfno IN NUMBER,
tsSegbno IN NUMBER,
tsSegsize IN NUMBER);
Must follow a beginTablespace call. The file must be for the tablespace. There must be one call for each datafile that is part of the tablespace (in the clone database).
dbms_pitr.doFileVerify(
fno IN BINARY_INTEGER,
tsid IN BINARY_INTEGER,
ckptSCN IN NUMBER,
resetSCN IN NUMBER,
resetStamp IN NUMBER,
filesize IN NUMBER,
hdba IN NUMBER);
Builds a list of the files added between the current and the recovery point-in-time. Must follow the last doFileVerify call and must follow a beginTablespace call.
dbms_pitr.endTablespace(
cleanSCN IN NUMBER,
resetSCN IN NUMBER,
resetStamp IN NUMBER);
The exception shown at right demonstrates what happens when a procedure is called, manually, in the wrong sequence
dbms_pitr.selectBlock(blockId IN BINARY_INTEGER);
exec dbms_pitr.selectBlock(424242);
*
ERROR at line 1:
ORA-29301: wrong DBMS_PITR package function/procedure order
ORA-06512: at "SYS.DBMS_PITR", line 855
ORA-06512: at "SYS.DBMS_PITR", line 846
ORA-06512: at line 1
Informs the package that the caller intends to do point-in-time recovery on the specified tablespace. Must be called once for each tablespace in the recovery set.
It alter selected tablespace read only, also checks datafiles in the selected tablespace.