oracle problem of insufficient archive space (rman delete archive log)

Case I: archive log full, database users can not log in, business exceptions
 
A solution (can log rman):
rman target /
 
RMAN> crosscheck archivelog all;
 
RMAN> delete archivelog until time 'sysdate-7';
 
RMAN> crosscheck archivelog all;
 
Solution two (not landing rman)
1, log database server, delete the database archive directory 7 days before the archive
2, then delete the archive file, try again landed rman,
If you can log rman then:
rman target /
 
crosscheck archivelog all;
 
delete archivelog until time 'sysdate-7';
 
crosscheck archivelog all;
 
If you delete the archive after still can not log rman, then you must restart the database.
 
 
The best solution:
Write regular tasks, regularly delete the database archive log files seven days ago.
 
[oracle@edgzrip1-PROD1 ~]$ cat delete_archivelog.sh
#!/bin/bash
source ~/profile_prod1
$ORACLE_HOME/bin/rman target / log=delete_archivelog.log<<eof
crosscheck archivelog all;
delete archivelog until time 'sysdate-7';
crosscheck archivelog all;
exit;
eof

Guess you like

Origin www.cnblogs.com/orcl-2018/p/11913246.html