{"id":952,"date":"2014-01-06T15:43:21","date_gmt":"2014-01-06T12:43:21","guid":{"rendered":"http:\/\/www.fatihacar.com\/blog\/?p=952"},"modified":"2014-01-06T15:45:01","modified_gmt":"2014-01-06T12:45:01","slug":"restore-and-recover-oracle-11g-r2-database-on-windows-2008-r2-server","status":"publish","type":"post","link":"http:\/\/www.fatihacar.com\/blog\/restore-and-recover-oracle-11g-r2-database-on-windows-2008-r2-server\/","title":{"rendered":"Restore And Recover Oracle 11g R2 Database on Windows 2008 R2 Server"},"content":{"rendered":"<p>You can restore and recover Oracle 11g R2 Database from RMAN backup on Windows 2008 R2 Server with below operations. You have to execute Command Prompt as Administrator for all operations.<\/p>\n<p><strong>Restore and Recover Database<\/strong><\/p>\n<blockquote><p>Install Oracle software<br \/>\nInstall Patch<\/p>\n<p>Create ORACLE_HOME and ORACLE_SID in Server Environment Path.<\/p>\n<p>Copy backup files to C:\\orabackup<\/p>\n<p>Create Oracle service with below command<\/p>\n<p>cmd> oradim -NEW -SID YOURDBSID -STARTMODE manual -PFILE &#8220;$ORACLE_HOME\\dbs\\init.ora&#8221;<\/p>\n<p>cmd> rman target \/<\/p>\n<p>RMAN> set dbid=12412312   <strong>Note :<\/strong> DBID writes in Control File backup name, if you use %F file name parameter.<\/p>\n<p>RMAN> startup nomount force;<\/p>\n<p>RMAN> restore spfile from &#8216;C:\\orabackup\\controlfilebackupfile&#8217;;<\/p>\n<p>RMAN> exit;<\/p>\n<p>cmd> sqlplus \/ as sysdba<\/p>\n<p>SQL> create pfile=&#8217;C:\\orabackup\\pfile.ora&#8217; from spfile;<\/p>\n<p>You have to create archivelog directory and other directories in pfile.ora. You have to copy archivelog file to archivelog directory.<\/p>\n<p>SQL> create spfile from pfile=&#8217;C:\\orabackup\\pfile.ora&#8217;;<\/p>\n<p>SQL> shu abort;<\/p>\n<p>SQL> startup nomount;<\/p>\n<p>cmd> rman target \/<\/p>\n<p>RMAN> restore controlfile from &#8216;C:\\orabackup\\controlfilebackupfile&#8217;;<\/p>\n<p>Control files restored to directories that are in pfile.ora<\/p>\n<p>SQL> alter database mount;<\/p>\n<p>If you use parallel backup to take backup, you can select backups like below.<\/p>\n<p>RMAN> catalog backuppiece &#8216;C:\\orabackup\\backupfile1.bck&#8217;,&#8217;C:\\orabackup\\backupfile2.bck&#8217;;<\/p>\n<p>RMAN> list backup;<\/p>\n<p>You have to create directory for datafiles. Directories show in list backup;<\/p>\n<p>RMAN> restore database;<\/p>\n<p>RMAN> recover database;<\/p>\n<p>RMAN> alter database open resetlogs;<\/p>\n<p>ORA-00392 log 3 of thread 1 is being cleared, operation not allowed<br \/>\nORA-00312 online log 3 thread 1: &#8216;path&#8217;<\/p>\n<p>If you get above error, you have to create path that writes in error. You get error because system can not create directory for redo logs.<br \/>\nYou have to execute below SQL to clear logfile, you can open database.<\/p>\n<p>SQL> alter database clear unarchived logfile group 3;<\/p>\n<p>SQL> alter database open resetlogs;<\/p>\n<p>SQL> select status from v$instance;<\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>You can restore and recover Oracle 11g R2 Database from RMAN backup on Windows 2008 R2 Server with below operations. You have to execute Command Prompt as Administrator for all operations. Restore and Recover Database Install Oracle software Install Patch Create ORACLE_HOME and ORACLE_SID in Server Environment Path. Copy backup files to C:\\orabackup Create Oracle&#8230;<\/p>\n","protected":false},"author":37,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[9,20,53],"tags":[23,14,90,32,49,48],"class_list":["post-952","post","type-post","status-publish","format-standard","hentry","category-administration","category-oracle-backup-and-recovery","category-oracle-errors-and-solutions","tag-backup-and-recovery-2","tag-database-administration","tag-oracle","tag-oracle-administration","tag-oracle-backup-and-restore","tag-oracle-rman-backup"],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p39NFI-fm","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"http:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/posts\/952","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/users\/37"}],"replies":[{"embeddable":true,"href":"http:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/comments?post=952"}],"version-history":[{"count":3,"href":"http:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/posts\/952\/revisions"}],"predecessor-version":[{"id":955,"href":"http:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/posts\/952\/revisions\/955"}],"wp:attachment":[{"href":"http:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/media?parent=952"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/categories?post=952"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/tags?post=952"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}