8 Replies Latest reply: Jan 10, 2013 12:43 PM by rp0428 RSS

    Why Database should be in mount stage for enable Flashback

    AKPT
      Oracle 11.1.0.6.0
      Windows

      Why database should be in mount stage for enabling flashback feature but we can disable this feature even in Open mode?

      Kindly share your inputs .

      Thanks,
      Alok
        • 1. Re: Why Database should be in mount stage for enable Flashback
          vlethakula
          Pobably, oracle does not want any transactions to be running.In mount mode database is not accessible to end users.
          • 2. Re: Why Database should be in mount stage for enable Flashback
            AJ
            Hi,

            Actually, starting from 11.2, the database can be open when enabling flashback database.
            • 3. Re: Why Database should be in mount stage for enable Flashback
              rp0428
              >
              Oracle 11.1.0.6.0
              Windows

              Why database should be in mount stage for enabling flashback feature but we can disable this feature even in Open mode?
              >
              That was, indeed, a requirement in 11.1 per the doc
              http://docs.oracle.com/cd/B28359_01/server.111/b28286/statements_9011.htm
              >
              Prerequisites

              You must have the SYSDBA system privilege. A flash recovery area must have been prepared for the database. The database must have been put in FLASHBACK mode with an ALTER DATABASE FLASHBACK ON statement unless you are flashing the database back to a guaranteed restore point. The database must be mounted but not open. In addition:
              >
              But no longer a requirement in the 11.2 doc
              http://docs.oracle.com/cd/E11882_01/backup.112/e10642/flashdb.htm
              >
              Enabling Flashback Database
              Follow these are the steps to enable Flashback Database.

              To enable flashback logging:

              1.Ensure the database instance is open or mounted. If the instance is mounted, then the database must be shut down cleanly unless it is a physical standby database. Other Oracle RAC instances can be in any mode.
              • 4. Re: Why Database should be in mount stage for enable Flashback
                AKPT
                Hi,

                As per doc this is prerequisites that database should be in mount mode to enable flashback but we can disable flashback even in open mode.
                I would like to know the concept behind this.

                Thanks,
                Alok
                • 5. Re: Why Database should be in mount stage for enable Flashback
                  Salman Qureshi
                  Hi Alok
                  I would like to know the concept behind this.
                  Oracle did not disclose it that why initially flashback enable/disable needed database to be in mount and why in 11.2 it does not. Likewise they don't reveal why oracle needs to be in mount state for enabling archivelog mode. Oracle started using rollback/unto segments eversince oracle is around, but initially it did not support flashback query/transaction but now it allows, why/hiow? oracle never published the reason.
                  So these are secrets and oracle does not tell how it does this thing.

                  Salman
                  • 6. Re: Why Database should be in mount stage for enable Flashback
                    AKPT
                    Hi ,

                    Aman/hemant sir please share your inputs.

                    Thanks
                    Alok
                    • 7. Re: Why Database should be in mount stage for enable Flashback
                      John Stegeman
                      The reason why: Oracle says so.

                      Do you think if you knew the technical or other reasons why Oracle has stipulated this that anything would change?
                      • 8. Re: Why Database should be in mount stage for enable Flashback
                        rp0428
                        >
                        As per doc this is prerequisites that database should be in mount mode to enable flashback but we can disable flashback even in open mode.
                        I would like to know the concept behind this.
                        >
                        Only Oracle knows why and why, for 11g, you can now have the database open. Any 'guesses' would only be guesses.

                        You can get some possible clues from the DBA guide section for 10g 'Starting Up and Shutting Down' the database.
                        http://docs.oracle.com/cd/B19306_01/server.102/b14231/start.htm

                        Traditionally MOUNT mode (database closed) is used for administrative activities by the DBA that need to be done either when there is no user activity that might conflict with them.
                        >
                        Starting Up an Instance
                        . . .
                        •Start the instance and mount the database, but leave it closed. This state allows for certain DBA activities, but does not allow general access to the database.
                        >
                        Or this from the same doc a little later on
                        >
                        Starting an Instance and Mounting a Database
                        You can start an instance and mount a database without opening it, allowing you to perform specific maintenance operations. For example, the database must be mounted but not open during the following tasks:

                        •Enabling and disabling redo log archiving options. For more information, please refer to Chapter 7, "Managing Archived Redo Logs".

                        •Performing full database recovery. For more information, please refer to Oracle Database Backup and Recovery Basics

                        The following command starts an instance and mounts the database, but leaves the database closed:

                        STARTUP MOUNT
                        >
                        Perhaps part of the flashback enable process required exclusive access to ALL tablespaces or datafiles; meaning you can't have users modifying them.

                        Perhaps the enable process for 10g needed to perform simultaneous updates to all datafile headers, the controlfiles and undo or cache or data dictionary entries; meaning you can't have users getting in the way.

                        Dont' know.