Home > Database > Mysql Tutorial > body text

Oracle归档日志大小的修改方法

WBOY
Release: 2016-06-07 16:58:26
Original
1221 people have browsed it

Oracle归档日志相信大家都不会陌生,下面就为您介绍Oracle归档日志大小的修改方法,希望对您学习Oracle归档日志方面能够有所

  Oracle归档日志相信大家都不会陌生,,下面就为您介绍Oracle归档日志大小的修改方法,希望对您学习Oracle归档日志方面能够有所帮助。

  方法:加入新的大的日志文件,然后删掉旧的小的日志文件

  假设现有三个日志组,每个组内有一个成员,每个成员的大小为1MB,现在想把此三个日志组的成员大小都改为10MB

  1、创建2个新的日志组
  1.alter database add logfile group 4 ('D:\ORACLE\ORADATA\ORADB\REDO04_1.LOG') size 1024k;
  2.alter database add logfile group 5 ('D:\ORACLE\ORADATA\ORADB\REDO05_1.LOG') size 1024k;

  2、切换当前日志到新的日志组
  1.alter system switch logfile;
  2.alter system switch logfile;

  3、删除旧的日志组
  1.alter database drop logfile group 1;
  2.alter database drop logfile group 2;
  3.alter database drop logfile group 3;

  4、操作系统下删除原日志组1、2、3中的文件

  5、重建日志组1、2、3
  1.alter database add logfile group 1 ('D:\ORACLE\ORADATA\ORADB\REDO01_1.LOG') size 10M;
  2.alter database add logfile group 2 ('D:\ORACLE\ORADATA\ORADB\REDO02_1.LOG') size 10M;
  3.alter database add logfile group 3 ('D:\ORACLE\ORADATA\ORADB\REDO03_1.LOG') size 10M;

  6、切换日志组
  1.alter system switch logfile;
  2.alter system switch logfile;
  3.alter system switch logfile;

  7、删除中间过渡用的日志组4、5
  1.alter database drop logfile group 4;
  2.alter database drop logfile group 5;

  8、到操作系统下删除原日志组4、5中的文件

  9、备份当前的最新的控制文件
  1.SQL> connect internal
  2.SQL> alter database backup controlfile to trace resetlogs

linux

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template