10 Replies Latest reply: May 16, 2014 6:29 AM by petra-K RSS

    Disable dataguard

      Hi all,

       

      11.2.0.1

       

      We have currently standby database at DR site. But the DR site got busted.

      How do I turn off or stop dataguard replication at the Primary DB?

       

      Thanks,

      pK

        • 1. Re: Disable dataguard
          Renu-Oracle

          Hi,

           

          Remove Physical Standby Configuration
          ==========================


          1. Put Primary Database in Maximum Performance Mode

          On the Primary database, put the Database in Maximum Performance Mode (if not already):

          SQL> ALTER DATABASE SET STANDBY DATABASE TO MAXIMIZE PERFORMANCE;

          or if using the Data Guard Broker:

          DGMGRL> EDIT CONFIGURATION SET PROTECTION MODE AS MAXPERFORMANCE;

           

          2. Remove Data Guard Broker Configuration

          If you are using the Data Guard Broker, remove the Data Guard Broker Configuration:

          DGMGRL> REMOVE CONFIGURATION;

           

          3. Unset Data Guard-specific Initialization Parameters

          Unset/Remove following Initialization Parameters from the (S)PFILE of the Primary Database:

           

           

          LOG_ARCHIVE_CONFIG
          DB_FILE_NAME_CONVERT
          LOG_FILE_NAME_CONVERT
          LOG_ARCHIVE_DEST_n pointing to the Standby Database and valid for STANDBY_LOGFILES
          LOG_ARCHIVE_DEST_STATE_n
          DG_BROKER_START
          DG_BROKER_CONFIG_FILE1
          DG_BROKER_CONFIG_FILE2
          STANDBY_ARCHIVE_DEST
          STANDBY_FILE_MANAGEMENT
          FAL_SERVER
          FAL_CLIENT

           

           

          4. Drop Standby Redologs from the Primary Database

           

          Use following Query to check for Standby Redolog Groups:

           

           

          SQL> SELECT GROUP# FROM V$STANDBY_LOG;


          Use following Command to Drop the Standby Redo logs:

           

           

          SQL> ALTER DATABASE DROP STANDBY LOGFILE GROUP <GROUP_NUMBER>;
          e.g.
          SQL> alter database drop standby logfile group 3;


          Drop all Standby Redolog Groups using above Command.

           


          5. Drop the Data Guard Broker Configuration Files if used.

           

          Thanks,

          Renu

          • 2. Re: Disable dataguard

            Thanks dear , your mastery of the subject is impressive!!!!

            Truly exceptionally fantastic

            I gave you an A+++ rating

            • 3. Re: Disable dataguard
              stefan.seck

              Hi,

               

              with this answer you have not only stopped or disabled the dataguard.

              You have removed all dataguard configuration.

              When your standby server is up and runnng again, you have to build a new standby database.

               

              But if the server is only a few hours down and you have fixed it, you might want to start your standby again without the timeconsuming rebuild.

               

              You can access the dataguard configuration also from the primary database.

              You can disable the log apply in the standby:

              dgmgrl> edit database 'STANDBY_DB' set state='APPLY-OFF;

               

              If the first step doesn't work,

              You can at least stop the log shipping to the standby:

              dgmgrl> edit database 'STANDBY_DB' set state='LOG-TRANSPORT-OFF';

               

              Check the status

              dgmgrl> show database verbose 'STANDBY_DB'

               

              But be aware that from now the archives logs won't be shipped to the standby host and won't be deleted because rman recognized that the archivelogs aren't applied .

              So you have to monitor the archivelog destinations on your primary host.

               

              Regards

              Stefan

              • 4. Re: Disable dataguard

                Thanks dear, very informative! I learned new things here

                • 5. Re: Disable dataguard
                  Green Dust

                  As far as I know if the standby database is down and below parameters are reset then it will allow to delete the archvies on primary. correct me if i am wrong.

                   

                  log_archive_config

                  archive_log_dest_2=service

                  • 6. Re: Disable dataguard
                    Renu-Oracle

                    Thanks pK

                    • 7. Re: Disable dataguard
                      stefan.seck

                      Hi Green Dust,

                       

                      you are right.

                      But be careful, If you use dgmgrl to setup a dataguard configuration, use only dgmgrl to change parameter in the databases.

                       

                      Regards

                      Stefan

                      • 8. Re: Disable dataguard

                        Hi All,

                         

                        What happen if i failover to standby and drop it?

                         

                        Does my primary still retain the dataguard config  when  I start it up again?

                         

                         

                        Thanks

                        • 9. Re: Disable dataguard

                          Hi Renu,

                           

                          How to do this? > Drop the Data Guard Broker Configuration Files if used.

                           

                           

                          Thanks.

                          • 10. Re: Disable dataguard

                            Hi Stefan,

                             

                            ****But be careful, If you use dgmgrl to setup a dataguard configuration, use only dgmgrl to change parameter in the databases.


                            How do I differentiate the parameters setup in dgmgrl against the parameter setup at sqlplus command line?


                            Thanks