Oracle重做日志文件组-新增、删除

查看日志文件组信息

sql> select * from v$log;
GROUP# THREAD# SEQUENCE# BYTES BLOCKSIZE MEMBERS ARCHIVED STATUS FIRST_CHANGE# FIRST_TIME NEXT_CHANGE# NEXT_TIME
---------- ---------- ---------- ---------- ---------- ---------- -------- ---------------- ------------- ----------- ------------ -----------
1 1 13 52428800 512 1 NO INACTIVE 21995736819 2017-9-21 9 21995740613 2017-9-21 1
2 1 14 52428800 512 1 NO CURRENT 21995740613 2017-9-21 1 281474976710
3 1 12 52428800 512 1 NO INACTIVE 21995708930 2017-9-21 7 21995736819 2017-9-21 9

sql> select * from v$logfile;
GROUP# STATUS TYPE MEMBER IS_RECOVERY_DEST_FILE
---------- ------- ------- -------------------------------------------------------------------------------- ---------------------
3 ONLINE C:\ORACEL\BASE\ORADATA\ORCL\REDO03.LOG NO
2 ONLINE C:\ORACEL\BASE\ORADATA\ORCL\REDO02.LOG NO
1 ONLINE C:\ORACEL\BASE\ORADATA\ORCL\REDO01.LOG NO

新增日志组:

sql> alter database add logfile
2 ('C:\orcl1122\disk1\REDO04.LOG','C:\orcl1122\disk1\REDO05.LOG') size 50M;
Database altered

sql> select * from v$log
2 ;
GROUP# THREAD# SEQUENCE# BYTES BLOCKSIZE MEMBERS ARCHIVED STATUS FIRST_CHANGE# FIRST_TIME NEXT_CHANGE# NEXT_TIME
---------- ---------- ---------- ---------- ---------- ---------- -------- ---------------- ------------- ----------- ------------ -----------
1 1 13 52428800 512 1 NO INACTIVE 21995736819 2017-9-21 9 21995740613 2017-9-21 1
2 1 14 52428800 512 1 NO CURRENT 21995740613 2017-9-21 1 281474976710
3 1 12 52428800 512 1 NO INACTIVE 21995708930 2017-9-21 7 21995736819 2017-9-21 9
4 1 0 52428800 512 2 YES UNUSED 0 0

sql> select * from v$logfile;
GROUP# STATUS TYPE MEMBER IS_RECOVERY_DEST_FILE
---------- ------- ------- -------------------------------------------------------------------------------- ---------------------
3 ONLINE C:\ORACEL\BASE\ORADATA\ORCL\REDO03.LOG NO
2 ONLINE C:\ORACEL\BASE\ORADATA\ORCL\REDO02.LOG NO
1 ONLINE C:\ORACEL\BASE\ORADATA\ORCL\REDO01.LOG NO
4 ONLINE C:\ORCL1122\DISK1\REDO04.LOG NO
4 ONLINE C:\ORCL1122\DISK1\REDO05.LOG NO

删除日志组: sql> alter database drop logfile group 4;

相关文章

数据库版本:11.2.0.4 RAC(1)问题现象从EM里面可以看到,在23号早上8:45~8:55时,数据库等待会话暴增...
(一)问题背景最近在对一个大约200万行数据的表查看执行计划时,发现存在异常,理论上应该返回100多万...
(一)删除备份--DELETE命令用于删除RMAN备份记录及相应的物理文件。当使用RMAN执行备份操作时,会在RM...
(1)DRA介绍 数据恢复顾问(Data Recovery Advise)是一个诊断和修复数据库的工具,DRA能够修复数据文...
RMAN(Recovery Manager)是Oracle恢复管理器的简称,是集数据库备份(backup)、修复(restore)和恢复...
(1)备份对象 可以使用RMAN进行的备份对象如下: --整个数据库:备份所有的数据文件和控制文件; --数...