{"id":2311,"date":"2019-05-12T04:31:05","date_gmt":"2019-05-12T07:31:05","guid":{"rendered":"https:\/\/zmsolution.laraclaud.com.br\/?p=2311"},"modified":"2019-05-12T04:31:05","modified_gmt":"2019-05-12T07:31:05","slug":"rman-20020-database-incarnation-not-set","status":"publish","type":"post","link":"http:\/\/zmsolution.com\/rman-20020-database-incarnation-not-set\/","title":{"rendered":"RMAN-20020: database incarnation not set"},"content":{"rendered":"
Quando tentamos fazer a ressincroniza\u00e7\u00e3o do cat\u00e1logo com o banco de dados de destino, se recebermos a menssagem RMAN-20020: database incarnation not set,<\/strong> ent\u00e3o temos que redefinir o banco de dados para definir a encarna\u00e7\u00e3o para o atual.<\/p>\n<\/div>\n <\/p>\n<\/div>\n Quando tentamos fazer a ressincroniza\u00e7\u00e3o do cat\u00e1logo com o banco de dados de destino, se recebermos a menssagem RMAN-20020: database incarnation not set, ent\u00e3o temos que redefinir o banco de dados para definir a encarna\u00e7\u00e3o para o atual. \u00a0 Step 1 connect to\u00a0 rman and connect to the target database with recovery catalog rman Recovery Manager: Release 11.2.0.4.0 – Production\u00a0 Copyright (c) 1982, 2011, Oracle and\/or its affiliates.\u00a0 All rights reserved. \u00a0 connect target \/[…]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_mi_skip_tracking":false,"_exactmetrics_sitenote_active":false,"_exactmetrics_sitenote_note":"","_exactmetrics_sitenote_category":0},"categories":[21,1],"tags":[],"jetpack_featured_media_url":"","_links":{"self":[{"href":"http:\/\/zmsolution.com\/wp-json\/wp\/v2\/posts\/2311"}],"collection":[{"href":"http:\/\/zmsolution.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/zmsolution.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/zmsolution.com\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/zmsolution.com\/wp-json\/wp\/v2\/comments?post=2311"}],"version-history":[{"count":0,"href":"http:\/\/zmsolution.com\/wp-json\/wp\/v2\/posts\/2311\/revisions"}],"wp:attachment":[{"href":"http:\/\/zmsolution.com\/wp-json\/wp\/v2\/media?parent=2311"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/zmsolution.com\/wp-json\/wp\/v2\/categories?post=2311"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/zmsolution.com\/wp-json\/wp\/v2\/tags?post=2311"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}\u00a0<\/code><\/div>\n
Step 1\r\nconnect to\u00a0 rman and connect to the target database with recovery catalog\r\nrman\r\nRecovery Manager: Release 11.2.0.4.0 - Production\u00a0\r\nCopyright (c) 1982, 2011, Oracle and\/or its affiliates.\u00a0 All rights reserved.\r\n\u00a0\r\nconnect target \/\r\nconnected to target database: <SID> (DBID=<database_id>)\r\n\u00a0\r\nconnect catalog rman\/<password>@<catalog database service name>\r\nconnected to recovery catalog database\r\n\r\nStep2\r\n\r\nRMAN> resync catalog\r\n2> ;\r\nRMAN-00571: ===========================================================\r\nRMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============\r\nRMAN-00571: ===========================================================\r\nRMAN-03009: failure of resync command on default channel at 05\/14\/2013 13:36:02\r\nRMAN-20020: database incarnation not set\r\n\r\nRMAN> backup datafile <file_number>;\r\nStarting backup at 14-MAY-13\r\nRMAN-00571: ===========================================================\r\nRMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============\r\nRMAN-00571: ===========================================================\r\nRMAN-03002: failure of backup command at 05\/14\/2013 13:37:14\r\nRMAN-03014: implicit resync of recovery catalog failed\r\nRMAN-06004: ORACLE error from recovery catalog database: RMAN-20020: database incarnation not set\r\n\r\nStep 3\r\nonce you got the incarnation not set check the list of incarnation the database has\r\n\r\n\u00a0list incarnation ;\r\nList of Database Incarnations\r\nDB Key\u00a0 Inc Key DB Name\u00a0 DB ID\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 STATUS\u00a0 Reset SCN\u00a0 Reset Time\r\n------- ------- -------- ---------------- --- ---------- ----------\r\n29\u00a0\u00a0\u00a0\u00a0\u00a0 360\u00a0 \u00a0 \u00a0ZMDB\u00a0\u00a0\u00a0 728861074\u00a0 \u00a0 \u00a0 \u00a0 PARENT\u00a0 1\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 05-MAR-18\r\n29\u00a0\u00a0\u00a0\u00a0\u00a0 361\u00a0 \u00a0 ZMDB\u00a0 \u00a0 728861074 \u00a0 \u00a0 \u00a0 PARENT\u00a0 14640435\u00a0\u00a0 08-JUN-18\r\n29\u00a0\u00a0\u00a0\u00a0\u00a0 98\u00a0 \u00a0 \u00a0 ZMDB \u00a0 728861074 \u00a0 \u00a0 \u00a0 \u00a0PARENT\u00a0 14882874888 22-JUN-18\r\n29\u00a0\u00a0\u00a0\u00a0\u00a0 30\u00a0 \u00a0 \u00a0 ZMDB \u00a0 728861074 \u00a0 \u00a0 \u00a0 \u00a0ORPHAN\u00a0 15574861795 11-JUL-18\r\n29\u00a0\u00a0\u00a0\u00a0\u00a0 321\u00a0 \u00a0 ZMDB\u00a0 \u00a0 728861074 \u00a0 \u00a0 \u00a0 CURRENT 15996977185 22-AUG-18\r\n\r\n\r\nSQL> select * from v$controlfile_record_section where TYPE ='DATABASE INCARNATION';\r\n\r\nTYPE\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 RECORD_SIZE RECORDS_TOTAL RECORDS_USED FIRST_INDEX LAST_INDEX LAST_RECID\r\n---------------------------- ----------- ------------- ------------ ----------- ---------- ----------\r\nDATABASE INCARNATION\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 56\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 292\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 4\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 1\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 4\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 4\r\n\r\nwe can check the no of database incarnations in the database control file ...\r\n\r\nStep 4\r\nTo sync the incarnation number with the catalog issue the Reset the database\u00a0 command in the rman\u00a0\r\nand test the backup\r\n\r\nRMAN> reset database;\r\n\r\ndatabase incarnation already registered\r\n\r\nRMAN> backup datafile 3;\r\nStarting backup at 14-MAY-13\r\nallocated channel: ORA_DISK_1\r\nchannel ORA_DISK_1: SID=4256 device type=DISK\r\nchannel ORA_DISK_1: starting full datafile backup set\r\nchannel ORA_DISK_1: specifying datafile(s) in backup set\r\ninput datafile file number=00003 name=+DATA\/fahdb\/datafile\/<datafile_number>\r\nchannel ORA_DISK_1: starting piece 1 at 14-MAY-13\r\nchannel ORA_DISK_1: finished piece 1 at 14-MAY-13\r\npiece handle=+FLASH\/fahdb\/backupset\/2013_05_14\/nnndf0_tag20130514t135843_0.282.815407125 tag=TAG20130514T135843 comment=NONE\r\nchannel ORA_DISK_1: backup set complete, elapsed time: 00:00:07\r\nFinished backup at 14-MAY-13\r\nStarting Control File and SPFILE Autobackup at 14-MAY-13\r\npiece handle=+FLASH\/fahdb\/autobackup\/2013_05_14\/s_815407132.326.815407133 comment=NONE\r\nFinished Control File and SPFILE Autobackup at 14-MAY-13\r\n\r\nRMAN> resync catalog\u00a0;\r\nstarting full resync of recovery catalog\r\nfull resync complete\r\n\u00a0\r\n<\/pre>\n