總結-表空間傳輸

oracle_ace發表於2007-12-16

Collecting the tablespace information for constraints
-----------------------------------------------------
execute dbms_tts.transport_set_check(ts_list=>'USERS',incl_constraints=>TRUE,full_check=>TRUE);

or

execute dbms_tts.transport_set_check(ts_list=>'USERS,INDX',incl_constraints=>TRUE,full_check=>TRUE);

check the temp table named "transport_set_violations" so as to observe the detail constraints information related to another

tablespace
----------------------------------------------------------------------
select * from transport_set_violations

before exp the tablespace information
-------------------------------------
alter tablespace USERS read only; 
 ---&gttablespace checkpoint will be performed

alter tablespace indx read only;

export the dict information for that tablespace USERS
------------------------------------------------------
exp transport_tablespace=y tablespaces=USERS file=D:\USERS.dmp

username:sys/password@icmnlsdb as sysdba

or

exp tablespaces=users,indx transport_tablespace=y file=exp_users_indx.dmp

username:sys/password@icmnlsdb as sysdba

after exported tablespace,we have to backup the OS file for it and gather them to be one of the backupset so as to transfer

to our target machine
-----------------------------------------------------------------------

How to import the backup tablespace which has been transferred from original target
--------------------------------------------------------------------
imp transport_tablespace=y datafiles='d:\backupdb\users01.dbf','d:\backupdb\users02.dbf'

username:sys/passw0rd@rmdb as sysdba;

or

imp transport_tablespace=y tablespaces=users,indx file=exp_users_indx.dmp

datafiles='D:\ORACLE\ORADATA\ICMNLSDB\USERS01.DBF','D:\ORACLE\ORADATA\ICMNLSDB\INDX01.DBF'

username:sys/passw0rd@rmdb as sysdba;

Online the tablespace
----------------------------------------------------------------------------

alter tablespace users read write;

alter tablespace indx read write;

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/12361284/viewspace-666/,如需轉載,請註明出處,否則將追究法律責任。

相關文章