{"id":2785,"date":"2021-03-17T09:02:37","date_gmt":"2021-03-17T09:02:37","guid":{"rendered":"https:\/\/swiv.com.br\/creating-a-new-pdb-by-cloning-a-remote-pdb\/"},"modified":"2026-05-27T20:02:50","modified_gmt":"2026-05-27T19:02:50","slug":"creating-a-new-pdb-by-cloning-a-remote-pdb","status":"publish","type":"post","link":"https:\/\/swiv.com.br\/index.php\/2021\/03\/17\/creating-a-new-pdb-by-cloning-a-remote-pdb\/","title":{"rendered":"Creating a new PDB by cloning a REMOTE PDB"},"content":{"rendered":"\n<p>\u00c9 poss\u00edvel criarmos um novo PDB usando como origem um PDB de forma remota, com DB_LINK. Para simular este recurso, vou criar um DB_LINK apontando para o meu CDB$ROOT:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nSQL&gt; SHO CON_NAME CON_ID\n \nCON_NAME\n------------------------------\nCDB$ROOT\n \nCON_ID\n------------------------------\n1\nSQL&gt; CREATE DATABASE LINK ROOT_DBLINK CONNECT TO system IDENTIFIED BY oracle USING &#039;TALAMO&#039;;\n \nDatabase link created.\n<\/pre><\/div>\n\n\n<p>Testando o DB_LINK:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nSQL&gt; SELECT * FROM DUAL@ROOT_DBLINK;\n \nD\n-\nX\n<\/pre><\/div>\n\n\n<p>Criando o novo PDB:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nSQL&gt; CREATE PLUGGABLE DATABASE HIPOFISE4 FROM HIPOFISE3@ROOT_DBLINK;\n \nPluggable database created.\n<\/pre><\/div>\n\n\n<p>Abrindo o novo PDB:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nSQL&gt; ALTER PLUGGABLE DATABASE HIPOFISE4 OPEN;\n \nPluggable database altered.\n<\/pre><\/div>\n\n\n<p>Realizando teste de conex\u00e3o:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nSQL&gt; CONN sys\/oracle@oel8.localdomain:1521\/HIPOFISE4.localdomain as SYSDBA\nConnected.\nSQL&gt; SHOW CON_NAME CON_ID;\n \nCON_NAME\n------------------------------\nHIPOFISE4\n \nCON_ID\n------------------------------\n7\n<\/pre><\/div>\n\n\n<p>Obs: Este procedimento foi criado pelo senhor Ahmed Baraka (www.ahmedbaraka.com) e foi apenas reproduzido por mim em um laborat\u00f3rio pessoal para fins de aprendizado.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u00c9 poss\u00edvel criarmos um novo PDB usando como origem um PDB de forma remota, com DB_LINK. Para simular este recurso, vou criar um DB_LINK apontando para o meu CDB$ROOT: Testando o DB_LINK: Criando o novo PDB: Abrindo o novo PDB: Realizando teste de conex\u00e3o: Obs: Este procedimento foi criado pelo senhor Ahmed Baraka (www.ahmedbaraka.com) e [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[],"class_list":["post-2785","post","type-post","status-publish","format-standard","hentry","category-multitenant"],"_links":{"self":[{"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts\/2785","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/comments?post=2785"}],"version-history":[{"count":1,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts\/2785\/revisions"}],"predecessor-version":[{"id":9223,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts\/2785\/revisions\/9223"}],"wp:attachment":[{"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/media?parent=2785"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/categories?post=2785"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/tags?post=2785"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}