{"id":3011,"date":"2021-03-22T08:54:00","date_gmt":"2021-03-22T08:54:00","guid":{"rendered":"https:\/\/swiv.com.br\/starting-and-stoping-data-guard-redo-apply-using-sql-plus\/"},"modified":"2026-05-27T20:02:50","modified_gmt":"2026-05-27T19:02:50","slug":"starting-and-stoping-data-guard-redo-apply-using-sql-plus","status":"publish","type":"post","link":"https:\/\/swiv.com.br\/index.php\/2021\/03\/22\/starting-and-stoping-data-guard-redo-apply-using-sql-plus\/","title":{"rendered":"Starting and Stoping Data Guard Redo Apply using SQL *Plus"},"content":{"rendered":"\n<p>Para inicializar o Redo Apply como &#8220;foreground session&#8221;, basta dispararmos o comando abaixo no ambiente Standby:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n&#x5B;oracle@fornix2 ~]$ sqlplus \/ as sysdba\n \nSQL*Plus: Release 19.0.0.0.0 - Production on Mon Mar 22 05:40:47 2021\nVersion 19.3.0.0.0\n \nCopyright (c) 1982, 2019, Oracle.  All rights reserved.\n \n \nConnected to:\nOracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production\nVersion 19.3.0.0.0\n \nSQL&gt; SELECT INSTANCE_NAME,STATUS FROM V$INSTANCE;\n \nINSTANCE_NAME    STATUS\n---------------- ------------\nCORTEXDR         MOUNTED\n \nSQL&gt; ALTER DATABASE RECOVER MANAGED STANDBY DATABASE;\n<\/pre><\/div>\n\n\n<p>Ao realizar um ctrl+c, \u00e9 poss\u00edvel notar que o redo apply foi parado, por conta de termos o inicializado como foreground session:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n^CALTER DATABASE RECOVER MANAGED STANDBY DATABASE\n*\nERROR at line 1:\nORA-16043: Redo apply has been canceled.\nORA-01013: user requested cancel of current operation\n<\/pre><\/div>\n\n\n<p>Para inicializarmos o redo apply como background session (que \u00e9 o mais comum), basta rodar o seguinte comando no standby:<\/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 DATABASE RECOVER MANAGED STANDBY DATABASE DISCONNECT;\n \nDatabase altered.\n<\/pre><\/div>\n\n\n<p>Parando o redo apply com o comando abaixo no standby:<\/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 DATABASE RECOVER MANAGED STANDBY DATABASE CANCEL;\n \nDatabase altered.\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>Para inicializar o Redo Apply como &#8220;foreground session&#8221;, basta dispararmos o comando abaixo no ambiente Standby: Ao realizar um ctrl+c, \u00e9 poss\u00edvel notar que o redo apply foi parado, por conta de termos o inicializado como foreground session: Para inicializarmos o redo apply como background session (que \u00e9 o mais comum), basta rodar o seguinte [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[],"class_list":["post-3011","post","type-post","status-publish","format-standard","hentry","category-high-availability"],"_links":{"self":[{"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts\/3011","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=3011"}],"version-history":[{"count":1,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts\/3011\/revisions"}],"predecessor-version":[{"id":9212,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts\/3011\/revisions\/9212"}],"wp:attachment":[{"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/media?parent=3011"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/categories?post=3011"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/tags?post=3011"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}