欢迎光临
我们一直在努力

在RAC环境中如何管理日志(redolog file)组-数据库专栏,SQL Server

建站超值云服务器,限时71元/月

在rac环境中如何管理日志(redolog file)组

tuesday, 2004-09-14 11:52 eygle 
    
 
 原文连接:

http://www.eygle.com/faq/how.to.mangement.redologfile.in.rac.raw.htm

本文简单介绍在rac裸设备环境下如何管理日志文件(redolog file)

本文环境:oracle9i rac + vcs4.0 + vxvm4.0 + solaris9.0 + sunfire210

1.首先可以查看当前裸设备情况

# vxprintdisk group: oradgty name assoc kstate length ploffs state tutil0 putil0dg oradg oradg – – – – – -dm oradg01 c2t0d2s2 – 244143872 – – – -v ctlfile1 gen enabled 204800 – active – -pl ctlfile1-01 ctlfile1 enabled 204800 – active – -sd oradg01-13 ctlfile1-01 enabled 204800 0 – – -v ctlfile2 gen enabled 204800 – active – -pl ctlfile2-01 ctlfile2 enabled 204800 – active – -sd oradg01-14 ctlfile2-01 enabled 204800 0 – – -v redo101 gen enabled 204800 – active – -pl redo101-01 redo101 enabled 204800 – active – -sd oradg01-04 redo101-01 enabled 204800 0 – – -v redo102 gen enabled 204800 – active – -pl redo102-01 redo102 enabled 204800 – active – -sd oradg01-05 redo102-01 enabled 204800 0 – – -v redo103 gen enabled 204800 – active – -pl redo103-01 redo103 enabled 204800 – active – -sd oradg01-06 redo103-01 enabled 204800 0 – – -v redo201 gen enabled 204800 – active – -pl redo201-01 redo201 enabled 204800 – active – -sd oradg01-07 redo201-01 enabled 204800 0 – – -v redo202 gen enabled 204800 – active – -pl redo202-01 redo202 enabled 204800 – active – -sd oradg01-08 redo202-01 enabled 204800 0 – – -v redo203 gen enabled 204800 – active – -pl redo203-01 redo203 enabled 204800 – active – -sd oradg01-09 redo203-01 enabled 204800 0 – – -v spfile gen enabled 204800 – active – -pl spfile-01 spfile enabled 204800 – active – -sd oradg01-12 spfile-01 enabled 204800 0 – – -v srvcfg gen enabled 1024000 – active – -pl srvcfg-01 srvcfg enabled 1024000 – active – -sd oradg01-15 srvcfg-01 enabled 1024000 0 – – -v system gen enabled 1638400 – active – -pl system-01 system enabled 1638400 – active – -sd oradg01-01 system-01 enabled 1638400 0 – – -v temp gen enabled 2048000 – active – -pl temp-01 temp enabled 2048000 – active – -sd oradg01-02 temp-01 enabled 2048000 0 – – -v undo11 gen enabled 16777216 – active – -pl undo11-01 undo11 enabled 16777216 – active – -sd oradg01-10 undo11-01 enabled 2048000 0 – – -sd oradg01-17 undo11-01 enabled 14729216 2048000 – – -v undo21 gen enabled 2048000 – active – -pl undo21-01 undo21 enabled 2048000 – active – -sd oradg01-11 undo21-01 enabled 2048000 0 – – -v users gen enabled 16777216 – active – -pl users-01 users enabled 16777216 – active – -sd oradg01-03 users-01 enabled 2048000 0 – – -sd oradg01-16 users-01 enabled 14729216 2048000 – – –

2.分配新的裸设备并设置相应的权限

这一步需要以root身份执行

 

# vxassist -g oradg -u gen make redo104 100m
# vxassist -g oradg -u gen make redo105 100m
# vxedit -g oradg set user=oracle mode=644 redo104
# vxedit -g oradg set user=oracle mode=644 redo105

 

3.重新规划redolog file组

$ sqlplus “/ as sysdba”sql*plus: release 9.2.0.4.0 – production on tue sep 14 10:02:47 2004copyright (c) 1982, 2002, oracle corporation. all rights reserved.connected to:oracle9i enterprise edition release 9.2.0.4.0 – 64bit productionwith the real application clusters optionjserver release 9.2.0.4.0 – productionsql> set linesize 120sql> select * from v$log; group# thread# sequence# bytes members arc status first_change# first_tim———- ———- ———- ———- ———- — —————- ————- ——— 1 1 6313 52428800 1 no active 3193855 14-sep-04 2 1 6312 52428800 1 no inactive 3191691 14-sep-04 5 1 6314 52428800 1 no current 3196041 14-sep-04 3 2 17 10485760 1 no current 3016310 14-sep-04 4 2 16 10485760 1 no inactive 1619198 13-sep-04sql> alter database add logfile thread 1 group 6 (/dev/vx/rdsk/oradg/redo104) size 90m;database altered.sql> alter database add logfile thread 1 group 7 (/dev/vx/rdsk/oradg/redo105) size 90m;database altered.sql> select * from v$log; group# thread# sequence# bytes members arc status first_change# first_tim———- ———- ———- ———- ———- — —————- ————- ——— 1 1 6316 52428800 1 no inactive 3200415 14-sep-04 2 1 6315 52428800 1 no inactive 3198233 14-sep-04 5 1 6317 52428800 1 no active 3202621 14-sep-04 6 1 6318 94371840 1 no current 3204811 14-sep-04 7 1 0 94371840 1 yes unused 0 3 2 17 10485760 1 no current 3016310 14-sep-04 4 2 16 10485760 1 no inactive 1619198 13-sep-047 rows selected.sql> alter database drop logfile group 5;database altered.sql> alter database add logfile thread 1 group 5 (/dev/vx/rdsk/oradg/redo103) size 90m;database altered…..sql> select *from v$log; group# thread# sequence# bytes members arc status first_change# first_tim———- ———- ———- ———- ———- — —————- ————- ——— 1 1 6327 94371840 1 no inactive 3238534 14-sep-04 2 1 6329 94371840 1 no current 3246417 14-sep-04 5 1 0 94371840 1 yes unused 0 6 1 6328 94371840 1 no active 3242482 14-sep-04 7 1 6326 94371840 1 no inactive 3234597 14-sep-04 3 2 17 10485760 1 no current 3016310 14-sep-04 4 2 16 10485760 1 no inactive 1619198 13-sep-047 rows selected.

 

赞(0)
版权申明:本站文章部分自网络,如有侵权,请联系:west999com@outlook.com 特别注意:本站所有转载文章言论不代表本站观点! 本站所提供的图片等素材,版权归原作者所有,如需使用,请与原作者联系。未经允许不得转载:IDC资讯中心 » 在RAC环境中如何管理日志(redolog file)组-数据库专栏,SQL Server
分享到: 更多 (0)