
{"id":7233,"date":"2021-05-14T19:32:38","date_gmt":"2021-05-14T19:32:38","guid":{"rendered":"https:\/\/rax-stg-wp-aws.com\/blogs\/alternate-archive-destinations-in-oracle\/"},"modified":"2026-11-03T19:28:16","modified_gmt":"2026-11-03T19:28:16","slug":"alternate-archive-destinations-in-oracle","status":"publish","type":"blogs","link":"https:\/\/www.rackspace.com\/en-gb\/blogs\/alternate-archive-destinations-in-oracle\/","title":{"rendered":"Alternate archive destinations in Oracle"},"content":{"rendered":"<p><strong>Introduction<\/strong><\/p>\n<p>Archiving Oracle databases lets you retain and store data for the long term, but what happens if you run out of space?<\/p>\n<p>If the archive destination fills up, your Oracle Database can hang or become stuck, and you might see one of the following errors:<br \/>\n&nbsp;<\/p>\n<p><em>&#8211; **0RA-00257**: Archiver error, connect internal only until freed<br \/>\n&#8211; **ORA-16014**: Log 2 sequence# 1934 not archived, no available destinations<\/em><\/p>\n<p>In this case, you need to have an alternate archiving destination to use when the original archive destination fails. You can leverage the alternate archive destination in the event of any failure (space, hardware, and so on) in the primary archive destination.<\/p>\n<p>Let&#8217;s go through a quick demonstration to understand how it works.<\/p>\n<p><strong>Demo part one<\/strong><\/p>\n<p>First, I set the primary archive destination to <strong>\/u03\/primary_dest location<\/strong>, which is currently 99% utilized. You can do the same thing as a test.<\/p>\n<p>Then, run the following commands:<\/p>\n<p>&nbsp; &nbsp; <em>SQL&gt; select version from v$instance;<\/em><\/p>\n<p>&nbsp; &nbsp; VERSION<br \/>\n&nbsp; &nbsp; &#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br \/>\n&nbsp; &nbsp; 12.1.0.2.0<\/p>\n<p><em>&nbsp; &nbsp; SQL&gt; select DEST_NAME,TARGET,DESTINATION,VALID_ROLE,STATUS&nbsp;<br \/>\n&nbsp; &nbsp; from v$archive_dest where status!=&#8217;INACTIVE&#8217;;<\/em><\/p>\n<p><em>&nbsp; &nbsp; DEST_NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; TARGET &nbsp; &nbsp; DESTINATION &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;VALID_ROLE &nbsp; STATUS<br \/>\n&nbsp; &nbsp; &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212; &#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;&#8212; &#8212;&#8212;&#8212;<br \/>\n&nbsp; &nbsp; LOG_ARCHIVE_DEST_1 &nbsp; &nbsp;PRIMARY &nbsp; &nbsp;\/u03\/primary_dest &nbsp; &nbsp; ALL_ROLES &nbsp; &nbsp;VALID<\/em><\/p>\n<p>&nbsp;<\/p>\n<p><strong>Demo part two<\/strong><\/p>\n<p>Let&#8217;s add an alternate archive destination **\/u04\/alternate_dest**, which the system can use if the primary destination is unavailable.<\/p>\n<p>&nbsp; <em>&nbsp; SQL&gt; !df -h \/u04\/alternate_dest<br \/>\n&nbsp; &nbsp; Filesystem &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Size &nbsp;Used Avail Use% Mounted on<br \/>\n&nbsp; &nbsp; \/dev\/ddg2 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1004M &nbsp; 18M&nbsp;<br \/>\n&nbsp; &nbsp; 936M &nbsp; 2% \/u04<\/em><\/p>\n<p><em>&nbsp; &nbsp; SQL&gt; alter system set log_archive_dest_2=&#8217;LOCATION=\/u04\/alternate_dest&#8217; scope=both;<\/em><\/p>\n<p>&nbsp; &nbsp; System altered.<\/p>\n<p>&nbsp; <em>&nbsp; SQL&gt; alter system set log_archive_dest_state_2=ALTERNATE scope=both;<\/em><\/p>\n<p>&nbsp; &nbsp; System altered.<\/p>\n<p>&nbsp; &nbsp;<em> SQL&gt; select DEST_NAME,TARGET,DESTINATION,VALID_ROLE,STATUS,ALTERNATE from v$archive_dest where status!=&#8217;INACTIVE&#8217;;<\/em><\/p>\n<p><em>&nbsp; &nbsp; DEST_NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; TARGET &nbsp; &nbsp; &nbsp;DESTINATION &nbsp; &nbsp; &nbsp; &nbsp; VALID_ROLE &nbsp; STATUS &nbsp; &nbsp; &nbsp;ALTERNATE<br \/>\n&nbsp; &nbsp; &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212; &#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;<br \/>\n&nbsp; &nbsp; LOG_ARCHIVE_DEST_1 &nbsp; PRIMARY &nbsp; &nbsp;\/u03\/primary_dest &nbsp; &nbsp;ALL_ROLES &nbsp; &nbsp;VALID &nbsp; &nbsp; &nbsp;NONE<br \/>\n&nbsp; &nbsp; LOG_ARCHIVE_DEST_2 &nbsp; PRIMARY &nbsp; &nbsp;\/u04\/alternate_dest &nbsp;ALL_ROLES &nbsp; &nbsp;ALTERNATE &nbsp;NONE<\/em><br \/>\n&nbsp;<\/p>\n<p><strong>Demo part three<\/strong><\/p>\n<p>You can link the primary and alternate archive destination, and Oracle can fail over to an alternate archive location when the primary location reaches 100% usage. However, Oracle cannot execute a failback to the primary destination after it is available again. For that to work, you need to set the primary archive destination,<br \/>\n<strong>LOG_ARCHIVE_DEST_1<\/strong>, as the <strong>ALTERNATE<\/strong>&nbsp;for the alternate archive destination,<br \/>\n<strong>LOG_ARCHIVE_DEST_2<\/strong>, as shown in the following example:<\/p>\n<p><em>&nbsp; SQL&gt; alter system set log_archive_dest_2=&#8217;LOCATION=\/u04\/alternate_dest&nbsp;<br \/>\n&nbsp; &nbsp; NOREOPEN ALTERNATE=LOG_ARCHIVE_DEST_1&#8242; scope=both;<\/em><\/p>\n<p>&nbsp; &nbsp; System altered.<\/p>\n<p>&nbsp; &nbsp; <em>SQL&gt; alter system set log_archive_dest_1=&#8217;LOCATION=\/u03\/primary_dest<br \/>\n&nbsp; &nbsp; NOREOPEN ALTERNATE=LOG_ARCHIVE_DEST_2&#8242; scope=both;<\/em><\/p>\n<p>&nbsp; &nbsp; System altered.<\/p>\n<p>&nbsp; <em>&nbsp; SQL&gt; select DEST_NAME,TARGET,DESTINATION,VALID_ROLE,STATUS,ALTERNATE<br \/>\n&nbsp; &nbsp; from v$archive_dest where status!=&#8217;INACTIVE&#8217;;<\/em><\/p>\n<p>&nbsp; &nbsp; <em>DEST_NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;TARGET &nbsp; &nbsp; &nbsp;DESTINATION &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;VALID_ROLE &nbsp; STATUS &nbsp; &nbsp; ALTERNATE<br \/>\n&nbsp; &nbsp; &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;&#8212; &#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br \/>\n&nbsp; &nbsp; LOG_ARCHIVE_DEST_1 &nbsp; PRIMARY &nbsp; &nbsp; \/u03\/primary_dest &nbsp; &nbsp; ALL_ROLES &nbsp; &nbsp;VALID &nbsp; &nbsp; LOG_ARCHIVE_DEST_2<br \/>\n&nbsp; &nbsp; LOG_ARCHIVE_DEST_2 &nbsp; PRIMARY &nbsp; &nbsp; \/u04\/alternate_dest &nbsp; ALL_ROLES &nbsp; &nbsp;ALTERNATE LOG_ARCHIVE_DEST_1<\/em><\/p>\n<p>You can check to confirm that you linked the archive destinations one and two. Oracle should now be able to fail back to the primary after the primary has free space.<\/p>\n<p><strong>Demo part four<\/strong><\/p>\n<p>Next, I executed some DMLs so that the archive destination hit 100% usage, as shown in the following output:<br \/>\n&nbsp;<\/p>\n<p><em>&nbsp;Thread 1 is advanced to log sequence 20 (LGWR switch)<br \/>\n&nbsp; &nbsp; &nbsp; Current log# 2 seq# 20 mem# 0: \/u01\/app\/oracle\/oradata\/MODI\/redo02.log<br \/>\n&nbsp; &nbsp; 2020-12-05T04:44:29.216275+05:30<br \/>\n&nbsp; &nbsp; ARC0: Encountered disk I\/O error 19502<br \/>\n&nbsp; &nbsp; 2020-12-05T04:44:29.216575+05:30<br \/>\n&nbsp; &nbsp; ARC0: Closing local archive destination LOG_ARCHIVE_DEST_1 &#8216;\/u03\/primary_dest\/1_19_1058325294.dbf&#8217; (error 19502) (MODI)<br \/>\n&nbsp; &nbsp; 2020-12-05T04:44:29.217417+05:30<br \/>\n&nbsp; &nbsp; Errors in file \/u01\/app\/oracle\/diag\/rdbms\/modi\/MODI\/trace\/MODI_arc0_23015.trc:<br \/>\n&nbsp; &nbsp; ORA-27072: File I\/O error<br \/>\n&nbsp; &nbsp; Additional information: 4<br \/>\n&nbsp; &nbsp; Additional information: 350208<br \/>\n&nbsp; &nbsp; Additional information: 446464<br \/>\n&nbsp; &nbsp; ORA-19502: write error on file &#8220;\/u03\/primary_dest\/1_19_1058325294.dbf&#8221;, block number 350208 (block size=512)<br \/>\n&nbsp; &nbsp; 2020-12-05T04:44:32.583182+05:30<br \/>\n&nbsp; &nbsp; MODIP(3):Resize operation completed for file# 11, old size 1172480K, new size 1182720K<br \/>\n&nbsp; &nbsp; 2020-12-05T04:44:33.183355+05:30<br \/>\n&nbsp; &nbsp; Errors in file \/u01\/app\/oracle\/diag\/rdbms\/modi\/MODI\/trace\/MODI_arc0_23015.trc:<br \/>\n&nbsp; &nbsp; ORA-19502: write error on file &#8220;\/u03\/primary_dest\/1_19_1058325294.dbf&#8221;, block number 350208 (block size=512)<br \/>\n&nbsp; &nbsp; ORA-27072: File I\/O error<br \/>\n&nbsp; &nbsp; Additional information: 4<br \/>\n&nbsp; &nbsp; Additional information: 350208<br \/>\n&nbsp; &nbsp; Additional information: 446464<br \/>\n&nbsp; &nbsp; ORA-19502: write error on file &#8220;\/u03\/primary_dest\/1_19_1058325294.dbf&#8221;, block number 350208 (block size=512)<\/em><\/p>\n<p><strong>Step five<\/strong><\/p>\n<p>Oracle always tries to archive to the primary destination, and the automatic failback to the primary destination works in version 12c. After you clean up the primary destination and make it available for archiving, Oracle continues to archiving the redo logs to the primary destination without reporting any errors or failback message in the alert log file, as shown in the following example where I queried <strong>v$archived_log<\/strong><\/p>\n<p><em>SQL&gt; &nbsp;select thread#,sequence#,name from v$archive_log;:<\/em><\/p>\n<p><em>&nbsp; THREAD# &nbsp;SEQUENCE# &nbsp;NAME<br \/>\n&nbsp; &nbsp; &#8212;&#8212;&#8211; &#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;2 \/u03\/primary_dest\/1_2_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;3 \/u03\/primary_dest\/1_3_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;4 \/u03\/primary_dest\/1_4_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;5 \/u03\/primary_dest\/1_5_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;6 \/u04\/alternate_dest\/1_6_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;7 \/u04\/alternate_dest\/1_7_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;8 \/u04\/alternate_dest\/1_8_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;9 \/u04\/alternate_dest\/1_9_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 10 \/u04\/alternate_dest\/1_10_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 11 \/u04\/alternate_dest\/1_11_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 12 \/u04\/alternate_dest\/1_12_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 13 \/u04\/alternate_dest\/1_13_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 14 \/u04\/alternate_dest\/1_14_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 15 \/u04\/alternate_dest\/1_15_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 16 \/u04\/alternate_dest\/1_16_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 17 \/u04\/alternate_dest\/1_17_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 18 \/u04\/alternate_dest\/1_18_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 19 \/u04\/alternate_dest\/1_19_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 20 \/u04\/alternate_dest\/1_20_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 21 \/u04\/alternate_dest\/1_21_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 22 \/u04\/alternate_dest\/1_22_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 23 \/u04\/alternate_dest\/1_23_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 24 \/u04\/alternate_dest\/1_24_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 25 \/u04\/alternate_dest\/1_25_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 26 \/u04\/alternate_dest\/1_26_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 27 \/u04\/alternate_dest\/1_27_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 28 \/u04\/alternate_dest\/1_28_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 29 \/u03\/primary_dest\/1_29_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 30 \/u03\/primary_dest\/1_30_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 31 \/u03\/primary_dest\/1_31_1058325294.dbf<br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;1 &nbsp; &nbsp; &nbsp; &nbsp; 32 \/u03\/primary_dest\/1_32_1058325294.dbf<\/em><\/p>\n<p>31 rows selected.<\/p>\n<p><strong>Conclusion<\/strong><\/p>\n<p>Oracle has made a significant improvement in the automatic management of archive destination switching between the primary and alternate destination. &nbsp;Hopefully, you can use my demonstration to take advantage of this functionality.<\/p>\n<p>Having an alternate archive serves you well, but remember that Oracle intermittently logs error messages in the alert log file about the primary destination failure until the primary archive destination is ready again.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Alternate archive destinations in Oracle<\/p>\n","protected":false},"author":2,"featured_media":7235,"menu_order":0,"comment_status":"open","ping_status":"open","template":"","format":"standard","meta":{"content-type":"","nid":"26326","content_type":"blog","created_by":"10130","authored_on":"2023-11-30T20:32:38+00:00","field_article_industries":"","tag_category":"Technical","field_blog_author_text":"by Jay Vardhan, Oracle Database Administrator, Rackspace Technology","seo_description":"Understand how to set up and leverage alternate archiving destinations in Oracle Databases for avoiding system hang-ups due to space constraints.\r\n","field_featured_image":"","insights_image":"\/wp-content\/uploads\/2026\/blog_technical_images\/26326-insights_image-oracle-technical-blog-1-insights.jpg","field_partners":"","rxt_platforms":"Oracle","product":"","publisheddate":"2021-05-14T19:32:38","rxt_solutions":"Databases","opengraph_tag":"","x_tag":"","teaser_flag":"Technical Blog","seo_titile":"Alternate Archive Destinations in Oracle | Rackspace Technology","field_topics":"","field_slug":"alternate-archive-destniations-in-oracle","footnotes":""},"categories":[178],"tags":[204],"class_list":["post-7233","blogs","type-blogs","status-publish","format-standard","has-post-thumbnail","hentry","category-blog","tag-technical"],"_links":{"self":[{"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/blogs\/7233","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/blogs"}],"about":[{"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/types\/blogs"}],"author":[{"embeddable":true,"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/comments?post=7233"}],"version-history":[{"count":1,"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/blogs\/7233\/revisions"}],"predecessor-version":[{"id":7234,"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/blogs\/7233\/revisions\/7234"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/media\/7235"}],"wp:attachment":[{"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/media?parent=7233"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/categories?post=7233"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.rackspace.com\/en-gb\/wp-json\/wp\/v2\/tags?post=7233"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}