Enable and disable the archivelog in Oracle database

Enable or disable archive log in Oracle Database

Check the status of archive log.

SELECT LOG_MODE FROM V$DATABASE;

Check the location of archive generated.

ARCHIVE LOG LIST;
OR
SELECT DEST_NAME, STATUS, DESTINATION FROM V$ARCHIVE_DEST;

Enable the archivelog mode in Oracle

ALTER SYSTEM SET LOG_ARCHIVE_DEST_1='LOCATION=D:\ARCHIVE\ORCL' SCOPE=BOTH;
SHUTDOWN IMMEDIATE;
STARTUP MOUNT;
ALTER DATABASE ARCHIVELOG;
ALTER DATABASE OPEN;

Disable the archivelog Mode in Oracle

SHUTDOWN IMMEDIATE;
START MOUNT
ALTER DATABASE NOARCHIVELOG;
ALTER DATABASE OPEN;

Change the location of Archive log if location is full

-- first check the parameter which configured.
SHOW PARAMETER LOG_ARCHIVE_DEST
--Second change the location which having sufficient space
ALTER SYSTEM SET LOG_ARCHIVE_DEST_1='LOCATION=D:\ARCHIVE\ORCL' SCOPE=BOTH;
--Third backup the archive and clear with RMAN
RMAN> BACKUP ARCHIVELOG ALL DELETE INPUT;

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.