{"id":1521,"date":"2018-04-27T17:25:14","date_gmt":"2018-04-27T15:25:14","guid":{"rendered":"http:\/\/www.ora-solutions.net\/web\/?p=1521"},"modified":"2018-04-27T17:25:14","modified_gmt":"2018-04-27T15:25:14","slug":"baas-battle-against-archiver-stuck-alternate-archive-location","status":"publish","type":"post","link":"https:\/\/www.ora-solutions.net\/web\/2018\/04\/27\/baas-battle-against-archiver-stuck-alternate-archive-location\/","title":{"rendered":"BAAS: Battle Against Archiver Stuck &#8211; ALTERNATE Archive Location"},"content":{"rendered":"<p>If you are managing volatile systems, you might have encountered Archiver-Stuck in the past.<\/p>\n<pre lang=\"java\" line=\"1\">0RA-00257:archiver error, connect internal only until freed\r\nORA-16014:log 2 sequence# 1789 not archived, no available destinations<\/pre>\n<p>If this is the case, you might be interested in a rarely used feature called &#8220;ALTERNATE Archive Locations&#8221;. This is a second independent archive log destination, that is only used in case the primary destination is failing (full). In that case, the dest_2 is automatically enabled, preventing stuck database. As soon as the archivelog backup has cleaned up the full DEST_1 destination, there is an AUTOMATIC FALLBACK to the DEST_1 destination. <\/p>\n<pre lang=\"java\" line=\"1\">\r\nALTER SYSTEM SET LOG_ARCHIVE_DEST_1='LOCATION=\/disk1 MANDATORY MAX_FAILURE=1 ALTERNATE=LOG_ARCHIVE_DEST_2';\r\nALTER SYSTEM SET LOG_ARCHIVE_DEST_STATE_1=ENABLE;\r\nALTER SYSTEM SET LOG_ARCHIVE_DEST_STATE_2=ALTERNATE;\r\nALTER SYSTEM SET LOG_ARCHIVE_DEST_2='LOCATION=\/disk2 MANDATORY ALTERNATE=LOG_ARCHIVE_DEST_1';\r\n<\/pre>\n<p>Testing:<\/p>\n<pre lang=\"java\" line=\"1\">\r\nThread 1 advanced to log sequence 174 (LGWR switch)\r\n  Current log# 3 seq# 174 mem# 0: \/u01\/app\/oracle\/oradata\/CDB122\/redo03.log\r\n2018-04-27T17:18:47.685736+02:00\r\nARC3: Encountered disk I\/O error 19502\r\n2018-04-27T17:18:47.685800+02:00\r\nARC3: Closing local archive destination LOG_ARCHIVE_DEST_1 '\/disk1\/1_173_971869447.dbf' (error 19502) (CDB122)\r\n2018-04-27T17:18:47.687074+02:00\r\nErrors in file \/u01\/app\/oracle\/diag\/rdbms\/cdb122\/CDB122\/trace\/CDB122_arc3_31260.trc:\r\nORA-27072: File I\/O error\r\nAdditional information: 4\r\nAdditional information: 65536\r\nAdditional information: 315392\r\nORA-19502: write error on file \"\/disk1\/1_173_971869447.dbf\", block number 65536 (block size=512)\r\n2018-04-27T17:18:47.816938+02:00\r\nErrors in file \/u01\/app\/oracle\/diag\/rdbms\/cdb122\/CDB122\/trace\/CDB122_arc3_31260.trc:\r\nORA-19502: write error on file \"\/disk1\/1_173_971869447.dbf\", block number 65536 (block size=512)\r\nORA-27072: File I\/O error\r\nAdditional information: 4\r\nAdditional information: 65536\r\nAdditional information: 315392\r\nORA-19502: write error on file \"\/disk1\/1_173_971869447.dbf\", block number 65536 (block size=512)\r\nARC3: I\/O error 19502 archiving log 2 to '\/disk1\/1_173_971869447.dbf'\r\n<\/pre>\n<p>After the error, archivelogs are placed in \/dir2 directory and as soon as space is available again, archive destination is switched back to \/dir1 automatically.<\/p>\n<p>Archiver Stuck never again, right?<\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you are managing volatile systems, you might have encountered Archiver-Stuck in the past. 0RA-00257:archiver error, connect internal only until freed ORA-16014:log 2 sequence# 1789 not archived, no available destinations If this is the case, you might be interested in a rarely used feature called &#8220;ALTERNATE Archive Locations&#8221;. This is a second independent archive log [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[13,14,57,58,61,5],"tags":[],"class_list":["post-1521","post","type-post","status-publish","format-standard","hentry","category-10g","category-11g","category-11gr2","category-12c","category-12cr2","category-oracle-database"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.ora-solutions.net\/web\/wp-json\/wp\/v2\/posts\/1521","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.ora-solutions.net\/web\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ora-solutions.net\/web\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ora-solutions.net\/web\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ora-solutions.net\/web\/wp-json\/wp\/v2\/comments?post=1521"}],"version-history":[{"count":3,"href":"https:\/\/www.ora-solutions.net\/web\/wp-json\/wp\/v2\/posts\/1521\/revisions"}],"predecessor-version":[{"id":1524,"href":"https:\/\/www.ora-solutions.net\/web\/wp-json\/wp\/v2\/posts\/1521\/revisions\/1524"}],"wp:attachment":[{"href":"https:\/\/www.ora-solutions.net\/web\/wp-json\/wp\/v2\/media?parent=1521"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ora-solutions.net\/web\/wp-json\/wp\/v2\/categories?post=1521"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ora-solutions.net\/web\/wp-json\/wp\/v2\/tags?post=1521"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}