13 Replies Latest reply: Apr 8, 2013 4:44 AM by Mahir M. Quluzade RSS

    DartaGuard doesn't start apply process

    VirtualSadist
      Hello everyone!

      I suffer problem with deploying DataGuard on our infrastructure (Oracle 11R2 Database (no RAC or ASM) + SLES 11.2 OS)

      I was trying to configure it reading this instrcution: http://www.oracle-base.com/articles/11g/data-guard-setup-11gr2.php

      But now my apply process doesn't start.

      On the standby server:
      -----
      SQL> select max(sequence#) from v$log_history;

      MAX(SEQUENCE#)
      --------------
      17

      SQL>

      SQL> SELECT RECOVERY_MODE FROM V$ARCHIVE_DEST_STATUS WHERE DEST_ID=2;

      RECOVERY_MODE
      -----------------------
      IDLE

      SQL>
      -----

      on the primary one:
      -----
      SQL> select max(sequence#) from v$log_history;

      MAX(SEQUENCE#)
      --------------
      23

      SQL>
      SQL> SELECT RECOVERY_MODE FROM V$ARCHIVE_DEST_STATUS WHERE DEST_ID=2;

      RECOVERY_MODE
      -----------------------
      IDLE

      SQL>
      ------


      alert_stb.log ending is:

      Completed: ALTER DATABASE RECOVER MANAGED STANDBY DATABASE DISCONNECT FROM SESSION
      Fri Apr 05 17:19:37 2013
      Using STANDBY_ARCHIVE_DEST parameter default value as /db1/redo/arch_log/
      Fri Apr 05 17:20:37 2013
      FAL[client]: Failed to request gap sequence
      GAP - thread 1 sequence 17-17
      DBID 3032961371 branch 811712090
      FAL[client]: All defined FAL servers have been attempted.
      ------------------------------------------------------------
      Check that the CONTROL_FILE_RECORD_KEEP_TIME initialization
      parameter is defined to a value that's sufficiently large
      enough to maintain adequate log switch information to resolve
      archivelog gaps.

      and on the aler_primary.log there is something like:

      Fatal NI connect error 12514, connecting to:
      (DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=10.232.127.149)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=RCIRU1)(CID=(PROGRAM=oracle)(HOST=SecIBSO)(USER=oracle))))

      VERSION INFORMATION:
      TNS for Linux: Version 11.2.0.3.0 - Production
      TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.3.0 - Production
      Time: 08-APR-2013 09:33:50
      Tracing not turned on.
      Tns error struct:
      ns main err code: 12564

      TNS-12564: TNS:connection refused
      ns secondary err code: 0
      nt main err code: 0
      nt secondary err code: 0
      nt OS err code: 0
      Error 12514 received logging on to the standby


      can anybody help me with this?
      Kind regards,
      VS
        • 1. Re: DartaGuard doesn't start apply process
          Mahir M. Quluzade
          Hi,

          Can you paste here following sql results ?

          On primary
          select dest_id, status, error from v$archive_dest; 
          select max(sequence#)  from v$archived_log ; 
          On Standby
          select max(sequence#)  from v$archived_log ; 
          select max(sequence#)  from v$archived_log where Applied='YES';
          select process from v$managed_Standby; 
          
          Show parameter FAL_SERVER 
          Regards
          Mahir M. Quluzade
          • 2. Re: DartaGuard doesn't start apply process
            VirtualSadist
            primary

            SQL> select dest_id, status, error from v$archive_dest;
            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------
            1 VALID


            2 ERROR
            ORA-12514: TNS:listener does not currently know of service
            requested in connect descriptor

            3 INACTIVE


            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------

            4 INACTIVE


            5 INACTIVE


            6 INACTIVE


            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------

            7 INACTIVE


            8 INACTIVE


            9 INACTIVE


            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------

            10 INACTIVE


            11 INACTIVE


            12 INACTIVE


            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------

            13 INACTIVE


            14 INACTIVE


            15 INACTIVE


            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------

            16 INACTIVE


            17 INACTIVE


            18 INACTIVE


            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------

            19 INACTIVE


            20 INACTIVE


            21 INACTIVE


            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------

            22 INACTIVE


            23 INACTIVE


            24 INACTIVE


            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------

            25 INACTIVE


            26 INACTIVE


            27 INACTIVE


            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------

            28 INACTIVE


            29 INACTIVE


            30 INACTIVE


            DEST_ID STATUS
            ---------- ---------
            ERROR
            -----------------------------------------------------------------

            31 INACTIVE



            31 rows selected.

            SQL>
            SQL> select max(sequence#) from v$archived_log ;

            MAX(SEQUENCE#)
            --------------
            36

            SQL>


            standby:

            SQL> select max(sequence#) from v$archived_log ;

            MAX(SEQUENCE#)
            --------------
            17

            SQL> select max(sequence#) from v$archived_log where Applied='YES';

            MAX(SEQUENCE#)
            --------------
            17

            SQL> select process from v$managed_Standby;

            PROCESS
            ---------
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH

            PROCESS
            ---------
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH

            PROCESS
            ---------
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            ARCH
            MRP0

            31 rows selected.

            SQL>

            SQL> Show parameter FAL_SERVER

            NAME TYPE VALUE
            ------------------------------------ ----------- ------------------------------
            fal_server string PRIMARY
            SQL>
            • 3. Re: DartaGuard doesn't start apply process
              Mahir M. Quluzade
              998585 wrote:
              primary

              SQL> select dest_id, status, error from v$archive_dest;
              DEST_ID STATUS
              ---------- ---------
              ERROR
              -----------------------------------------------------------------
              1 VALID


              2 ERROR
              ORA-12514: TNS:listener does not currently know of service
              requested in connect descriptor
              ------------------------------------------------
              >
              SQL>
              SQL> select max(sequence#) from v$archived_log ;

              MAX(SEQUENCE#)
              --------------
              36

              SQL>


              standby:

              SQL> select max(sequence#) from v$archived_log ;

              MAX(SEQUENCE#)
              --------------
              17

              SQL> select max(sequence#) from v$archived_log where Applied='YES';

              MAX(SEQUENCE#)
              --------------
              17

              SQL> select process from v$managed_Standby;

              PROCESS
              ---------
              MRP0
              Your transport service is not running, but apply process is runnig.

              Now, you must check standby network service with tnsping <standby name>.

              Can you paste here both tnsnames.ora file contents.

              Mahir
              • 4. Re: DartaGuard doesn't start apply process
                Sunny kichloo
                Please confirm the Service name entered in log_archive_dest_2 parameter of your standby database.


                Verify it with connect descriptor of Primary database present at $ORACLE_HOME/network/admin/tnsnames.ora file at standby location.
                • 5. Re: DartaGuard doesn't start apply process
                  VirtualSadist
                  on the standby:


                  SQL> sho parameter log_archive_dest_2

                  NAME TYPE VALUE
                  ------------------------------------ ----------- ------------------------------
                  log_archive_dest_2 string SERVICE=PRIM ASYNC VALID_FOR
                  =(ONLINE_LOGFILES,PRIMARY_ROLE
                  ) DB_UNIQUE_NAME=PRIM

                  on the primary


                  SQL> sho parameter log_archive_dest_2

                  NAME TYPE VALUE
                  ------------------------------------ ----------- ------------------------------
                  log_archive_dest_2 string SERVICE=STB NOAFFIRM ASY
                  NC VALID_FOR=(ONLINE_LOGFILES,
                  PRIMARY_ROLE) DB_UNIQUE_NAME=STB


                  tnsnames.ora on stb server

                  STB =
                  (DESCRIPTION =
                  (ADDRESS = (PROTOCOL = TCP)(HOST = 10.232.127.149)(PORT = 1521))
                  (CONNECT_DATA =
                  (SERVICE_NAME = PRIM)
                  )
                  )

                  PRIM =
                  (DESCRIPTION =
                  (ADDRESS = (PROTOCOL = TCP)(HOST = 10.232.127.220)(PORT = 1521))
                  (CONNECT_DATA =
                  (SERVICE_NAME = PRIM)
                  )
                  )


                  and on primary


                  PRIM =
                  (DESCRIPTION =
                  (ADDRESS_LIST =
                  (ADDRESS = (PROTOCOL = TCP)(HOST = 10.232.127.220)(PORT = 1521))
                  )
                  (CONNECT_DATA =
                  (SERVICE_NAME = PRIM)
                  )
                  )

                  STB =
                  (DESCRIPTION =
                  (ADDRESS_LIST =
                  (ADDRESS = (PROTOCOL = TCP)(HOST = 10.232.127.149)(PORT = 1521))
                  )
                  (CONNECT_DATA =
                  (SERVICE_NAME = PRIM)
                  )
                  )
                  • 6. Re: DartaGuard doesn't start apply process
                    Mahir M. Quluzade
                    I think you must sahnge SERVICE_NAME to SID in tnsnames.ora
                    Like tnsnames.ora on Standby and Primary server

                    What is sid name on standby?
                     
                    STB =
                      (DESCRIPTION =
                        (ADDRESS = (PROTOCOL = TCP)(HOST = 10.232.127.149)(PORT = 1521))
                        (CONNECT_DATA =
                          (SID = PRIM)
                       )
                      )
                    
                    PRIM =
                      (DESCRIPTION =
                        (ADDRESS = (PROTOCOL = TCP)(HOST = 10.232.127.220)(PORT = 1521))
                        (CONNECT_DATA =
                          (SID = PRIM)
                        )
                      )
                    • 7. Re: DartaGuard doesn't start apply process
                      Sunny kichloo
                      Post lsnrctl status of your Primary Database.
                      • 8. Re: DartaGuard doesn't start apply process
                        VirtualSadist
                        Both SID's on stb and prim database server are RCIRU1 (PRIM)

                        the outline of lsnrctl status command on primary server:

                        oracle@SecIBSO:~> lsnrctl status

                        LSNRCTL for Linux: Version 11.2.0.3.0 - Production on 08-APR-2013 11:16:28

                        Copyright (c) 1991, 2011, Oracle. All rights reserved.

                        Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=10.232.127.220)(PORT=1521)))
                        STATUS of the LISTENER
                        ------------------------
                        Alias LISTENER
                        Version TNSLSNR for Linux: Version 11.2.0.3.0 - Production
                        Start Date 04-APR-2013 20:28:05
                        Uptime 3 days 14 hr. 48 min. 22 sec
                        Trace Level off
                        Security ON: Local OS Authentication
                        SNMP OFF
                        Listener Parameter File /u/app/oracle/product/11.2/db_1/network/admin/listener.ora
                        Listener Log File /u/app/oracle/diag/tnslsnr/SecIBSO/listener/alert/log.xml
                        Listening Endpoints Summary...
                        (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.232.127.220)(PORT=1521)))
                        Services Summary...
                        Service "RCIRU1" has 1 instance(s).
                        Instance "RCIRU1", status READY, has 1 handler(s) for this service...
                        The command completed successfully
                        oracle@SecIBSO:~>
                        • 9. Re: DartaGuard doesn't start apply process
                          Mahir M. Quluzade
                          Paste here lsnrctl status result on standby server.
                          You can add standby database service to listener as static service.

                          You are using Linux OS :

                          Add following strings to listener.ora
                          SID_LIST_LISTENER = 
                             (SID_LIST = 
                               (SID_DESC = 
                                 (SID_NAME=RCIRU1ST)
                                 (ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome)
                               )
                             )
                          
                          lsnsrctl  stop
                          lsnrctl start
                          
                          export ORACLE_SID=RCIRU1ST
                          
                          sqlplus / as sysdba
                          startup mount;
                          And you must change tnsnames.ora file contents both
                          RCIRU1ST=
                            (DESCRIPTION =
                              (ADDRESS = (PROTOCOL = TCP)(HOST = 10.232.127.149)(PORT = 1521))
                              (CONNECT_DATA =
                                (SID = RCIRU1ST)
                             )
                            )
                           
                          RCIRU1=
                            (DESCRIPTION =
                              (ADDRESS = (PROTOCOL = TCP)(HOST = 10.232.127.220)(PORT = 1521))
                              (CONNECT_DATA =
                                (SID = RCIRU1)
                              )
                            )
                          Regards
                          Mahir M. Quluzade
                          http://www.mahir-quluzade.com

                          Edited by: Mahir M. Quluzade on Apr 8, 2013 12:31 PM
                          • 10. Re: DartaGuard doesn't start apply process
                            VirtualSadist
                            Marih,

                            thanks a lot for your post!
                            Could you please tell me, where i have to edit listener.ora, on standby or on primary one?
                            On stb and primary SID's are the same
                            • 11. Re: DartaGuard doesn't start apply process
                              Mahir M. Quluzade
                              You must change listener.ora file on standby side.
                              • 12. Re: DartaGuard doesn't start apply process
                                VirtualSadist
                                It helped! Thank you very much!!!

                                Kind regards,
                                Karen Tovmasian