2

I have an Oracle 10g XE installation (exclusively used for development) which has accumulated so far 14 GB of files at ...\oraclexe\app\oracle\flash_recovery_area\XE\ARCHIVELOG. I do need that space and I'm tempted to just remove everything using Windows explorer but surely Oracle won't be amused.

Is it possible to configure Oracle XE to purge that stuff automatically as soon as it's no longer needed?

3

What does it mean "no longer needed"? Archive redologs have "only one" usage, they can be applied onto the last full/incremental database backup to recover the database.

So you either backup your development database and then you can delete them via RMAN during database backup. Or you do not backup your database and then you can run in NO ARCHIVELOG mode.

2
  • No backups exist: it's a development database with nothing but disposable data. I'll see if can can figure out how to disable ARCHIVELOG mode, since I apparently don't need those logs. Thank you. Jun 9 '15 at 11:45
  • I've composed an answer with the commands I've found that actually worked for me. Feel free to point out plain mistakes. Jun 9 '15 at 12:14
3

To disable archive logging entirely you need to connect locally (important bit, or you'll get disconnected) and run sqlplus as DBA:

C:\>sqlplus / as sysdba

... and then run:

SQL> shutdown immediate;
SQL> startup mount;
SQL> alter database noarchivelog;
SQL> alter database open;

Additionally, run this to ckeck whether it's enabled:

SQL> archive log list;

This won't remove existing logs though. You first need to remove the files manually right from the file system. Once you do it, you can run RMAN:

C:\> rman

... and tell Oracle about what you just did:

RMAN> connect target;
RMAN> crosscheck archivelog all;
RMAN> delete noprompt expired archivelog all;

Disclaimer: we've just disabled a backup related feature!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.