How to Chage the archive destination in Oracle Database

If you are an Oracle DBA you will have to come across this topic or might not. However
if we have to Chage the archive destination in Oracle Database then this article provides
more details on how to proceed.

If you are using a spfile then create a pfile as fail safe practice.

connect to the database

SQL> CREATE PFILE='$ORACLE_HOME/dbs/initORA.ora' FROM SPFILE='SPFILEORA.ORA';

Change the log_archive_dest parameter using


SQL> alter system set log_archive_dest='/vol2/oradata/archives' scope=spfile;

Shutdown the database

SQL> Shutdown immediate

start the database;

SQL> startup

trigger the log change;

SQL> alter system switch logfile;


Then move to new archive destination directory and check
weather archive logs are creating.

If creating then the change is successfull otherwise you may need to check the
permission for the new log destination and configuration.


=======================================================================

In case you couldn't startup the database after shutdown then you can start using
the last known good configuration usign the pfile.

In order to startup the database using pfile, use

SQL> startup pfile='$ORACLE_HOME/dbs/initORA.ora'

Thereafter create the SPfile using the current working pfile using

SQL> create spfile using pfile;

Then startup using the newly created spfile using

SQL> shutdown immediate

After shutdown complete, startup the database

SQL> startup

Provide the new archive location again using

SQL> alter system set log_archive_dest='/vol2/oradata/archives' scope=spfile;

Shutdown the database

SQL> Shutdown immediate

start the database;

SQL> startup

Trigger the log swtch manually using

SQL> alter system switch logfile;


Then move to new archive destination directory and check
weather archive logs are creating.

:) :) :) Have a nice day..... :)

Comments

Popular posts from this blog

Installation of MySQL Enterprise Monitor Agent on Linux

Installation and Configuration of Cisco VPN Client on Linux

Oracle Startup Issues ORA-16038