{"id":225,"date":"2012-03-02T04:08:42","date_gmt":"2012-03-02T04:08:42","guid":{"rendered":"http:\/\/oranotes.tuktaroff.com\/?page_id=225"},"modified":"2012-03-02T04:10:54","modified_gmt":"2012-03-02T04:10:54","slug":"transportable-tablespaces","status":"publish","type":"page","link":"http:\/\/oranotes.tuktaroff.com\/?page_id=225","title":{"rendered":"Transportable tablespaces"},"content":{"rendered":"<p><code><br \/>\n<script type=\"text\/javascript\"> \nfunction copy(what) {\n    window.clipboardData.setData('Text',what.value);\n}\nfunction paste(what) {\n    what.value = window.clipboardData.getData('Text');\n}\n<\/script><\/p>\n<form action=\"\"><textarea name=\"data\" cols=\"50\" rows=\"10\" style=\"display:none;\"><br \/>\n-- check if TTS are self-contained<br \/>\nexec dbms_tts.transport_set_check( 'EBI_PROV_OTR1_DAT, EBI_PROV_OTR1_IDX, EBI_STORE_OTR1_DAT, EBI_STORE_OTR1_IDX', true );<\/p>\n<p>select * from TRANSPORT_SET_VIOLATIONS;<\/p>\n<p>-- put TTS in read-only mode<br \/>\nalter tablespace EBI_STORE_OTR1_DAT read only;<br \/>\nalter tablespace EBI_STORE_OTR1_IDX read only;<\/p>\n<p>-- Run export of metadata of transportable tablespaces<br \/>\nexpdp \\'\\\/ as sysdba\\' DUMPFILE=BIPD_dat.dmp DIRECTORY=EXPD TRANSPORT_TABLESPACES=EBI_PROV_OTR1_DAT,EBI_PROV_OTR1_IDX,EBI_STORE_OTR1_DAT,EBI_STORE_OTR1_IDX,EBI_PROV_OTR2_DAT TRANSPORT_FULL_CHECK=Y logfile=EXPD:expdp_bipd_20110321.log<\/p>\n<p>-- copy TTS datafiles to destination host<br \/>\nscp <\/p>\n<p>-- put TTS in read-write mode<br \/>\nalter tablespace EBI_STORE_OTR1_DAT read write;<br \/>\nalter tablespace EBI_STORE_OTR1_IDX read write;<\/p>\n<p>-- import TTS on destination database<br \/>\nimpdp user\/password parfile=imp_datafiles.par exclude=statistics directory=ebi_export logfile=imp_datafile.log<\/p>\n<p>imp_datafiles.par:<br \/>\ntransport_datafiles=(<br \/>\n \/oracle\/BIUAT\/oradata12\/BIPD\/ebi_prov_otr1_dat01.dbf<br \/>\n,\/oracle\/BIUAT\/oradata15\/BIPD\/ebi_store_otr1_idx03.dbf<br \/>\n,\/oracle\/BIUAT\/oradata15\/BIPD\/ebi_store_otr1_idx04.dbf)<\/p>\n<p><\/textarea><input type=\"button\" value=\"Clipboard\" onclick=\"copy(this.form.data)\"><\/form>\n<pre class=\"qcode\">\r\n-- check if TTS are self-contained\r\nexec dbms_tts.transport_set_check( 'EBI_PROV_OTR1_DAT, EBI_PROV_OTR1_IDX, EBI_STORE_OTR1_DAT, EBI_STORE_OTR1_IDX', true );\r\n\r\nselect * from TRANSPORT_SET_VIOLATIONS;\r\n\r\n-- put TTS in read-only mode\r\nalter tablespace EBI_STORE_OTR1_DAT read only;\r\nalter tablespace EBI_STORE_OTR1_IDX read only;\r\n\r\n-- Run export of metadata of transportable tablespaces\r\nexpdp \\'\\\/ as sysdba\\' DUMPFILE=BIPD_dat.dmp DIRECTORY=EXPD TRANSPORT_TABLESPACES=EBI_PROV_OTR1_DAT,EBI_PROV_OTR1_IDX,EBI_STORE_OTR1_DAT,EBI_STORE_OTR1_IDX,EBI_PROV_OTR2_DAT TRANSPORT_FULL_CHECK=Y logfile=EXPD:expdp_bipd_20110321.log\r\n\r\n-- copy TTS datafiles to destination host\r\nscp \r\n\r\n-- put TTS in read-write mode\r\nalter tablespace EBI_STORE_OTR1_DAT read write;\r\nalter tablespace EBI_STORE_OTR1_IDX read write;\r\n\r\n-- import TTS on destination database\r\nimpdp user\/password parfile=imp_datafiles.par exclude=statistics directory=ebi_export logfile=imp_datafile.log\r\n \r\nimp_datafiles.par:\r\ntransport_datafiles=(\r\n \/oracle\/BIUAT\/oradata12\/BIPD\/ebi_prov_otr1_dat01.dbf\r\n,\/oracle\/BIUAT\/oradata15\/BIPD\/ebi_store_otr1_idx03.dbf\r\n,\/oracle\/BIUAT\/oradata15\/BIPD\/ebi_store_otr1_idx04.dbf)\r\n\r\n<\/pre>\n<p><\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&#8212; check if TTS are self-contained exec dbms_tts.transport_set_check( &#8216;EBI_PROV_OTR1_DAT, EBI_PROV_OTR1_IDX, EBI_STORE_OTR1_DAT, EBI_STORE_OTR1_IDX&#8217;, true ); select * from TRANSPORT_SET_VIOLATIONS; &#8212; put TTS in read-only mode alter tablespace EBI_STORE_OTR1_DAT read only; alter tablespace EBI_STORE_OTR1_IDX read only; &#8212; Run export of metadata of transportable tablespaces expdp \\&#8217;\\\/ as sysdba\\&#8217; DUMPFILE=BIPD_dat.dmp DIRECTORY=EXPD TRANSPORT_TABLESPACES=EBI_PROV_OTR1_DAT,EBI_PROV_OTR1_IDX,EBI_STORE_OTR1_DAT,EBI_STORE_OTR1_IDX,EBI_PROV_OTR2_DAT TRANSPORT_FULL_CHECK=Y logfile=EXPD:expdp_bipd_20110321.log &#8212; copy TTS datafiles [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":216,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-225","page","type-page","status-publish","hentry"],"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/P2NVny-3D","_links":{"self":[{"href":"http:\/\/oranotes.tuktaroff.com\/index.php?rest_route=\/wp\/v2\/pages\/225","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/oranotes.tuktaroff.com\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"http:\/\/oranotes.tuktaroff.com\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"http:\/\/oranotes.tuktaroff.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/oranotes.tuktaroff.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=225"}],"version-history":[{"count":2,"href":"http:\/\/oranotes.tuktaroff.com\/index.php?rest_route=\/wp\/v2\/pages\/225\/revisions"}],"predecessor-version":[{"id":227,"href":"http:\/\/oranotes.tuktaroff.com\/index.php?rest_route=\/wp\/v2\/pages\/225\/revisions\/227"}],"up":[{"embeddable":true,"href":"http:\/\/oranotes.tuktaroff.com\/index.php?rest_route=\/wp\/v2\/pages\/216"}],"wp:attachment":[{"href":"http:\/\/oranotes.tuktaroff.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=225"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}