Roby's profileblue_princePhotosBlogListsMore Tools Help

Blog


    June 24

    AIX下ASM配置出错处理

    在配置AIX的ASM时,执行localconfig add报错,出错信息如下:
     
    test:/@root>#/u01/oracle/product/10.2/bin/localconfig add
    /etc/oracle does not exist. Creating it now.
    exec(): 0509-036 Cannot load program crsctl.bin because of the following errors:
            0509-130 Symbol resolution failed for crsctl.bin because:
            0509-136   Symbol _Getctype__FPCc (number 102) is not exported from
                       dependent module /usr/lib/libC.a[ansi_64.o].
            0509-136   Symbol _Getnumpunct__FPCc (number 106) is not exported from
                       dependent module /usr/lib/libC.a[ansi_64.o].
            0509-136   Symbol __ct__Q2_3std8_LocinfoFPCci (number 176) is not exported from
                       dependent module /usr/lib/libC.a[ansi_64.o].
            0509-192 Examine .loader section symbols with the
                     'dump -Tv' command.
    Successfully accumulated necessary OCR keys.
    Creating OCR keys for user 'root', privgrp 'system'..
    Operation successful.
    Configuration for local CSS has been initialized
    Adding to inittab
    A file or directory in the path name does not exist.
    /etc/init.cssd[911]: /etc/oracle/scls_scr/test/root/cssrun: 0403-005 Cannot create the specified file.
    Startup will be queued to init within 30 seconds.
    Checking the status of new Oracle init process...
    exec(): 0509-036 Cannot load program crsctl.bin because of the following errors:
            0509-130 Symbol resolution failed for crsctl.bin because:
            0509-136   Symbol _Getctype__FPCc (number 102) is not exported from
                       dependent module /usr/lib/libC.a[ansi_64.o].
            0509-136   Symbol _Getnumpunct__FPCc (number 106) is not exported from
                       dependent module /usr/lib/libC.a[ansi_64.o].
            0509-136   Symbol __ct__Q2_3std8_LocinfoFPCci (number 176) is not exported from
                       dependent module /usr/lib/libC.a[ansi_64.o].
            0509-192 Examine .loader section symbols with the
                     'dump -Tv' command.
    Giving up: Oracle CSS stack appears NOT to be running.
    Oracle CSS service would not start as installed
    Automatic Storage Management(ASM) cannot be used until Oracle CSS service is started
     
    出现这个错误是由于AIX5.3自带的xlC的版本太低所致,需要到IBM的网站上下个新版本的xlC(推荐版本9以后)安装好后再配置,就可以解决问题:
     
    test:/xlc@root>#/u01/oracle/product/10.2/bin/localconfig reset /u01/oracle/product/10.2               
    Successfully accumulated necessary OCR keys.
    Creating OCR keys for user 'root', privgrp 'system'..
    Operation successful.
    Configuration for local CSS has been initialized
    Adding to inittab
    Startup will be queued to init within 30 seconds.
    Checking the status of new Oracle init process...
    Expecting the CRS daemons to be up within 600 seconds.
    CSS is active on these nodes.
            test
    CSS is active on all nodes.
    Oracle CSS service is installed and running under init(1M)

    配置基于ASM存储的STANDBY时日志文件的处理

    在配置基于ASM存储的STANDBY时,由于控制文件里面记录的联机日志还是原来主库日志文件的信息,因此需要对其做进一步处理。就算是设置了log_file_name_convert这个参数,假如主库的联机日志有两组成员,那么只会有一组成员转换为log_file_name_convert设置的对应ASM目录,另外一个成员还会是原来的目录,另外STANDBY LOGFILE的联机日志目录也不会更改。比如日志文件配置如下,我们看一下整个操作过程:
     
    Thread Group                       Member       Archived        Status         (MB)
    ------ ----- ---------------------------------- ---------- ---------------- -------
         1     1 /oradata/datafile/redo1_01.log     YES        CLEARING            1000
         1     1 +DATA/db/onlinelog/redo1_02.log    YES        CLEARING            1000
         1     2 /oradata/datafile/redo1_01.log     YES        CLEARING_CURRENT    1000
         1     2 +DATA/db/onlinelog/redo2_02.log    YES        CLEARING_CURRENT    1000
         1     3 /oradata/datafile/redo3_01.log     YES        CLEARING            1000
         1     3 +DATA/db/onlinelog/redo3_02.log    YES        CLEARING            1000
     
    Group                       Member       Archived        Status         (MB)
    ----- --------------------------------   ---------- ---------------- -------
       11  /oradata/datafile/redo1_01.log        NO         UNASSIGNED          1000
       12  /oradata/datafile/redo1_01.log        YES        ACTIVE              1000
       13  /oradata/datafile/redo1_01.log        NO         UNASSIGNED          1000
       14  /oradata/datafile/redo1_01.log        YES        UNASSIGNED          1000
     
    首先处理STANDBY LOGFILE,可以把所有的STANDBY LOGFILE GROUP都删除掉重建就行了:
     
    alter database drop standby logfile group 11;
    alter database drop standby logfile group 12;
    alter database drop standby logfile group 13;
    alter database drop standby logfile group 14;
    alter database add standby logfile group 11 ('+data') size 1000M;
    alter database add standby logfile group 12 ('+data') size 1000M;
    alter database add standby logfile group 13 ('+data') size 1000M;
    alter database add standby logfile group 14 ('+data') size 1000M;
     
    对于联机日志,则需要先把各组日志里面不转换为ASM目录的那组成员先删除掉,但是STATUS为CLEARING_CURRENT那组日志成员是无法删除的,可以后续再处理:
     
    alter database drop logfile member '/oradata/datafile/redo1_01.log';  
    alter database drop logfile member '/oradata/datafile/redo3_01.log'; 
     
    然后再将对应的日志组CLEAR掉再DROP,由于数据库至少需要两组联机日志,因此只能删除一组联机日志并重建好后才能再处理另一组:
     
    alter database clear logfile group 1;
    alter database drop logfile group 1;
    alter database add logfile group 1 ('+data','+data') size 1000M;
    alter database clear logfile group 3;
    alter database drop logfile group 3;
    alter database add logfile group 3 ('+data','+data') size 1000M;
     
    等日志组2的状态从CLEARING_CURRENT变成其他状态后,再进一步处理就可以了:
     
    alter database drop logfile member '/oradata/datafile/redo2_01.log';
    alter database clear logfile group 2;
    alter database drop logfile group 2;
    alter database add logfile group 2 ('+data','+data') size 1000M;
    June 23

    RMAN restore时ORA-27067错误处理

    今天在对一个数据库进行RESTORE时一直报ORA-27067,百思不得其解,后面查了下,得知要把备份集改成可读写才行。由于我的数据库备份是备份在NFS上面的,直接把备份集的权限改为666,问题解决。