{"id":1432,"date":"2015-04-09T15:56:10","date_gmt":"2015-04-09T18:56:10","guid":{"rendered":"http:\/\/www.dbarj.com.br\/?p=1432"},"modified":"2015-04-09T16:15:03","modified_gmt":"2015-04-09T19:15:03","slug":"oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey","status":"publish","type":"post","link":"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/","title":{"rendered":"Oracle Data Guard error &#8211; Force closing the keystore for standby rekey."},"content":{"rendered":"<p>I have a Primary 11g Oracle Database with a single\u00a0<strong>Physical Standby<\/strong>. Those days I tried to create an encrypted column inside one table for testing purposes.<\/p>\n<p>I end up accidentally messing the things:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">Force closing the keystore for standby rekey.\r\nPlease re-copy the keystore from primary before re-open as needed.\r\nApply redo for database master key re-key failed: new master key does not exist in the keystore\r\nMRP0: Background Media Recovery terminated with error 28374\r\nErrors in file \/u02\/diag\/rdbms\/dwqual02\/dwqual02\/trace\/dwqual02_pr00_37644.trc:\r\nORA-28374: typed master key not found in wallet\r\nManaged Standby Recovery not using Real Time Apply\r\nRecovery interrupted!\r\nRecovered data files to a consistent state at change 13453232993830<\/pre>\n<p>My\u00a0standby DB stopped receiving the redo logs because of one single encrypted column created!<\/p>\n<p>The problem is that the <strong>Wallet<\/strong> was configured in my Primary DB only, not in the STBY. So, I proceeded with the creation of it in the STBY DB.<\/p>\n<p>First, check you <strong>sqlnet.ora<\/strong> file to see if you are using an especific Wallet\u00a0for the encryptions (the encryption wallet\u00a0must be shared across the DG instances):<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"shell\">[oracle@blqa09bddsne001 admin]$ cat sqlnet.ora\r\nSQLNET.WALLET_OVERRIDE = TRUE\r\n\r\nWALLET_LOCATION =\r\n  (SOURCE =\r\n    (METHOD = FILE)\r\n    (METHOD_DATA =\r\n      (DIRECTORY = \/u01\/app\/oracle\/wallet\/normal)\r\n    )\r\n  )\r\n\r\nENCRYPTION_WALLET_LOCATION =\r\n  (SOURCE =\r\n    (METHOD = FILE)\r\n    (METHOD_DATA =\r\n      (DIRECTORY = \/u01\/app\/oracle\/wallet\/encrypt)\r\n    )\r\n  )\r\n[oracle@blqa09bddsne001 admin]$\r\n<\/pre>\n<p>As you can see, in my case I have one Wallet only for DB Encryption and another Wallet for other tasks (like EUS-OUD connection integration).<\/p>\n<p>If you just have the &#8220;WALLET_LOCATION&#8221; or if you don&#8217;t have anything setup, then Oracle will use a single Wallet for everything. In that case, go to the default folder for Wallet (probably\u00a0<em>$ORACLE_BASE\/admin\/$ORACLE_SID\/wallet<\/em>).<\/p>\n<p>You can also check where the wallet is querying in your primary instance:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"oracledb\">SQL&gt; set lines 1000\r\nSQL&gt; format col WRL_PARAMETER a40\r\nSQL&gt; select * from v$encryption_wallet;\r\n\r\nWRL_TYPE             WRL_PARAMETER                            STATUS\r\n-------------------- ---------------------------------------- ------------------\r\nfile                 \/u01\/app\/oracle\/wallet\/encrypt           OPEN\r\n\r\nSQL&gt;<\/pre>\n<p>All you need now is to copy (<strong>scp<\/strong>) the encryption wallet (or the default wallet if you are <span style=\"text-decoration: underline;\"><strong>not<\/strong><\/span> using &#8220;ENCRYPTION_WALLET_LOCATION&#8221;) from your primary to your standby database.<\/p>\n<p>Don&#8217;t forget to place it in the default directory or in the directory pointed by your <strong>sqlnet.ora<\/strong> file, if the entry is there.<\/p>\n<p>After that, force the Oracle to close the Wallet running\u00a0&#8220;<em>ALTER SYSTEM SET ENCRYPTION WALLET CLOSE;<\/em>&#8221; and then restart your apply process. Or just bounce your standby instance.<\/p>\n<p>Great, your Data Guard may now be finally shipping redo logs again!<\/p>\n<b>Have you enjoyed? Please leave a comment or give a \ud83d\udc4d!<\/b>\n<p>&nbsp;<\/p>\n<div class='watch-action'><div class='watch-position align-left'><div class='action-like'><a class='lbg-style2 like-1432 jlk' href='javascript:void(0)' data-task='like' data-post_id='1432' data-nonce='de4404f630' rel='nofollow'><img class='wti-pixel' src='https:\/\/www.dbarj.com.br\/wp-content\/plugins\/wti-like-post\/images\/pixel.gif' title='Like' \/><span class='lc-1432 lc'>+5<\/span><\/a><\/div><\/div> <div class='status-1432 status align-left'><\/div><\/div><div class='wti-clear'><\/div>","protected":false},"excerpt":{"rendered":"<p>I have a Primary 11g Oracle Database with a single\u00a0Physical Standby. Those days I tried to create an encrypted column inside one table for testing purposes. I end up accidentally messing the things: Force closing the keystore for standby rekey. Please re-copy the keystore from primary before re-open as needed. Apply redo for database master &hellip; <\/p>\n<p><a class=\"more-link btn\" href=\"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/\">Continue reading<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[30],"tags":[],"class_list":["post-1432","post","type-post","status-publish","format-standard","hentry","category-data-guard-en","item-wrap"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Oracle Data Guard error - Force closing the keystore for standby rekey. - DBA - Rodrigo Jorge - Oracle Tips and Guides<\/title>\n<meta name=\"description\" content=\"How to solve Data Guard standby wallet key problem.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"DBA RJ\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/2015\\\/04\\\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/2015\\\/04\\\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\\\/\"},\"author\":{\"name\":\"DBA RJ\",\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/#\\\/schema\\\/person\\\/28a44ca3a6633fe4156ad1ea209d40a9\"},\"headline\":\"Oracle Data Guard error &#8211; Force closing the keystore for standby rekey.\",\"datePublished\":\"2015-04-09T18:56:10+00:00\",\"dateModified\":\"2015-04-09T19:15:03+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/2015\\\/04\\\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\\\/\"},\"wordCount\":297,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/#\\\/schema\\\/person\\\/28a44ca3a6633fe4156ad1ea209d40a9\"},\"articleSection\":[\"Data Guard\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/2015\\\/04\\\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/2015\\\/04\\\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\\\/\",\"url\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/2015\\\/04\\\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\\\/\",\"name\":\"Oracle Data Guard error - Force closing the keystore for standby rekey. - DBA - Rodrigo Jorge - Oracle Tips and Guides\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/#website\"},\"datePublished\":\"2015-04-09T18:56:10+00:00\",\"dateModified\":\"2015-04-09T19:15:03+00:00\",\"description\":\"How to solve Data Guard standby wallet key problem.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/2015\\\/04\\\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/2015\\\/04\\\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/2015\\\/04\\\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Oracle Data Guard error - Force closing the keystore for standby rekey.\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/#website\",\"url\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/\",\"name\":\"DBA - Rodrigo Jorge - Oracle Tips and Guides\",\"description\":\"Blog about Databases, Security and High Availability\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/#\\\/schema\\\/person\\\/28a44ca3a6633fe4156ad1ea209d40a9\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/en\\\/#\\\/schema\\\/person\\\/28a44ca3a6633fe4156ad1ea209d40a9\",\"name\":\"DBA RJ\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/wp-content\\\/uploads\\\/2019\\\/09\\\/RodrigoJorgePOUG19.png\",\"url\":\"https:\\\/\\\/www.dbarj.com.br\\\/wp-content\\\/uploads\\\/2019\\\/09\\\/RodrigoJorgePOUG19.png\",\"contentUrl\":\"https:\\\/\\\/www.dbarj.com.br\\\/wp-content\\\/uploads\\\/2019\\\/09\\\/RodrigoJorgePOUG19.png\",\"width\":712,\"height\":712,\"caption\":\"DBA RJ\"},\"logo\":{\"@id\":\"https:\\\/\\\/www.dbarj.com.br\\\/wp-content\\\/uploads\\\/2019\\\/09\\\/RodrigoJorgePOUG19.png\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Oracle Data Guard error - Force closing the keystore for standby rekey. - DBA - Rodrigo Jorge - Oracle Tips and Guides","description":"How to solve Data Guard standby wallet key problem.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/","twitter_misc":{"Written by":"DBA RJ","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/#article","isPartOf":{"@id":"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/"},"author":{"name":"DBA RJ","@id":"https:\/\/www.dbarj.com.br\/en\/#\/schema\/person\/28a44ca3a6633fe4156ad1ea209d40a9"},"headline":"Oracle Data Guard error &#8211; Force closing the keystore for standby rekey.","datePublished":"2015-04-09T18:56:10+00:00","dateModified":"2015-04-09T19:15:03+00:00","mainEntityOfPage":{"@id":"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/"},"wordCount":297,"commentCount":0,"publisher":{"@id":"https:\/\/www.dbarj.com.br\/en\/#\/schema\/person\/28a44ca3a6633fe4156ad1ea209d40a9"},"articleSection":["Data Guard"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/","url":"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/","name":"Oracle Data Guard error - Force closing the keystore for standby rekey. - DBA - Rodrigo Jorge - Oracle Tips and Guides","isPartOf":{"@id":"https:\/\/www.dbarj.com.br\/en\/#website"},"datePublished":"2015-04-09T18:56:10+00:00","dateModified":"2015-04-09T19:15:03+00:00","description":"How to solve Data Guard standby wallet key problem.","breadcrumb":{"@id":"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.dbarj.com.br\/en\/2015\/04\/oracle-data-guard-error-force-closing-the-keystore-for-standby-rekey\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.dbarj.com.br\/en\/"},{"@type":"ListItem","position":2,"name":"Oracle Data Guard error - Force closing the keystore for standby rekey."}]},{"@type":"WebSite","@id":"https:\/\/www.dbarj.com.br\/en\/#website","url":"https:\/\/www.dbarj.com.br\/en\/","name":"DBA - Rodrigo Jorge - Oracle Tips and Guides","description":"Blog about Databases, Security and High Availability","publisher":{"@id":"https:\/\/www.dbarj.com.br\/en\/#\/schema\/person\/28a44ca3a6633fe4156ad1ea209d40a9"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.dbarj.com.br\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/www.dbarj.com.br\/en\/#\/schema\/person\/28a44ca3a6633fe4156ad1ea209d40a9","name":"DBA RJ","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.dbarj.com.br\/wp-content\/uploads\/2019\/09\/RodrigoJorgePOUG19.png","url":"https:\/\/www.dbarj.com.br\/wp-content\/uploads\/2019\/09\/RodrigoJorgePOUG19.png","contentUrl":"https:\/\/www.dbarj.com.br\/wp-content\/uploads\/2019\/09\/RodrigoJorgePOUG19.png","width":712,"height":712,"caption":"DBA RJ"},"logo":{"@id":"https:\/\/www.dbarj.com.br\/wp-content\/uploads\/2019\/09\/RodrigoJorgePOUG19.png"}}]}},"_links":{"self":[{"href":"https:\/\/www.dbarj.com.br\/en\/wp-json\/wp\/v2\/posts\/1432","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dbarj.com.br\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dbarj.com.br\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dbarj.com.br\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dbarj.com.br\/en\/wp-json\/wp\/v2\/comments?post=1432"}],"version-history":[{"count":0,"href":"https:\/\/www.dbarj.com.br\/en\/wp-json\/wp\/v2\/posts\/1432\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.dbarj.com.br\/en\/wp-json\/wp\/v2\/media?parent=1432"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dbarj.com.br\/en\/wp-json\/wp\/v2\/categories?post=1432"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dbarj.com.br\/en\/wp-json\/wp\/v2\/tags?post=1432"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}