kingsql 如何修改Oralce日誌檔案大小
如果日誌頻繁切換,就需要增加日誌檔案的大小
>select GROUP#,STATUS,MEMBER from v$logfile;
GROUP# STATUS MEMBER
---------- ------- --------------------------------------------------
3 STALE /u01/app/oracle/oradata/hzh/redo03.log
2 STALE /u01/app/oracle/oradata/hzh/redo02.log
1 /u01/app/oracle/oradata/hzh/redo01.log
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 1 CURRENT NO 50M
2 1 INACTIVE YES 50M
3 1 INACTIVE YES 50M
>alter database add logfile group 4 ('/u01/app/oracle/oradata/hzh/redo04.log','/u01/app/oracle/oradata/hzh/redo04b.log') size 200M;
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 1 CURRENT NO 50M
2 1 INACTIVE YES 50M
3 1 INACTIVE YES 50M
4 2 UNUSED YES 200M
>alter database drop logfile group 2;
Database altered.
>alter database drop logfile group 3;
Database altered.
>alter system switch logfile;
System altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 1 ACTIVE YES 50M
4 2 CURRENT NO 200M
[oracle@hong ~]$ cd /u01/app/oracle/oradata/hzh/
[oracle@hong hzh]$ rm redo02* redo03*
>alter database add logfile group 2 ('/u01/app/oracle/oradata/hzh/redo02.log','/u01/app/oracle/oradata/hzh/redo02b.log') size 200M;
Database altered.
>alter database add logfile group 3 ('/u01/app/oracle/oradata/hzh/redo03.log','/u01/app/oracle/oradata/hzh/redo03b.log') size 200M;
Database altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 1 INACTIVE YES 50M
2 2 UNUSED YES 200M
3 2 UNUSED YES 200M
4 2 CURRENT NO 200M
>alter database drop logfile group 1;
Database altered.
[oracle@hong hzh]$ rm redo01.log
>alter database add logfile group 1 ('/u01/app/oracle/oradata/hzh/redo01.log','/u01/app/oracle/oradata/hzh/redo01b.log') size 200M;
Database altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 2 UNUSED YES 200M
2 2 UNUSED YES 200M
3 2 UNUSED YES 200M
4 2 CURRENT NO 200M
>alter system switch logfile;
System altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 2 CURRENT NO 200M
2 2 UNUSED YES 200M
3 2 UNUSED YES 200M
4 2 ACTIVE YES 200M
>alter system switch logfile;
System altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 2 ACTIVE YES 200M
2 2 CURRENT NO 200M
3 2 UNUSED YES 200M
4 2 INACTIVE YES 200M
到此,已經修改完了,後面的步驟,純屬個人潔癖
>alter database drop logfile group 4;
Database altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 2 ACTIVE YES 200M
2 2 CURRENT NO 200M
3 2 UNUSED YES 200M
[oracle@hong hzh]$ rm redo04*
kingsql作品
如有建議請回帖或發電子郵件至
★希望向高手學習、同時幫助新手★
>select GROUP#,STATUS,MEMBER from v$logfile;
GROUP# STATUS MEMBER
---------- ------- --------------------------------------------------
3 STALE /u01/app/oracle/oradata/hzh/redo03.log
2 STALE /u01/app/oracle/oradata/hzh/redo02.log
1 /u01/app/oracle/oradata/hzh/redo01.log
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 1 CURRENT NO 50M
2 1 INACTIVE YES 50M
3 1 INACTIVE YES 50M
>alter database add logfile group 4 ('/u01/app/oracle/oradata/hzh/redo04.log','/u01/app/oracle/oradata/hzh/redo04b.log') size 200M;
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 1 CURRENT NO 50M
2 1 INACTIVE YES 50M
3 1 INACTIVE YES 50M
4 2 UNUSED YES 200M
>alter database drop logfile group 2;
Database altered.
>alter database drop logfile group 3;
Database altered.
>alter system switch logfile;
System altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 1 ACTIVE YES 50M
4 2 CURRENT NO 200M
[oracle@hong ~]$ cd /u01/app/oracle/oradata/hzh/
[oracle@hong hzh]$ rm redo02* redo03*
>alter database add logfile group 2 ('/u01/app/oracle/oradata/hzh/redo02.log','/u01/app/oracle/oradata/hzh/redo02b.log') size 200M;
Database altered.
>alter database add logfile group 3 ('/u01/app/oracle/oradata/hzh/redo03.log','/u01/app/oracle/oradata/hzh/redo03b.log') size 200M;
Database altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 1 INACTIVE YES 50M
2 2 UNUSED YES 200M
3 2 UNUSED YES 200M
4 2 CURRENT NO 200M
>alter database drop logfile group 1;
Database altered.
[oracle@hong hzh]$ rm redo01.log
>alter database add logfile group 1 ('/u01/app/oracle/oradata/hzh/redo01.log','/u01/app/oracle/oradata/hzh/redo01b.log') size 200M;
Database altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 2 UNUSED YES 200M
2 2 UNUSED YES 200M
3 2 UNUSED YES 200M
4 2 CURRENT NO 200M
>alter system switch logfile;
System altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 2 CURRENT NO 200M
2 2 UNUSED YES 200M
3 2 UNUSED YES 200M
4 2 ACTIVE YES 200M
>alter system switch logfile;
System altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 2 ACTIVE YES 200M
2 2 CURRENT NO 200M
3 2 UNUSED YES 200M
4 2 INACTIVE YES 200M
到此,已經修改完了,後面的步驟,純屬個人潔癖
>alter database drop logfile group 4;
Database altered.
>select GROUP#,MEMBERS,STATUS,ARCHIVED,BYTES/1024/1024||'M' bt from v$log;
GROUP# MEMBERS STATUS ARC BT
---------- ---------- ---------------- --- ----------
1 2 ACTIVE YES 200M
2 2 CURRENT NO 200M
3 2 UNUSED YES 200M
[oracle@hong hzh]$ rm redo04*
kingsql作品
如有建議請回帖或發電子郵件至
★希望向高手學習、同時幫助新手★
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/28389881/viewspace-756331/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 增加日誌檔案,修改當前日誌檔案大小
- 線上修改重做日誌檔案的大小
- 修改Oracle重做日誌檔案的大小Oracle
- 修改online redo日誌檔案大小
- 日誌檔案的大小
- 如何更改線上重做日誌檔案的大小
- MySQL 修改InnoDB重做日誌檔案的數量或大小MySql
- 改變日誌檔案大小
- 改變歸檔日誌檔案大小
- Postgres使用pg_resetwal命令修改wal日誌檔案大小的方法
- 限制 Apache日誌檔案大小的方法Apache
- 【Oracle】如何修改資料檔案和日誌檔案的路徑Oracle
- 【kingsql分享】RAC擴大online日誌組大小SQL
- 日誌檔案和歸檔日誌檔案的關係以及如何切換日誌
- oracle 修改日誌大小及增加日誌成員Oracle
- Oralce資料庫關閉歸檔日誌並且刪除歸檔日誌資料庫
- 日誌檔案太大,壓縮後,限制檔案的大小,但出現日誌檔案已經滿的告警
- 歸檔日誌大小統計
- 修改上傳檔案大小
- apache 訪問日誌如何設定每日新增一個日誌檔案、如何限制大小、設定記錄內容Apache
- 【Oracle日誌】- 日誌檔案重建Oracle
- 日誌檔案
- 修改歸檔日誌路徑
- MySQL 5.6修改REDO日誌的大小和個數MySql
- 刪除日誌檔案組與日誌檔案成員
- 更改RAC資料庫日誌檔案大小及數量 for ASM資料庫ASM
- 如何設定redo log的OMF 及如何修改log檔案大小
- 管理日誌檔案
- dump日誌檔案
- APACHE日誌檔案Apache
- OGG 修改trail 檔案的大小AI
- oralce密碼檔案要注意SID的大小寫問題密碼
- Linux 日誌檔案系統如何工作Linux
- 如何正確刪除ORACLE歸檔日誌檔案Oracle
- 控制檔案/歸檔日誌
- nxlog4go 按天或按檔案大小分割日誌Go
- 對日誌檔案組和日誌檔案組成員的管理
- 線上修改REDO LOG的大小及增加新的日誌組