首页 > 代码库 > ORACLE 加大日志文件

ORACLE 加大日志文件

--新建临时日志文件
alter database add logfile group 4 (‘/u01/app/oracle/oradata/orcl/redo04.log‘) size 10m;
alter database add logfile group 5 (‘/u01/app/oracle/oradata/orcl/redo05.log‘) size 10m;
alter database add logfile group 6 (‘/u01/app/oracle/oradata/orcl/redo06.log‘) size 100m;
--切换日志文件
alter system switch logfile;
alter system switch logfile;
--删除旧文件
alter database drop logfile group 1;
alter database drop logfile group 2;
alter database drop logfile group 3;
--操作系统删掉1,2,3
--新建3个
alter database add logfile group 1 (‘/u01/app/oracle/oradata/orcl/redo01.log‘) size 200m;
alter database add logfile group 2 (‘/u01/app/oracle/oradata/orcl/redo02.log‘) size 200m;
alter database add logfile group 3 (‘/u01/app/oracle/oradata/orcl/redo03.log‘) size 200m;
--切换日志文件
alter system switch logfile;
alter system switch logfile;
--删旧日志组
alter database drop logfile group 4;
--操作系统删掉4,5
--备份控制文件
SQL> connect / as sysdba

SQL> alter database backup controlfile to trace resetlogs

ORACLE 加大日志文件