{"id":855,"date":"2014-11-06T23:10:29","date_gmt":"2014-11-06T21:10:29","guid":{"rendered":"http:\/\/www.ludovicocaldara.net\/dba\/?p=855"},"modified":"2020-08-18T16:38:41","modified_gmt":"2020-08-18T14:38:41","slug":"demo-grounds-clone-pdb-rw","status":"publish","type":"post","link":"https:\/\/www.ludovicocaldara.net\/dba\/demo-grounds-clone-pdb-rw\/","title":{"rendered":"Tales from Demo Grounds part 1: Clone PDBs while open READ-WRITE"},"content":{"rendered":"<p>DISCLAIMER: I&#8217;ve got this information by chatting with Oracle developers at the Demo Grounds. The functionality is not documented yet and Oracle may change it at its sole discretion.\u00a0Please refer to the documentation if\/when it will be updated \ud83d\ude09<\/p>\n<p>In one of\u00a0<a href=\"https:\/\/www.ludovicocaldara.net\/dba\/a-pdb-is-cloned-while-in-read-write-data-guard-loose-its-marbles-12-1-0-2-ora-19729\/\">my previous posts named &#8220;A PDB is cloned while in read-write, Data Guard loose its marbles (12.1.0.2, ORA-19729)&#8221; <\/a>I&#8217;ve blogged about a weird behaviour:<\/p>\n<p>The <a href=\"http:\/\/docs.oracle.com\/database\/121\/SQLRF\/statements_6010.htm#CACDDGBH\">documentation states that you can create a pluggable database from another one only if the source PDB is open read-only<\/a>.<\/p>\n<p>Indeed, If I try to clone it when the source PDB is MOUNTED, I get error ORA-65036:<\/p>\n<pre class=\"lang:plsql decode:true\">15:44:24 SYS@CDBATL_1&gt; select inst_id, name, open_mode from gv$pdbs where name='MAAZ';\r\n\r\nINST_ID NAME OPEN_MODE\r\n---------- ------------------------------ ----------\r\n1 MAAZ MOUNTED\r\n2 MAAZ MOUNTED\r\n\r\n15:53:43 SYS@CDBATL_1&gt; create pluggable database ludo from maaz;\r\ncreate pluggable database ludo from maaz\r\n*\r\nERROR at line 1:\r\nORA-65036: pluggable database MAAZ not open in required mode\r\n<\/pre>\n<p>The weird behavior is that if you do it<strong> when the source is in read-write mode, it works from release 12.1.0.2 (onward?)<\/strong><\/p>\n<p>I&#8217;ve questioned the developers at the DEMO Grounds and they have confirmed that:<\/p>\n<ul>\n<li>With the 12.1.0.2, they have initially planned to disclose\u00a0this functionality (clone PDBS in READ-WRITE).<\/li>\n<li>That they had problems in making it work with an Active Data Guard environment (a-ah! so my post was not completely wrong)<\/li>\n<li>Finally they have released it as undocumented feature<\/li>\n<li>In the next release &#8220;they will fix it, maybe&#8221; and document it<\/li>\n<li>The process of cloning the PDB anyway freeze the transactions on the source<\/li>\n<\/ul>\n<p>I hope that this update helps clarifying both the behavior and my previous post about this problem! \ud83d\ude42<\/p>\n<p>Cheers<\/p>\n<p>&#8212;<\/p>\n<p>Ludo<\/p>\n","protected":false},"excerpt":{"rendered":"<p>DISCLAIMER: I&#8217;ve got this information by chatting with Oracle developers at the Demo Grounds. The functionality is not documented yet and Oracle may change it at its sole discretion.\u00a0Please refer to the documentation if\/when it will be updated \ud83d\ude09 In &hellip; <a href=\"https:\/\/www.ludovicocaldara.net\/dba\/demo-grounds-clone-pdb-rw\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[116,327,326,329,3,52,328,149,132],"tags":[209,290,289],"class_list":["post-855","post","type-post","status-publish","format-standard","hentry","category-events-and-conferences","category-oracle-maa","category-oracle","category-oracle-dg","category-oracledb","category-12c","category-oracle-mt","category-oracle-rac","category-triblog","tag-clone","tag-db12c","tag-multitenant"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.ludovicocaldara.net\/dba\/wp-json\/wp\/v2\/posts\/855","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.ludovicocaldara.net\/dba\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ludovicocaldara.net\/dba\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ludovicocaldara.net\/dba\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ludovicocaldara.net\/dba\/wp-json\/wp\/v2\/comments?post=855"}],"version-history":[{"count":4,"href":"https:\/\/www.ludovicocaldara.net\/dba\/wp-json\/wp\/v2\/posts\/855\/revisions"}],"predecessor-version":[{"id":859,"href":"https:\/\/www.ludovicocaldara.net\/dba\/wp-json\/wp\/v2\/posts\/855\/revisions\/859"}],"wp:attachment":[{"href":"https:\/\/www.ludovicocaldara.net\/dba\/wp-json\/wp\/v2\/media?parent=855"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ludovicocaldara.net\/dba\/wp-json\/wp\/v2\/categories?post=855"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ludovicocaldara.net\/dba\/wp-json\/wp\/v2\/tags?post=855"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}