1 2 Previous Next 17 Replies Latest reply: Oct 12, 2012 6:32 AM by 967980 RSS

    RMAN-04006: error from auxiliary database,

    Jcgo-Oracle
      Hi All,

      Getting this error when trying to do an RMAN Duplicate command.
      Well, first , just trying to connect to AUX db fails with this error:

      ORA-12528: TNS:listener: all appropriate instances are blocking new connections


      1). Target aux db is in MOUNT state.
      2). DB versions are 11.2.0.2
      3). Listener file is managed by GRID.

      I looked at few ML notes, specially
      Connection to Auxilary using connect string failed with ORA-12528 [ID 419440.1]
      also this one:

      ORA-12528: TNS:listener: all appropriate instances are blocking new connections [ID 301099.1]

      doesnt help at all..

      any ideas?
        • 1. Re: RMAN-04006: error from auxiliary database,
          CKPT
          Target aux db is in MOUNT state.
          Why AUX database in mount status? It should be in nomount

          Post the command here how you are connecting?
          From where you are executing duplicate?
          Is target database is in open or not?
          • 2. Re: RMAN-04006: error from auxiliary database,
            Jcgo-Oracle
            Sorry ...
            the target database is in Nomount state.
            And I am connecting from source db.
            • 3. Re: RMAN-04006: error from auxiliary database,
              tychos
              Hi JCGO,
              Can you change the listener.ora on the aux server by adding a static entry for the aux database in the sid_list?
              (do not forget to restart or reload the listener.)
              When done retry the rman duplicate command.
              Please post your results.
              Regards,
              Tycho
              • 4. Re: RMAN-04006: error from auxiliary database,
                Jcgo-Oracle
                I made changes, then reloaded the listener services and no luck.

                Here is the content of the listener file:
                SID_LIST_LISTENER =
                (SID_LIST=
                (SID_DESC=
                (SID_NAME=patriadb)
                (ORACLE_HOME =/u01/app/oracle/product/11.2.02/dbhome_1)
                )
                )


                I added this to the TNS files on the source and now it works:

                PATRIA1DB=(DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = host1.example.com)(PORT = 1521)) (CONNECT_DATA *=(UR=A)* (SERVER = DEDICATED) (SERVICE_NAME = db.example.com)))
                • 5. Re: RMAN-04006: error from auxiliary database,
                  CKPT
                  I made changes, then reloaded the listener services and no luck.
                  Always these are the basic thumb signs.

                  TARGET --- which is source database(production) it should be OPEN

                  Auxiliary -- which is destination database(dev/test/aux) it should be in NOMOUNT before duplicate.

                  If you are executing DUPLICATE command from AUXILIARY instance. then the command should be.

                  rman target sys/*****@prod auxiliary /

                  RMAN> duplicate target database to 'aux';

                  Make sure which tns string is pointing where.
                  • 6. Re: RMAN-04006: error from auxiliary database,
                    Jcgo-Oracle
                    well..FROM TARGET database ( where script is running);;
                    it looked ok for awhile then:

                    AN>
                    echo set on

                    RMAN> connect target *
                    connected to target database: PATRIADB (DBID=2365902769)

                    RMAN> connect auxiliary *
                    connected to auxiliary database: PATRIADB (not mounted)

                    RMAN> run {
                    2> # Create channels for parallism
                    3> allocate channel prmy1 type disk;
                    4> allocate channel prmy2 type disk;
                    5> allocate channel prmy3 type disk;
                    6> allocate channel prmy4 type disk;
                    7> allocate channel prmy5 type disk;
                    8> allocate auxiliary channel stby1 type disk;
                    9> duplicate target database to 'patriadb' from active database
                    10> db_file_name_convert=('/u01/oracle/oradata/patriadb','/u01/app/oracle/oradata/patriadb')
                    11> logfile group 1 ('/u01/app/oracle/oradata/patriadb/redo01.log ','/u01/app/oracle/oradata/patriadb/redo02_02.log') SIZE 500M,
                    e nomount;
                    }
                    executing Memory Script

                    Oracle instance shut down

                    released channel: prmy1
                    released channel: prmy2
                    released channel: prmy3
                    released channel: prmy4
                    released channel: prmy5
                    RMAN-00571: ===========================================================
                    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
                    RMAN-00571: ===========================================================
                    RMAN-03002: failure of Duplicate Db command at 06/12/2011 22:52:46
                    RMAN-06174: not connected to auxiliary database
                    RMAN-03015: error occurred in stored script Memory Script
                    RMAN-04006: error from auxiliary database: ORA-12514: TNS:listener does not currently know of service requested in connect descriptor


                    RMAN>

                    **************

                    I am going to try to run this from the target later....not sure where the error is coming from...
                    • 7. Re: RMAN-04006: error from auxiliary database,
                      tychos
                      Hi,
                      connected to target database: PATRIADB (DBID=2365902769)
                      connected to auxiliary database: PATRIADB (not mounted)
                      So your target and auxliary have the same name....
                      Please change the name of the auxiliary instance to something else.

                      Can you remotely stop/start the auxiliary instance with sqlplus?
                      sqlplus sys/<pwd>@<aux> as sysdba
                      shutdown immediate
                      startup
                      If not check and fix your tns and listener setup.
                      Than retry the duplicate command.
                      Regards,
                      Tycho

                      Edited by: tychos on 13-jun-2011 20:05
                      • 8. Re: RMAN-04006: error from auxiliary database,
                        Jcgo-Oracle
                        I can see whats happening.
                        when the DUPLICATE COMMAND runs, it shuts down TARGET database.
                        And when this happens, it also REMOVES the service name from the STATUS of the listener.
                        In other words, it unregisters the database from the listener.
                        Thats why I get this error:

                        sed channel: prmy4
                        released channel: prmy5
                        RMAN-00571: ===========================================================
                        RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
                        RMAN-00571: ===========================================================
                        RMAN-03002: failure of Duplicate Db command at 06/13/2011 13:25:01
                        RMAN-06174: not connected to auxiliary database
                        RMAN-03015: error occurred in stored script Memory Script
                        RMAN-04006: error from auxiliary database: ORA-12514: TNS:listener does not currently know of service requested in connect descriptor


                        RMAN>
                        • 9. Re: RMAN-04006: error from auxiliary database,
                          Jcgo-Oracle
                          as evidenced:

                          Service "kenobidb.us.oracle.com" has 1 instance(s).
                          Instance "kenobidb", status BLOCKED, has 1 handler(s) for this service...
                          The command completed successfully
                          LSNRCTL> status
                          Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=host1.example.com)(PORT=1522)))
                          STATUS of the LISTENER
                          ------------------------
                          Alias LISTENER_KENOBI1
                          Version TNSLSNR for Linux: Version 11.2.0.2.0 - Production
                          Start Date 13-JUN-2011 14:28:41
                          Uptime 0 days 0 hr. 10 min. 27 sec
                          Trace Level off
                          Security ON: Local OS Authentication
                          SNMP OFF
                          Listener Parameter File /u01/app/oracle/product/11.2.02/grid/network/admin/listener.ora
                          Listener Log File /u01/app/oracle/diag/tnslsnr/kenobi/listener_kenobi1/alert/log.xml
                          Listening Endpoints Summary...
                          (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=host1.example.com)(PORT=1522)))
                          The listener supports no services
                          The command completed successfully
                          LSNRCTL>

                          ************
                          After the RMAN duplicate fails, the DB unregisters from the listener...
                          • 10. Re: RMAN-04006: error from auxiliary database,
                            CKPT
                            RMAN-03002: failure of Duplicate Db command at 06/13/2011 13:25:01
                            RMAN-06174: not connected to auxiliary database
                            RMAN-03015: error occurred in stored script Memory Script
                            RMAN-04006: error from auxiliary database: ORA-12514: TNS:listener does not currently know of service requested in connect descriptor
                            well..FROM TARGET database ( where script is running);;
                            I always suggest to run DUPLICATE ONLY from Auxiliary instance. Not from target/source server.
                            Oracle instance shut down
                            released channel: prmy1
                            Because if you connect to auxiliary instance from other server remotly, Mostly it fails whenever oracle bounces the AUX database(due to internal scripts).
                            So i strongly recommend you to run the script from Auxiliary server not from target.

                            as
                            $ rman target sys/****@prod auxiliary /
                            RMAN> duplicate target database to 'aux';
                            Thanks.
                            • 11. Re: RMAN-04006: error from auxiliary database,
                              user7426834
                              How do you solve it?
                              Thx
                              • 12. Re: RMAN-04006: error from auxiliary database,
                                Ratnesh Sharma
                                solution is to set ORACLE_SID to auxiliary database id and connet it using "auxiliary /" use full credentials for target database
                                • 13. Re: RMAN-04006: error from auxiliary database,
                                  613650
                                  Curious how this is your solution...when I try this route I get the following. When I connect with a net service name (and a static entry in the listener, and (UR=A) in my tnsfile), I get the scenario that was describe at the beginning of this post.

                                  $ rman

                                  Recovery Manager: Release 11.2.0.3.0 - Production on Thu Apr 12 10:16:44 2012

                                  Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.

                                  RMAN> connect target sys/*******@SEED

                                  connected to target database: SEED (DBID=860063374)

                                  RMAN> connect auxiliary /

                                  connected to auxiliary database: TRNG (not mounted)

                                  RMAN> duplicate target database
                                  2> to 'TRNG'
                                  3> from active database;

                                  Starting Duplicate Db at 12-APR-12
                                  RMAN-00571: ===========================================================
                                  RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
                                  RMAN-00571: ===========================================================
                                  RMAN-03002: failure of Duplicate Db command at 04/12/2012 10:17:22
                                  RMAN-05501: aborting duplication of target database
                                  RMAN-06217: not connected to auxiliary database with a net service name
                                  • 14. Re: RMAN-04006: error from auxiliary database,
                                    920176
                                    check out following link for explanation

                                    http://oracle-mag.com/oracle-backup-and-recovery/duplicating-database-using-rman-duplicate-command/

                                    Edited by: user2872615 on May 21, 2012 12:01 AM
                                    1 2 Previous Next