ACE Director Alum Daniel Morgan, founder of Morgan's Library, is scheduling
complimentary technical Workshops on Database Security for the first 30
Oracle Database customers located anywhere in North America, EMEA, LATAM, or
APAC that send an email to
asra_us@oracle.com. Request a Workshop for
your organization today.
Purpose
Internal support package for Transportable Tablespaces.
AUTHID
DEFINER
Constants
Name
Data Type
Value
General
TS_EXP_BEGIN
BINARY_INTEGER
1
TS_EXP_END
BINARY_INTEGER
2
Function Constants
C_ADD
NUMBER
1
C_TRUNCATE
NUMBER
2
C_USER
NUMBER
1
C_TABLESPACE
NUMBER
2
Dependencies
CLU$
DUAL
SEQ$
COL$
FILE$
TAB$
DBMS_ASSERT
IDGEN1$
TABPART$
DBMS_EXTENDED_TTS_CHECKS
IND$
TABSUBPART$
DBMS_METADATA
INDPART$
TS$
DBMS_PITR
KUPCC
TTS_INFO_T
DBMS_PLUGTSP
KUPF$FILE
TTS_INFO_TAB
DBMS_PLUGTS_LIB
KUPP$PROC
USER$
DBMS_SPACE_ADMIN
KUPW$WORKER
V$DATABASE
DBMS_STREAMS_TABLESPACE_ADM
LOB$
V$DATAFILE
DBMS_SYS_ERROR
OBJ$
V$PARAMETER
DBMS_TDB
PLITBLM
X$KCVFH
DBMS_TTS
SEG$
Documented
No
Exceptions
Error Code
Reason
ORA-29304
Tablespace not found
ORA-29335
Tablespace not readonly
ORA-29336
Internal error
ORA-29338
Datafile not ready
ORA-29339
Blocksize mistmatch
ORA-29340
Export file corrupted
ORA-29341
Not self contained
ORA-29342
User not found
ORA-29343
Mapped user not found
ORA-29344
User not in list
ORA-29345
Different character set
ORA-29346
Invalid tablespace list
ORA-29347
Tablespace not in list
ORA-29348
Datafiles missing
ORA-29349
Tablespace name conflict
ORA-29351
System or Temporary tablespace
ORA-29353
Tablespace list overflow
ORA-39185
Tablespace failure list
ORA-39186
Tablespace list empty
ORA-39187
Not self-contained list
First Available
7.3.4
Security Model
Owned by SYS with granted to GSMADMIN_INTERNAL and SYSBACKUP and the EXECUTE_CATALOG_ROLE role
Direct access to some objects in this package is prevented by means of an Accessible By clause.
Sets the target tablespaces and it's owner. Checks to make sure the tablespace name does not conflict with any existing tablespaces already in the database.
Verifies the block size is the same as that in the target database. If this succeeds, begins importing metadata for the tablespace. This procedure call appears in the export file.
dbms_plugts.beginimptablespace(
tsname IN VARCHAR2, -- tablespace name
tsID IN NUMBER, -- tablespace ID in original database
owner IN VARCHAR2, -- owner of tablespace
n_files IN BINARY_INTEGER, -- number of datafiles in the tablespace
contents IN BINARY_INTEGER, -- contents column of ts$ (TEMP/PERMANENT)
blkSize IN BINARY_INTEGER, -- size of block in bytes
inc_num IN BINARY_INTEGER, -- incarnation number of extent
clean_SCN IN NUMBER, -- tablespace clean SCN
dflminext IN NUMBER, -- default minimum number of extents
dflmaxext IN NUMBER, -- default maximum number of extents
dflinit IN NUMBER, -- default initial extent size
dflincr IN NUMBER, -- default initial extent size
dflminlen IN NUMBER, -- default minimum extent size
dflextpct IN BINARY_INTEGER, -- default percent extent size increase
dflogging IN BINARY_INTEGER, -- default logging attribute
affstrength IN NUMBER, -- affinity strength
bitmapped IN NUMBER, -- if bitmapped
dbID IN NUMBER, -- database ID
directallowed IN NUMBER, -- allowed
flags IN BINARY_INTEGER, -- flags
creation_SCN IN NUMBER, -- tablespace creation SCN
groupname IN VARCHAR2, -- group name
spare1 IN NUMBER, -- spare1 in ts$
spare2 IN NUMBER, -- spare2 in ts$
spare3 IN VARCHAR2, -- spare3 in ts$
spare4 IN DATE, -- spare4 in ts$
seg_fno IN NUMBER DEFAULT 0, -- file# for space_hdr in seg$
seg_bno IN NUMBER DEFAULT 0, -- block# for space_hdr in seg$
seg_blks IN NUMBER DEFAULT 0); -- blocks, size of space_hdr in seg$
Calls statically linked C routines to associate the datafile with the tablespace and validates file headers.
This procedure appears in the export file. The parameter list includes all columns in file$, except those that will be discarded (status$, ownerinstance).
dbms_plugts.checkdatafile(
name IN VARCHAR2, -- file name (excluding path)
databaseID IN NUMBER, -- database ID
absolute_fno IN BINARY_INTEGER, -- absolute file number
curFileBlks IN NUMBER, -- size of file in blocks
tablespace_ID IN NUMBER, -- tablespace ID in original database
relative_fno IN BINARY_INTEGER, -- relative file number
maxextend IN NUMBER, -- maximum file size
inc IN NUMBER, -- increment amount
creation_SCN IN NUMBER, -- file creation SCN
checkpoint_SCN IN NUMBER, -- file checkpoint SCN
reset_SCN IN NUMBER, -- file reset SCN
spare1 IN NUMBER, -- spare1 in file$
spare2 IN NUMBER, -- spare2 in file$
spare3 IN VARCHAR2, -- spare4 in file$
spare4 IN DATE); -- spare4 in file$
Verifies that objects are self-contained in the tablespaces specified
The transport set must first be defined
dbms_plugts.checkpluggable(
incl_constraints IN NUMBER,
incl_triggers IN NUMBER,
incl_grants IN NUMBER,
full_check IN NUMBER,
do_check IN NUMBER DEFAULT 1,
job_type IN VARCHAR2 DEFAULT NULL,
encryption_password IN BOOLEAN DEFAULT FALSE);
Checks to see that the user name in the pluggable set matches that entered by the DBA via the import USERS command line option.
Makes sure that, after the user mappings, the required user is already in the database. This procedure call appears in the export file.
dbms_plugts.checkuser(username IN VARCHAR2);
-- test with one real and one fake username
SELECT username
FROM dba_users
ORDER BY1;
Determines whether a plug into a specified database char and nchar set is compatible with the current database
dbms_plugts.kcp_check_tts_char_set_compat(
has_clobs IN BINARY_INTEGER,
has_nchars IN BINARY_INTEGER,
char_semantics_on IN BINARY_INTEGER,
target_charset_name IN VARCHAR2,
target_ncharset_name IN VARCHAR2);
Checks if char, nchar set match. Raises an exception if they do not
dbms_plugts.kcp_chkchar(
cid IN BINARY_INTEGER, -- char ID
ncid IN BINARY_INTEGER, -- nchar ID
chknc IN BINARY_INTEGER, -- check nchar (1 or 0)
has_clobs IN BINARY_INTEGER,
has_nchars IN BINARY_INTEGER,
char_semantics_on IN BINARY_INTEGER);
Informs the dbms_plugts package of the location of the new datafiles. If the file can not be found, an error will be signaled: possibly at a later point
Informs the dbms_Plugts package about the location of a new datafile. This is a whitelist version of newDatafile. Only accessible from the sys.kupw$worker package.
dbms_plugts.plts_newDatafile(
filename IN VARCHAR2)
ACCESSIBLE BY (PACKAGE sys.kupw$worker,
PACKAGE gsmadmin_internal.exchange);
Can not be executed directly due to the ACCESSIBLE BY clause
Reclaims a segment by calling the statically linked C routine kcp_plg_reclaim_segment. This procedure call appears in the export file.
dbms_plugts.reclaimtempsegment(
file_no IN BINARY_INTEGER,
block_no IN BINARY_INTEGER,
type_no IN BINARY_INTEGER,
ts_no IN BINARY_INTEGER,
blocks IN BINARY_INTEGER,
extents IN BINARY_INTEGER,
iniexts IN BINARY_INTEGER,
minexts IN BINARY_INTEGER,
maxexts IN BINARY_INTEGER,
extsize IN BINARY_INTEGER,
extpct IN BINARY_INTEGER,
user_no IN BINARY_INTEGER,
lists IN BINARY_INTEGER,
groups IN BINARY_INTEGER,
bitmapranges IN NUMBER,
cachehint IN BINARY_INTEGER,
scanhint IN BINARY_INTEGER,
hwmincr IN BINARY_INTEGER,
spare1 IN BINARY_INTEGER,
spare2 IN BINARY_INTEGER);
Selects an anonymous block for retrieval. blockID is the ID to pick an anonymous block. Use ts_exp_begin at the beginning of of export and ts_exp_end at the end.
dbms_plugts.selectBlock(blockID IN BINARY_INTEGER);
Initializes global variables used for debugging trace messages. Trace/debug flags from /TRACE param or trace/debug event, possibly including global trace/debug flags.
dbms_plugts.setdebug(debug_flags IN BINARY_INTEGER);
Initialize global variables to communicate options settings from the Data Pump Worker to the PLTS code. Only a DataPump worker is allowed to call this routine.
dbms_plugts.setOption(
option_name IN VARCHAR2 DEFAULT NULL,
option_value IN VARCHAR2 DEFAULT NULL)
ACCESSIBLE BY (PACKAGE sys.kupw$worker);
Can not be executed directly due to an ACCESSIBLE BY clause