|  | 
 
 
              
                | 
                    
                    
                      | Enabling Archive in Oracle Database 10g !!!!! |  
                      | Thursday, June 12, 2008 |  
                      | 1) Check these parameters and use alter system command to set these parameters if you do not want to use the default valuesThese following parameters are dynamic. SQL> show parameter db_recovery_file_dest – If require set the location.
 SQL> show parameter db_recovery_file_dest_size – Default size of dir is 2GB.
 i.e SQL> alter system set log_archive_dest_1='LOCATION=USE_DB_RECOVERY_FILE_DEST' scope=both sid='*' ;
 Note : Why we don’t need to set LOG_ARCHIVE_DEST parameter b’coz LOG_ARCHIVE_DEST_10 init param automatically set to DB_RECOVERY_FILE_DEST.
 Note : log_archive_start parameter in pfile as it is been deprecated in 10g.
 Note : log_archive_dest this parameter you can’t use with db_recovery_file_dest. If you want to multiple archive log destination you should set "log_archive_dest_n" parameter for mutliple location.
 2) Shutdown Database and take cold backup.
 SQL>shutdown immediate;
 3) Startup database in Mount State.
 SQL>Startup Mount
 4) Enable Archive Log.
 SQL>alter database archivelog;
 5) Open Database
 SQL>alter database open;
 6) Check Archive Log Mode
 SQL> archive log list
 Database log mode            Archive Mode
 Automatic archival           Enabled
 Archive destination          USE_DB_RECOVERY_FILE_DEST
 Oldest online log sequence   128
 Next log sequence to archive 130
 Current log sequence         130
 Or
 SQL> select log_mode from v$database;
 LOG_MODE
 -----------------
 ARCHIVELOG
 6) Switch log file
 SQL>alter system switch logfile;
 System altered.
 7) Now Check flash_recovery_area
 flash_recovery_area\\ARCHIVELOG\/
 8) Query these view.
 V$FLASH_RECOVERY_AREA_USAGE - Using this view you can immediately see what      kind of files are available in the Flash Recovery Area.
 V$RECOVERY_FILE_DEST – It shows the current location, disk quota, space in use, space reclaimable by deleting files, and total number of files in the flash recovery area.
 v$archived_log - Information about archived redo logs.
 v$parameter - Shows the location of the flash recovery area where archived redo logs are created.
 v$log_history - Contains information on previous redo logs
 
 
 Note : You cannot enable these parameters if you have set values for the LOG_ARCHIVE_DEST and LOG_ARCHIVE_DUPLEX_DEST parameters. You must disable those parameters before setting up the flash recovery area. You can instead set values for the LOG_ARCHIVE_DEST_n parameters. If you do not set values for local LOG_ARCHIVE_DEST_n, then setting up the flash recovery area will implicitly set LOG_ARCHIVE_DEST_10 to the flash recovery area.
 
 ==============================================
 Pre-Checking
 ============
 
 Logon to SQLPLUS and check:
 
 SQL> show parameter db_recovery_file_dest
 
 NAME                                 TYPE        VALUE
 ------------------------------------ ----------- ------------------------------
 db_recovery_file_dest                string
 db_recovery_file_dest_size           big integer 0
 
 SQL> show parameter log_archive_format
 
 NAME                                 TYPE        VALUE
 ------------------------------------ ----------- ------------------------------
 log_archive_format                   string      PPAAPI_%t_%s_%r.arc
 
 SQL> show parameter log_archive_dest
 
 NAME                                 TYPE        VALUE
 ------------------------------------ ----------- ------------------------------
 log_archive_dest                     string      /prod/arch
 
 SQL> SELECT * FROM v$version;
 
 BANNER
 ----------------------------------------------------------------
 Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
 PL/SQL Release 10.2.0.4.0 - Production
 CORE    10.2.0.4.0      Production
 TNS for Linux: Version 10.2.0.4.0 - Production
 NLSRTL Version 10.2.0.4.0 - Production
 
 SQL> archive log list
 Database log mode              No Archive Mode
 Automatic archival             Disabled
 Archive destination            /prod/arch
 Oldest online log sequence     597
 Current log sequence           600
 
 SQL> !df -h /prod/arch
 Filesystem            Size  Used Avail Use% Mounted on
 approd06-nas:/vol/aoh_16a_arch/prod_arch
 100G  1G  99G   1% /prod/arch
 
 Action Plan
 ===========
 1. Bring down the database services.
 2. Bring up the database in mount state
 
 Logon to SQLPLUS as sysdba
 
 SQL> startup mount
 SQL> alter database archivelog;
 SQL> alter database open;
 
 3. Verify the Archive Log Mode as following:
 
 SQL> archive log list
 SQL>select log_mode from v$database;
 
 4. After above action plan is done, once its changed to archive mode, Perform
 the backup (Recommended).
 |  
                      | posted by Jaswinder Singh @ 5:00 AM   |  
                      | 
                            
                              |  |  
                              | 4 Comments: |  
                              | 
                                  
                                  
                                      
                                      
                                        Running the database in ARCHIVELOG mode has the following benefits:
 * The database can be completely recovered from both instance and media failure.
 * The user can perform online backups, i.e., back up tablespaces while the database is open and available for use.
 * Archived redo logs can be transmitted and applied to the standby database
 * Oracle supports multiplexed archive logs to avoid any possible single point of failure on the archive logs.
 * The user has more recovery options, such as the ability to perform tablespace-point-in-time recovery (TSPITR)
                                      
                                      
                                  
                                      
                                      
                                        Greetings,
 This is a question for the webmaster/admin here at askmeapps.blogspot.com.
 
 May I use part of the information from this blog post  right above if I provide a link back to your website?
 
 Thanks,
 James
                                      
                                      
                                        Hi James,
 Thanks for your comments. You can not use contents from this blog. You may provide the link of blog.
 
 Regards,
 Jaswinder Singh
 AskMeApps
 |  
                              |  |  
                              | << Home |  
                              |  |  |  |  |  | 
        
Running the database in ARCHIVELOG mode has the following benefits:
* The database can be completely recovered from both instance and media failure.
* The user can perform online backups, i.e., back up tablespaces while the database is open and available for use.
* Archived redo logs can be transmitted and applied to the standby database
* Oracle supports multiplexed archive logs to avoid any possible single point of failure on the archive logs.
* The user has more recovery options, such as the ability to perform tablespace-point-in-time recovery (TSPITR)