1 2 3 Previous Next 39 Replies Latest reply: Jun 13, 2014 1:08 AM by Hemant K Chitale Go to original post RSS
      • 15. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
        KarthikSinghDBA

        While checking the alert logs

         

        ARCH: Archival disabled due to shutdown: 1089

        Shutting down archive processes

        Archiving is disabled

        ARCH: Archival disabled due to shutdown: 1089

        Shutting down archive processes

        Archiving is disabled

        NOTE: Shutting down MARK background process

        Stopping background process VKTM

        Tue Jun 10 08:40:49 2014

        Instance shutdown complete

         

        Current time:

        [oracle@host trace]$ date

        Tue Jun 10 09:47:19 EDT 2014

        • 16. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
          FreddieEssex

          You should be able to query the views once the instance was mounted although I can't check this to confirm at the moment.

           

          From your log above it looks like the database was in the mount stage?

           

          Is the backup still running?  Has the RMAN restore bombed out?

           

          Any errors in the alert log?

           

          From your new terminal did you properly set your environment variables like ORACLE_SID etc before logging into the database?

          • 17. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
            KarthikSinghDBA

            You should be able to query the views once the instance was mounted although I can't check this to confirm at the moment.

            Okay. I tried to query in another terminal session by setting oraenv and then connected with sqlplus / as sysdba but it shows as connected with an idle instance.

             

            From your log above it looks like the database was in the mount stage?

            Yes while starting the restore it was in nomount stage.

             

            Is the backup still running?  Has the RMAN restore bombed out?

            Yes it is still running/hangs at the same statement as previously said.

             

            Any errors in the alert log?

            No there is no errors. The above pasted lines are clean shutdown by rman.

             

            From your new terminal did you properly set your environment variables like ORACLE_SID etc before logging into the database?

            Yes.

            • 18. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
              FreddieEssex

              Something doesn't add up.

               

              Is your restore still running?

               

              The alert log looks like the database was shut cleanly and didn't terminate due to an error....is this alert log from prior to the restore when you shutdown your database?

               

              If you do "ps -ef | grep pmon" does this show the process for your TEST database?

              • 19. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                KarthikSinghDBA

                Something doesn't add up.

                 

                Is your restore still running?

                Yes. It still hangs at the same line.

                 

                The alert log looks like the database was shut cleanly and didn't terminate due to an error....is this alert log from prior to the restore when you shutdown your database?

                No. After the execution of Duplicate Database.

                 

                If you do "ps -ef | grep pmon" does this show the prcess for your TEST database?

                No.

                • 20. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                  KarthikSinghDBA

                  I think RMAN did a shutdown and startup the instance in mount stage but during the clone/memory script execution it still hangs.

                   

                  Starting restore at 10-JUN-14

                  allocated channel: ORA_AUX_DISK_1

                  channel ORA_AUX_DISK_1: SID=35 device type=DISK

                   

                   

                  channel ORA_AUX_DISK_1: restoring control file

                  channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:02

                  output file name=+DATA1/TEST/controlfile/current.297.848048479

                  Finished restore at 10-JUN-14

                   

                   

                  database mounted

                  released channel: ORA_AUX_DISK_1

                  allocated channel: ORA_AUX_DISK_1

                  channel ORA_AUX_DISK_1: SID=35 device type=DISK

                  Oracle instance started

                   

                   

                  Total System Global Area    2137886720 bytes

                   

                   

                  Fixed Size                     2230072 bytes

                  Variable Size               1610614984 bytes

                  Database Buffers             520093696 bytes

                  Redo Buffers                   4947968 bytes

                   

                   

                  contents of Memory Script:

                  {

                     sql clone "alter system set  db_name =

                  ''TEST'' comment=

                  ''Reset to original value by RMAN'' scope=spfile";

                     sql clone "alter system reset  db_unique_name scope=spfile";

                     shutdown clone immediate;

                  }

                  executing Memory Script

                   

                   

                  sql statement: alter system set  db_name =  ''TEST'' comment= ''Reset to ori

                   

                   

                  sql statement: alter system reset  db_unique_name scope=spfile

                  • 21. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                    KarthikSinghDBA

                    Part of Alert Log info:

                     

                    SUCCESS: diskgroup DATA1 was mounted

                    Tue Jun 10 08:39:38 2014

                    NOTE: dependency between database TEST and diskgroup resource ora.DATA1.dg is established

                    ALTER SYSTEM SET control_files='+DATA1/TEST/controlfile/current.297.848048479' COMMENT='Set by RMAN' SCOPE=SPFILE;

                    ALTER SYSTEM SET db_name='ORCL' COMMENT='Modified by RMAN duplicate' SCOPE=SPFILE;

                    ALTER SYSTEM SET db_unique_name='TEST' COMMENT='Modified by RMAN duplicate' SCOPE=SPFILE;

                    Shutting down instance (immediate)

                    Shutting down instance: further logons disabled

                    Stopping background process MMNL

                    Stopping background process MMON

                    License high water mark = 3

                    All dispatchers and shared servers shutdown

                    alter database close

                    ORA-1507 signalled during: alter database close...

                    alter database dismount

                    ORA-1507 signalled during: alter database dismount...

                    ARCH: Archival disabled due to shutdown: 1089

                    Shutting down archive processes

                    Archiving is disabled

                    ARCH: Archival disabled due to shutdown: 1089

                    Shutting down archive processes

                    Archiving is disabled

                    Tue Jun 10 08:39:42 2014

                    Stopping background process VKTM

                    Tue Jun 10 08:39:42 2014

                    NOTE: Shutting down MARK background process

                    Tue Jun 10 08:39:45 2014

                    Instance shutdown complete

                    Tue Jun 10 08:39:47 2014

                    Adjusting the default value of parameter parallel_max_servers

                    from 320 to 135 due to the value of parameter processes (150)

                    Starting ORACLE instance (normal)

                    Tue Jun 10 08:39:57 2014

                    LICENSE_MAX_SESSION = 0

                    LICENSE_SESSIONS_WARNING = 0

                    Picked latch-free SCN scheme 3

                    Using LOG_ARCHIVE_DEST_1 parameter default value as /u01/app/oracle/product/11.2.0/dbhome_1/dbs/arch

                    Autotune of undo retention is turned on.

                    IMODE=BR

                    ILAT =27

                    LICENSE_MAX_USERS = 0

                    SYS auditing is disabled

                    Starting up:

                    Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production

                    With the Partitioning, OLAP, Data Mining and Real Application Testing options.

                    ORACLE_HOME = /u01/app/oracle/product/11.2.0/dbhome_1

                    System name:    Linux

                    Node name:      gonk.testenv.com

                    Release:        2.6.18-308.el5xen

                    Version:        #1 SMP Fri Jan 27 17:26:57 EST 2012

                    Machine:        x86_64

                    VM name:        Xen Version: 3.1 (PVM)

                    Using parameter settings in server-side pfile /u01/app/oracle/product/11.2.0/dbhome_1/dbs/initTEST.ora

                    System parameters with non-default values:

                      processes                = 150

                      sessions                 = 248

                      spfile                   = "+DATA1/test/spfiletest.ora"

                      memory_target            = 2G

                      control_files            = "+DATA1/test/controlfile/current.297.848048479"

                      db_block_size            = 8192

                      compatible               = "11.2.0.0.0"

                      db_create_file_dest      = "+DATA1"

                      undo_tablespace          = "UNDOTBS1"

                      remote_login_passwordfile= "EXCLUSIVE"

                      db_domain                = "TESTENV.COM"

                      dispatchers              = "(PROTOCOL=TCP) (SERVICE=testXDB)"

                      session_cached_cursors   = 200

                      job_queue_processes      = 10

                      audit_file_dest          = "/u01/app/oracle/admin/test/adump"

                      audit_trail              = "DB"

                      db_name                  = "ORCL"

                      db_unique_name           = "TEST"

                      open_cursors             = 700

                      diagnostic_dest          = "/u01/app/oracle"

                    Tue Jun 10 08:40:02 2014

                    PMON started with pid=2, OS id=7891

                    Tue Jun 10 08:40:02 2014

                    PSP0 started with pid=3, OS id=7893

                    Tue Jun 10 08:40:03 2014

                    VKTM started with pid=4, OS id=7898 at elevated priority

                    VKTM running at (4)millisec precision with DBRM quantum (100)ms

                    Tue Jun 10 08:40:03 2014

                    GEN0 started with pid=5, OS id=7905

                    Tue Jun 10 08:40:04 2014

                    DIAG started with pid=6, OS id=7907

                    Tue Jun 10 08:40:04 2014

                    DBRM started with pid=7, OS id=7909

                    Tue Jun 10 08:40:04 2014

                    DIA0 started with pid=8, OS id=7911

                    Tue Jun 10 08:40:04 2014

                    MMAN started with pid=9, OS id=7916

                    Tue Jun 10 08:40:04 2014

                    DBW0 started with pid=10, OS id=7918

                    Tue Jun 10 08:40:04 2014

                    LGWR started with pid=11, OS id=7920

                    Tue Jun 10 08:40:05 2014

                    CKPT started with pid=12, OS id=7922

                    Tue Jun 10 08:40:05 2014

                    SMON started with pid=13, OS id=7924

                    Tue Jun 10 08:40:05 2014

                    RECO started with pid=14, OS id=7926

                    Tue Jun 10 08:40:05 2014

                    RBAL started with pid=15, OS id=7931

                    Tue Jun 10 08:40:05 2014

                    ASMB started with pid=16, OS id=7933

                    Tue Jun 10 08:40:06 2014

                    MMON started with pid=17, OS id=7935

                    NOTE: initiating MARK startup

                    Tue Jun 10 08:40:06 2014

                    MMNL started with pid=18, OS id=7939

                    starting up 1 dispatcher(s) for network address '(ADDRESS=(PARTIAL=YES)(PROTOCOL=TCP))'...

                    Starting background process MARK

                    Tue Jun 10 08:40:06 2014

                    MARK started with pid=19, OS id=7941

                    NOTE: MARK has subscribed

                    starting up 1 shared server(s) ...

                    ORACLE_BASE from environment = /u01/app/oracle

                    Tue Jun 10 08:40:07 2014

                    ALTER SYSTEM SET local_listener='(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=10.1.3.92)(PORT=1553))))' SCOPE=MEMORY SID='TEST';

                    NOTE: Loaded library: /opt/oracle/extapi/64/asm/orcl/1/libasm.so

                    NOTE: Loaded library: System

                    Tue Jun 10 08:40:11 2014

                    SUCCESS: diskgroup DATA1 was mounted

                    NOTE: dependency between database TEST and diskgroup resource ora.DATA1.dg is established

                    Tue Jun 10 08:40:12 2014

                    alter database mount

                    Set as converted control file due to db_unique_name mismatch

                    Changing di2dbun from ORCL to TEST

                    Tue Jun 10 08:40:16 2014

                    Successful mount of redo thread 1, with mount id 2311351724

                    Database mounted in Exclusive Mode

                    Lost write protection disabled

                    Completed: alter database mount

                    Tue Jun 10 08:40:18 2014

                    License high water mark = 4

                    USER (ospid: 8026): terminating the instance

                    Tue Jun 10 08:40:18 2014

                    ORA-1092 : opitsk aborting process

                    Instance terminated by USER, pid = 8026

                    Tue Jun 10 08:40:21 2014

                    Adjusting the default value of parameter parallel_max_servers

                    from 320 to 135 due to the value of parameter processes (150)

                    Starting ORACLE instance (normal)

                    LICENSE_MAX_SESSION = 0

                    LICENSE_SESSIONS_WARNING = 0

                    Picked latch-free SCN scheme 3

                    Tue Jun 10 08:40:33 2014

                    Using LOG_ARCHIVE_DEST_1 parameter default value as /u01/app/oracle/product/11.2.0/dbhome_1/dbs/arch

                    Autotune of undo retention is turned on.

                    IMODE=BR

                    ILAT =27

                    • 22. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                      KarthikSinghDBA

                      Note sure, Looks like there is an Issue with ARCHIVE LOG MODE. When I terminated the rman by ctrl+c

                       

                      Oracle instance shut down

                      RMAN-00571: ===========================================================

                      RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

                      RMAN-00571: ===========================================================

                      RMAN-03002: failure of Duplicate Db command at 06/10/2014 08:40:49

                      RMAN-05501: aborting duplication of target database

                      RMAN-05541: no archived logs found in target database

                      • 23. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                        FreddieEssex

                        Sorry...I'm a bit lost now, your RMAN session says database shutdown and then database started but the last messages in your alert log are database shutdown, but the RMAN restore session is still hanging.

                         

                        What I would do is stop/kill your database and your RMAN session.

                         

                        Clean up all your files and rename your alert log...and then run the restore again.

                         

                        One thing I noticed was that you had omitted the spfile caluse from your duplicate database statement:

                         

                        DUPLICATE DATABASE TO TEST
                        SPFILE
                        BACKUP LOCATION '/home/oracle/backup/ORCL'
                        NOFILENAMECHECK;
                        
                        
                        

                         

                        If  you think you don't need this as you stated you had already created an pfile, then perhaps create just the pfile with the db_name parameter as suggested in the doc and use the spfile clause.  Maybe a typo or somethig else incorrect in your spfile?

                         

                        http://docs.oracle.com/cd/E11882_01/backup.112/e10642/rcmdupdb.htm#i1006629

                         

                        Please also check this link:

                         

                        http://docs.oracle.com/cd/B28359_01/backup.111/b28270/rcmdupdb.htm#BRADV89934

                         

                        The link above states the following about db_name:

                         

                        The same name used in the DUPLICATE command.

                        The DB_NAME setting for the duplicate database must be unique among databases in its Oracle home.

                        However you have set db_name = ORCL in your pfile I think from the output of your alert log above and you are duplicating to TEST?

                         

                        db_name                  = "ORCL"

                        db_unique_name           = "TEST"

                         

                         

                        Set as converted control file due to db_unique_name mismatch

                        Changing di2dbun from ORCL to TEST

                         

                        Can you then post the appropriate error you get in your alert log.  Can you also post the error you get from the RMAN backup assuming this time it doesn't hang.

                         

                        Message was edited by: FreddieEssex Maybe your error message is due to you not having everything you require to do a restore. Cause:  Target database was running in archived log mode, but control file did not have any archived log records.

                        • 24. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                          KarthikSinghDBA

                          Sorry...I'm a bit lost now, your RMAN session says database shutdown and then database started but the last messages in your alert log are database shutdown, but the RMAN restore session is still hanging.

                           

                          What I would do is stop/kill your database and your RMAN session.

                           

                          Clean up all your files and rename your alert log...and then run the restore again.

                           

                          Exactly I did the same.

                          One thing I noticed was that you had omitted the spfile caluse from your duplicate database statement:

                           

                           

                           

                          1. DUPLICATE DATABASE TO TEST 
                          2. SPFILE 
                          3. BACKUP LOCATION '/home/oracle/backup/ORCL' 
                          4. NOFILENAMECHECK; 

                           

                          If  you think you don't need this as you stated you had already created an pfile, then perhaps create just the pfile with the db_name parameter as suggested in the doc and use the spfile clause.  Maybe a typo or somethig else incorrect in your spfile?

                          If I use the SPFILE then I'm facing the below error

                           

                          Starting Duplicate Db at 10-JUN-14

                          RMAN-00571: ===========================================================

                          RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

                          RMAN-00571: ===========================================================

                          RMAN-03002: failure of Duplicate Db command at 06/10/2014 10:57:39

                          RMAN-05501: aborting duplication of target database

                          RMAN-05537: DUPLICATE without TARGET connection when auxiliary instance is started with spfile cannot use SPFILE clause

                           

                          The same name used in the DUPLICATE command.

                          The DB_NAME setting for the duplicate database must be unique among databases in its Oracle home.

                          However you have set db_name = ORCL in your pfile I think from the output of your alert log above and you are duplicating to TEST?

                          I think some where messed up here. But Yes I'm duplicating the database backup ORCL to TEST which is already installed with default configurations.

                           

                          This time I executed with the same command and RMAN without hanging it populates the following error.

                           

                          Oracle instance shut down

                          RMAN-00571: ===========================================================

                          RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

                          RMAN-00571: ===========================================================

                          RMAN-03002: failure of Duplicate Db command at 06/10/2014 10:59:39

                          RMAN-05501: aborting duplication of target database

                          RMAN-05541: no archived logs found in target database

                           

                          Thanks,

                          Karthik

                          • 25. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                            FreddieEssex

                            Cause:  Target database was running in archived log mode, but control file did not have any archived log records.


                            I don't think there is much you can do about that now as your source is long gone.

                            • 26. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                              Hemant K Chitale

                              Since the controlfile has been restored, you could

                              STARTUP MOUNT

                              LIST BACKUP

                              LIST ARCHIVELOG ALL

                               

                              to see if the controlfile has information about backups and archivelogs.

                               

                              Hemant K Chitale

                              • 27. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                                KarthikSinghDBA

                                Thanks Hemant,

                                 

                                I tried but it didn't work

                                 

                                RMAN> startup mount;

                                 

                                 

                                Oracle instance started

                                RMAN-00571: ===========================================================

                                RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

                                RMAN-00571: ===========================================================

                                RMAN-03002: failure of startup command at 06/11/2014 00:18:11

                                ORA-01103: database name 'ORCL' in control file is not 'TEST'

                                 

                                Looking for a work around

                                • 28. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                                  KarthikSinghDBA

                                  I think I will try to delete the already created database named TEST and then will try the restore. Will it work?

                                  • 29. Re: Restore, Recover, change DB Name with Already Installed DB SW only 11gr2
                                    KarthikSinghDBA

                                    Restore of Contorol file is doing good

                                     

                                    RMAN> restore controlfile from '/home/oracle/backup/ORCL/ORCL_18_0ip6c3so_1_1';

                                     

                                     

                                    Starting restore at 11-JUN-14

                                    using channel ORA_DISK_1

                                     

                                     

                                    channel ORA_DISK_1: restoring control file

                                    channel ORA_DISK_1: restore complete, elapsed time: 00:00:01

                                    output file name=+DATA1/test/controlfile/current.297.848048479

                                    Finished restore at 11-JUN-14

                                     

                                    but after this when I tried to do alter database mount; it shows the db name mismatch error as said preivous post.