While turning on Flashback in the Oracle Database, sometimes we may encounter the error : ‘ORA-38706: Cannot turn on FLASHBACK DATABASE logging’. Today we will discuss how to resolve this. Let’s go through step by step:
Table of Contents
Issue : ORA-38706: Cannot turn on FLASHBACK DATABASE logging
SQL> select flashback_on from v$database;
FLASHBACK_ON
------------------
NO
SQL> alter database flashback on;
alter database flashback on
*
ERROR at line 1:
ORA-38706: Cannot turn on FLASHBACK DATABASE logging.
ORA-38707: Media recovery is not enabled.
Resolution :
Check the log mode. We can see that its in noarchive log. So make it in archivelog mode. Follow the below steps :
SQL> select log_mode from v$database;
LOG_MODE
------------
NOARCHIVELOG
SQL> shut immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup mount;
ORACLE instance started.
Total System Global Area 2432695144 bytes
Fixed Size 8899432 bytes
Variable Size 536870912 bytes
Database Buffers 1879048192 bytes
Redo Buffers 7876608 bytes
Database mounted.
SQL> alter database archivelog;
Database altered.
SQL> alter database open;
Database altered.
SQL> select log_mode from v$database;
LOG_MODE
------------
ARCHIVELOG
Now, enable the flashback. It will be fine.
SQL> select flashback_on from v$database;
FLASHBACK_ON
------------------
NO
SQL> alter database flashback on;
Database altered.
So, these are the steps how you can resolve ‘ORA-38706: Cannot turn on FLASHBACK DATABASE logging’. I hope it helps!! Also, there are other scenarios as well where you can get this error. For this, you can check the Oracle Doc ID 2785129.1 too.
Related Oracle Related Articles :
- Enable-Disable Archivelog Mode in Oracle Database
- Troubleshooting ORA-19504 : failed to create file: Easy Guide
Pingback: How to Start and Stop MRP Process in Oracle Dataguard
Pingback: ORA-04036: PGA memory used by the instance...: Easy Guide