Focus On Oracle

Installing, Backup & Recovery, Performance Tuning,
Troubleshooting, Upgrading, Patching

当前位置: 首页 » 技术文章 » AODU

aodu(At Oracle Database Utility)之asm(一)



AODU> asm ohsdba
        asm asmcmd|asmlib|amdu|kfod|kfed|troubleshooting|note|script|passwd|reblance|general|sga
AODU> asm whoami
         Currently it's for internal use only

注意:只有使用asm ohsdba才会把asm的功能列出来

AODU> asm asmcmd   ---asmcmd命令的分类,如何使用,asm使用情况

        ****asmcmd utility reference****
        Instance Management Commands:startup,shutdown,dsget,dsset,lsct,lsop,lspwusr,orapwusr,spbackup,spcopy,spget,spmove,spset
        File Management:cd,cp,du,find,ls,lsof,mkalias,pwd,rm,rmalias
        DiskGroup Management:chdg,chkdg,dropdg,iostat,lsattr,lsdg,lsdsk,lsod,md_backup,md_restore,mkdg,mount,offline,online,rebal,remap,setattr,umount
        File Access Control:chgrp,chmod,chown,groups,grpmod,lsgrp,lsusr,mkgrp,mkusr,passwd,rmgrp,rmusr
        Template Management:chtmpl,lstmpl,mktmpl,rmtmpl
        Volume Management:volcreate,voldelete,voldisable,volenable,volinfo,volresize,volset,volstat

        cp - Enables you to copy files between ASM disk groups on local instances and remote instances.
        lsdsk -ASM can list disk information with or without a running ASM instance.This is a useful tool for system or
        storage administrators who want to obtain lists of disks that an ASM instance uses.
        md_backup and md_restore - These commands enable you to re-create a pre-xisting ASM disk group with the same disk path,disk name,
        failure groups, attributes,templates and alias directory structure.You can use md_backup to back up the disk group environment
        and use md_restore to re-create the disk group before loading from a database backup.
        -b      Specifies the location in which you want to store the intermediate backup file.
        -g      Specifies the diskgroup name that needs to be backed up.
        ASMCMD> md_backup -b /u01/backup/backup.txt -g dg_fra,dg_data

         -b     Reads the metadata information from backup_file.
         -l     Prints the messages to a file.
         -i or --silent If md_restore encounters an error, it will stop. Specifying this flag ignores any errors.
         -t     Specifies the type of diskgroup to be created:
                full - Create diskgroup and restore metadata.
                nodg - Restore metadata only.
                newdg - Create diskgroup with a different name and restore metadata, -o is required to rename.
         -f or -S       Write SQL commands to sql_script_file instead of executing them.
         -g or -G       Select the diskgroups to be restored. If no diskgroups are defined, then all diskgroups will be restored.
         -o     Rename diskgroup old_dg_name to new_dg_name.
        ASMCMD> md_restore ▒Ct nodg ▒Cg data ▒Ci backup_file
        ASMCMD> md_restore --full  -G data --silent /tmp/backup_11.bkp

        remap - You can remap and recover bad blocks on an ASM disk in normal or high redundancy that have been reported by
        storage management tools such as disk scrubbers. ASM reads from the good copy of an ASM mirror
        and rewrites these blocks to an alternate location on disk.
        asm_diskgroups= <list of diskgroups>
        asm_diskstring= 'ORCL:*' or '/dev/oracleasm/disks/*'
        asmcmd umount DATA
        asmcmd lsdg
        renamedg phase=both dgname=DATA newdgname=DG_PROD_DATA verbose=true asm_diskstring='discoverystring1','discoverystring2'
        asmcmd mount DG_PROD_DATA
        alter system set asm_diskstring= <'ORCL:*' or '/dev/rdsk/*' or '/dev/emcpower*', etc..> scope=both;
        alter system set asm_diskgroups= 'NODE2DG', 'DATA', 'RECO', 'BACKUP' scope=both;
        alter diskgroup 'DATA' mount;
        alter diskgroup 'RECO' mount;
        alter diskgroup 'BACKUP' mount;
        /etc/init.d/oracleasm  listdisks
        /etc/init.d/oracleasm scandisks
        /etc/init.d/oracleasm listdisks

        11g new feature,you can use asmcmd to copy files between remote instances
        Enables you to copy files between ASM disk groups on local instances and remote instances. You can also use this command to
        copy files from ASM disk groups to the operating system.
        cp -ifr <source file name> <user_name>@<host_name>.<Port Number>.<SID>:<targer path>/<target file name>
        user_name@host_name.<Port Number>.<SID>
        The user_name, host_name, and SID are required. The default port number is 1521.
        Example :-
        asmcmd>cp -ifr +DATA/RAC/PARAMETERFILE/spfile.257.678975489 sys@stgrac1.1521.+ASM2:+FRA/RAC/ARCHIVELOG/spfile
        We need to enable additional tracing for asmcmd connection to get a exact failure message.
        ++ set DBI_TRACE environment variable for asmcmd perl tracing.
        export DBI_TRACE=1
        ++ Now connect using asmcmd and re-produce the issue.
        The cp command failed because the target ASM file name was not specified  or File name should not contain the file
        number/incarnation.We can not copy OMF form files without specifying file name
        cp -ifr thread_2_seq_5.264.678983423 sys@bderac2-vip.1521.+ASM2:+FRA/RAC/ARCHIVELOG/thread_2_seq_5
        The file number/incarnation will be created automatically during the copy.

         export DBI_TRACE=1
        $ asmcmd
        ASMCMD> -- run the command
        $ strace -aeft -o /tmp/asmcmd.log asmcmd
        ASMCMD> -- run the command

        ****ASM files usage****
        # - ASM reports by Bane Radulovic, Oracle Corporation, 2005
        # [-db DBNAME]
        # [-db DBNAME] -space
        # [-db DBNAME] -files
        # Usage notes:
        # All arguments are optional.
        # If database name is not supplied, report on all disk groups/space/files.
        # Report on total space in all disk groups only if database name not specified.
        # Parse command line arguments
        while [ $# -gt 0 ]
          case $1 in
            -db) shift; DBNAME=$1;; # Database name
            -space) SPACE=TRUE;;    # User wants the space usage report
            -files) FILES=TRUE;;    # User wants the report on all files in db DBNAME
            -help) echo "Usage: [-db DBNAME] [-space] [-files]";exit 1;;
        echo ""
        # Get all ASM disk groups using the 'asmcmd ls' command
        for DIRECTORY in ` asmcmd ls -d % 2>/dev/null `
          echo $DIRECTORY | cut -f1 -d'/' >> /tmp/groups$$
        if [ -s /tmp/groups$$ ]
            echo "ASM instance $ORACLE_SID manages the following disk group(s):"
            echo "=================================="
            cat /tmp/groups$$
            echo ""
            echo "There are no disk groups in the ASM instance $ORACLE_SID"
            echo ""
            exit 2
        # If -files was specified, report on all files for database DBNAME
        if [ $FILES ]
            if [ $DBNAME ]
              for GRP in `cat /tmp/groups$$`
                  asmcmd find $GRP/$DBNAME % >>/tmp/files$$ 2>/dev/null
                if [ -s /tmp/files$$ ]
                    echo "$ORACLE_SID files for database $DBNAME:"
                    echo "=================================="
                    cat /tmp/files$$
                   echo "Database $DBNAME does not have any files in disk group $GRP."
              echo ""
              echo "The list of all files managed by ASM instance $ORACLE_SID:"
              echo "=================================="
              for GRP in `cat /tmp/groups$$`
                asmcmd find $GRP % 2>/dev/null

        # If -space was specified, report on the space usage per ASM group
        if [ $SPACE ]
            if [ $DBNAME ]
              for GRP in `cat /tmp/groups$$`
                asmcmd du $GRP/$DBNAME > /tmp/grp$$ 2>/dev/null
                if [ -s /tmp/grp$$ ]
                    echo "Space usage by database $DBNAME in disk group $GRP:"
                    echo "=================================="
                    cat /tmp/grp$$
                    echo ""
                    rm -f /tmp/grp$$
                    echo "Database $DBNAME does not use disk group $GRP."
              for GRP in `cat /tmp/groups$$`
                asmcmd du $GRP > /tmp/grp$$ 2>/dev/null
                if [ -s /tmp/grp$$ ]
                    echo "Total Space usage by all databases in disk group $GRP:"
                    echo "=================================="
                    cat /tmp/grp$$
                    echo ""
                    rm -f /tmp/grp$$
        # Clean up
        rm -f /tmp/groups$$
        rm -f /tmp/files$$
        rm -f /tmp/grp$$
        # All work done
        exit 0

AODU> asm asmlib   ---主要收集与asmlib相关信息,用于故障诊断

        ****Troubleshooting ASMLIB issues****
        1) In order to check if the ASMLIB API is correctly configured, please execute the next commands and provide us the output
        (from each node if this is RAC):
        # cat /etc/*release
        # uname -a
        # rpm -qa |grep oracleasm
        # df -ha
        # /usr/sbin/oracleasm configure
        # /sbin/modinfo oracleasm
        2) Check the discovery path (from each node if this is RAC):
        # /etc/init.d/oracleasm status
        # /usr/sbin/oracleasm-discover
        # /usr/sbin/oracleasm-discover 'ORCL:*'
        3) Please check if the ASMLIB devices can be accessed (from each node if this is RAC):
        # /etc/init.d/oracleasm scandisks -s  # Use "-s" option if diskgroups are mounted
        # /etc/init.d/oracleasm scandisks     # Do not use "-s" option if diskgroups are dismounted
        # /etc/init.d/oracleasm listdisks
        # /etc/init.d/oracleasm querydisk -p <each disk from previous output>
        # ls -l /dev/oracleasm/disks
        # /sbin/blkid
        # find /dev/oracleasm/disks -type b | xargs -i sh -c "echo {}; dd if={} count=100 2>/dev/null | strings"
        # cat /proc/partitions |grep sd|while read a b c d;do echo -n $d$'\t'" scsi_id=";(echo $d|tr -d [:digit:]|xargs -i scsi_id -g -s /block/{})done
        4) Upload the next files from each node if this is RAC:
        =)> /var/log/messages*
        =)> /var/log/oracleasm
        =)> /etc/sysconfig/oracleasm*
        =)> /etc/sysconfig/oracleasm-_dev_oracleasm
        5) Please show us the partition table (from each node if this is RAC):
        # cat /proc/partitions
        6) If you are using multipath devices (mapper devices or emcpower) then show me the output of:
        #  ls -l /dev/mpath/*
        #  ls -l /dev/mapper/*
        #  ls -l /dev/dm-*
        #   multipath -ll
        #  ls -l /dev/emcpower*
        Or if you have another multipath configuration then list the devices:
        # ls -l /dev/<multi path device name>*
        7) Finally connect to your ASM instance, provide me the output from the 3 scripts described in the next note (from each node if this is RAC):
            Doc ID: 470211.1 How To Gather/Backup ASM Metadata In A Formatted Manner version 10.1, 10.2, 11.1, 11.2 & 12.1?
        Note: please compress those files in just one file (*.zip or *.tar) and upload it thru Metalink.
        8) If your OS is Oracle Linux (OL), then provide the "sosreport" from all the nodes as follows (execute it as root user):
        # /usr/sbin/sosreport
        9) Also, if this is not a new ASM/ASMLIB implementation, please describe in detail what has changed since this last worked
        (OS patches, OS kernel upgrade, SAN migration, etc.)?
        Note: If you are installing UEK (Unbreakable Enterprise Kernel),therefore the Oracle ASMLib kernel driver is now included in the
        Unbreakable Enterprise Kernel. No driver package needs to be installed when using this kernel.
        The oracleasm-support and oracleasmlib packages still need to be installed from ULN (below):
        # up2date -i oracleasm-support oracleasmlib oracleasm-`uname -r`
        [root@cstdb02 database]# modinfo oracleasm

        ****oracle asm examples****
        #/etc/init.d/oracleasm start
        #/etc/init.d/oracleasm stop
        #/etc/init.d/oracleasm restart
        #/etc/init.d/oracleasm status
        #/etc/init.d/oracleasm enable
        #/etc/init.d/oracleasm disable
        #/etc/init.d/oracleasm configure
        #/etc/init.d/oracleasm createdisk DISK_NAME PARTITION_NAME
        #/etc/init.d/oracleasm createdisk VOL3 /dev/sdd1
        #/etc/init.d/oracleasm createdisk ASM_DATA /dev/cciss/c0d1p1
        #/etc/init.d/oracleasm scandisks
        #/etc/init.d/oracleasm listdisks
        #/etc/init.d/oracleasm querydisk DISK_NAME
        #/etc/init.d/oracleasm querydisk -d LABEL
        #/etc/init.d/oracleasm querydisk /dev/sdc6
        #/etc/init.d/oracleasm querydisk -d VOL6
        #/etc/init.d/oracleasm querydisk -p VOL1
        #/etc/init.d/oracleasm renamedisk PARTITION_NAME DISK_NAME
        #/etc/init.d/oracleasm renamedisk /dev/sdc1 VOL2
        #/etc/init.d/oracleasm deletedisk DISK_NAME
        #/etc/init.d/oracleasm deletedisk /dev/sdc9
        /etc/sysconfig/oracleasm  -- Oracle ASMLib configuration file

        ***gather os log****
        Solaris OS:
        =)> /var/adm/messages*
        AIX OS:
        Connect as root OS user and extract the OS logs as follow:
        =)> /bin/errpt -a > /tmp/errpt.txt
        HP-UX OS:
        =)> /var/adm/syslog/syslog.log
        =)> /usr/sbin/dmesg > /tmp/dmesg.txt
        Linux OS:
        =)> /var/log/messages*
        =)> /var/adm/messages*

AODU> asm amdu    ---amdu有用的工具,12c中asmcmd中增加了amdu extract命令行工具

        ****AMDU - ASM Metadata Dump Utility****
        AMDU is an utility to extract all the available metadata from one or more ASM disks and/or generate formatted printouts of individual blocks.
        The utility does not require that any diskgroup to be mounted.
        Oracle Support may ask you to provide AMDU output, especially when facing internal errors related to the ASM metadata
        AMDU is a dump tool, designed to obtain ASM metadata details primarily on dismounted ASM disk groups.
        Although AMDU can be run on mounted ASM disk groups, by design it is not aware if there are any dirty
        ASM metadata blocks buffered in the ASM instance buffer cache.
        Therefore,if AMDU dumps are collected while the disk group is mounted and active(ie,ongoing I/O),there is a possibility AMDU could
        interpret the dirty ASM metadata blocks cached in memory and not yet written to disk (in-flight),
        as inconsistent and thus report corrupted metadata blocks.
         How to resotore the database from AMDU after Disk corruption ?
        1. Create pfile of lost database , from database alert.log startup messages.
        2. Startup database in nomount
        3. Get the controlfile number from db alert log , it will show while starting the database here in this eg. its 256
        eg., control_files='+DATA/orcl/controlfile/current.256.709676643'
        If you have controlfile backup already in non-asm location edit the pfile to point to location of non-asm and then mount the database
        If you dont have controlfile backup then go to step 4 after determining the file# from step 3
        4. $ amdu -diskstring <asm_diskstring> -extract DATA.256
        5. shutdown the database and change the control_file location to point to the extracted file location
        6. startup mount the database
        7. once mounted, get the datafile file numbers using "select name from v$datafile"
          And get online redo logfile from "select * from v$logfile".
        8. Extract all datafiles and redolog files in similar manner
        9. alter database rename <datafile 1> to < newly extracte location>
        10. open the database

        If CHECK NOREPAIR reports no corruption on a disk group that is mounted,then AMDU ought no longer report corruption once the asm disk group
        is dismounted normal (ie, not 'dismount force). If this is a clustered environment, the disk group must be
        dismounted across all clustered ASM instances.
        Important:As a precautionary step or best practice, before attempting to dismount the ASM disk group,
        make sure RMAN back ups on the database are current, and stored in a safe place.

        Identify the object holding the corrupted block using the following query:
        SELECT tablespace_name, segment_type, owner, segment_name
        FROM dba_extents WHERE file_id = <file#> AND <block_id> between block_id AND block_id + blocks - 1
         If the block belonged to an index segment, drop and recreate the index.
         If the block belonged to a data segment either use Rman Blockrecover or restore and recover the complete datafile to fix the corruption

        AMDU executable comes with installation from 11.1 onwards. Although this tool was released with 11g, it can be used with ASM 10g as well.
        Note 553639.1 - Placeholder for AMDU binaries and using with ASM 10g
         Obtain an AMDU dump from the affected diskgroup(s) as follows (execute it as grid OS user):
        $> amdu -diskstring '<your_path_to_ASM_disks'  -dump  '<diskgroup>'
        $> <ASM Oracle Home>/bin/amdu -diskstring '<ASM disks location>/*' -dump '<diskgroup>'
        $> <ASM Oracle Home>/bin/amdu -diskstring '/dev/rhdisk*' -dump 'DATA'
        $> <ASM Oracle Home>/bin/amdu -diskstring '/dev/oracleasm/disks/*' -dump 'DATA'
        $> <ASM Oracle Home>/bin/amdu -diskstring '/dev/rdsk/*' -dump 'DATA'
        Every time AMDU is executed a directory is created on the current location, unless it is override by parameter -directory.
        The directory will have the format amdu_YYYY_MM_DD_HH24_MM_SS
        The default command  will generate following files:
        <diskgroup>_0001.img     -  a exact dump of the content of the diskgroup;size is limited to 2gb but can be more than one file
        <diskgroup>.map            -  can be used to find the exact location of the ASM metadata on the disks
        report.txt                        -  include details about the disks scanned
        The report.txt file shows the header info of the disks belonging to diskgroup, like below:
        $> amdu -diskstring '/dev/raw/raw*' -dump 'DG11'
        <report.txt content>
        ----------------------------- DISK REPORT N0003 ---------------------------
        Disk Path: /dev/raw/raw3
        Physical Sector Size: 512 bytes
        Disk Size: 977 megabytes
        Group Name: DG11
        Disk Name: DG11_0000
        Failure Group Name: DG11_0000
        ----------------------------- DISK REPORT N0004 ---------------------------
        CAUTION: DO NOT USE the above tools with options which can damage your disks, without Oracle Support guidance.

AODU> asm kfod   ---用于发现asm磁盘

        ****KFOD - Kernel Files OSM Disk****
        KFOD utility is used to simulate the disk discovery from the operating system level and it can be found in
        $GRID_HOME/bin directory (or ASM_HOME/bin in older releases).
        1) KFOD is used at installation time as well (by OUI,DBCA or ASMCA) in order to perform disk discovery.
        2) In case of a failed installation (e.g no $GRID_HOME/bin existing yet) KFOD can be found
        under your stage folder: <stage_folder>/grid/stage/ext/bin/
        In such cases you might need to set LD_LIBRARY_PATH to <stage_folder>/grid/stage/ext/lib.
        Help screen can be seen using:
        $> kfod help=y
        _asm_a/llow_only_raw_disks     KFOD allow only raw devices [_asm_allow_only_raw_disks=TRUE/(FALSE)]
        _asm_l/ibraries                       ASM Libraries[_asm_libraries='lib1','lib2',...]
        _asms/id                               ASM Instance[_asmsid=sid]
        a/sm_diskstring                      ASM Diskstring [asm_diskstring='discoverystring', 'discoverystring' ...]
        d/isks                                    Disks to discover [disks=raw,asm,all]
        g/roup                                   Group discover [group=controlfile]
        n/ohdr                                   KFOD header suppression [nohdr=TRUE/(FALSE)]
        o/p                                        KFOD options type [OP=DISKS/GROUPS/ALL]
        p/file                                     ASM parameter file [pfile='parameterfile']
        s/tatus                                   Include disk header status [status=TRUE/(FALSE)]
        v/erbose                                KFOD verbose errors [verbose=TRUE/(FALSE)]
        The usual syntax used for disk discovery is:
        kfod status=TRUE asm_diskstring='<your_path_to_ASM_devices>' disk=ALL
        $ export LD_LIBRARY_PATH=/u01/stage/
        $ /u01/stage/ status=TRUE asm_diskstring='/dev/rdsk/*' disk=all dscvgroup=TRUE
        Disk Size Header Path Disk Group User Group
        1: 10040 Mb MEMBER /dev/rdsk/c0t600144F0E08ACF0000004C2F6FBB0005d0s1  DG oracle oinstall
        2: 10040 Mb MEMBER /dev/rdsk/c0t600144F0E08ACF0000004C2F6FBC0006d0s1  DG oracle oinstall
        3: 10142 Mb MEMBER /dev/rdsk/c0t600144F0E08ACF0000004C2F6FBE0007d0s1  DG oracle oinstall
        4: 10142 Mb MEMBER /dev/rdsk/c0t600144F0E08ACF0000004C2F6FBF0008d0s1  DG oracle oinstall
        5:  9734 Mb MEMBER /dev/rdsk/c0t600144F0E08ACF0000004C2F6FC00009d0s1 FRA oracle oinstall

AODU> asm kfed   ---用于asm磁盘元数据的查看,编辑,修复等

        ****KFED - Kernel Files metadata EDitor****
        KFED is a useful tool which allows to analyze ASM disk header information when ASM diskgroups can not be mounted.
        Note 1180491.1 - KFED Tool For Windows OS.
        Note 1346190.1 - KFED.PL for diagnosing - ORA-15036 ORA-15042 ORA-15020 ORA-15033
        KFED executable comes with installation from 11.1 onwards; for the older version you must build it.
        But it is not included  the source of the software, therefore it is not available until GI installation completes.
        If you need to use it before GI being installed, please refer
        Note 1505005.1 - Where to find kfed utility before Oracle Grid Infrastructure is installed
        Help screen can be seen using:
        $>kfed help=y
        as/mlib         ASM Library [asmlib='lib']
        aun/um        AU number to examine or update [AUNUM=number]
        aus/z           Allocation Unit size in bytes [AUSZ=number]
        blkn/um       Block number to examine or update [BLKNUM=number]
        blks/z          Metadata block size in bytes [BLKSZ=number]
        ch/ksum       Update checksum before each write [CHKSUM=YES/NO]
        cn/t              Count of AUs to process [CNT=number]
        de/v            ASM device to examine or update [DEV=string]
        dm/pall        Don't suppress repeated lines when dumping corrupt blocks [DMPALL=YES/NO]
        o/p              KFED operation type [OP=READ/WRITE/MERGE/REPAIR/NEW/FORM/FIND/STRUCT]
        p/rovnm       Name for provisioning purposes [PROVNM=string]
        s/eek           AU number to seek to [SEEK=number]
        te/xt            File name for translated block text [TEXT=string]
        ty/pe           ASM metadata block type number [TYPE=number]
         The usual syntax used for reading ASM disk header is:
        $> kfed read <your_device>
        $> kfed read /dev/raw/raw1
           kfbh.endian:                       1 ; 0x000: 0x01
           kfbh.hard:                          130 ; 0x001: 0x82
           kfbh.type:                          1 ; 0x002: KFBTYP_DISKHEAD
           kfbh.datfmt:                       1 ; 0x003: 0x01
           kfbh.block.blk:                   0 ; 0x004: T=0 NUMB=0x0
           kfbh.block.obj:                   2147483648 ; 0x008: TYPE=0x8 NUMB=0x0
           kfbh.check:                        2932902794 ; 0x00c: 0xaed08b8a
           kfbh.fcn.base:                        0 ; 0x010: 0x00000000
           kfbh.fcn.wrap:                        0 ; 0x014: 0x00000000
           kfbh.spare1:                          0 ; 0x018: 0x00000000
           kfbh.spare2:                          0 ; 0x01c: 0x00000000
           kfdhdb.driver.provstr:         ORCLDISK ; 0x000: length=8
           kfdhdb.driver.reserved[0]:            0 ; 0x008: 0x00000000
           kfdhdb.driver.reserved[1]:            0 ; 0x00c: 0x00000000
           kfdhdb.driver.reserved[2]:            0 ; 0x010: 0x00000000
           kfdhdb.driver.reserved[3]:            0 ; 0x014: 0x00000000
           kfdhdb.driver.reserved[4]:            0 ; 0x018: 0x00000000
           kfdhdb.driver.reserved[5]:            0 ; 0x01c: 0x00000000
           kfdhdb.compat:                 168820736 ; 0x020: 0x0a100000
           kfdhdb.dsknum:                     0 ; 0x024: 0x0000
           kfdhdb.grptyp:                        1 ; 0x026: KFDGTP_EXTERNAL
           kfdhdb.hdrsts:                        3 ; 0x027: KFDHDR_MEMBER
           kfdhdb.dskname:               ASM01_0000 ; 0x028: length=10
           kfdhdb.grpname:               ASM01 ; 0x048: length=5
           kfdhdb.fgname:                 ASM01_0000 ; 0x068: length=10
           kfdhdb.capname:               ; 0x088: length=0
           kfdhdb.crestmp.hi:             32837774 ; 0x0a8: HOUR=0xe DAYS=0x4 MNTH=0x4 YEAR=0x7d4
           kfdhdb.crestmp.lo:             1555722240 ; 0x0ac: USEC=0x0 MSEC=0x29c SECS=0xb MINS=0x17
           kfdhdb.mntstmp.hi:            32837774 ; 0x0b0: HOUR=0xe DAYS=0x4 MNTH=0x4 YEAR=0x7d4
           kfdhdb.mntstmp.lo:            1563864064 ; 0x0b4: USEC=0x0 MSEC=0x1ab SECS=0x13 MINS=0x17
           kfdhdb.ub4spare[60]:         0 ; 0x1d0: 0x00000000
           kfdhdb.acdb.aba.seq:         0 ; 0x1d4: 0x00000000
           kfdhdb.acdb.aba.blk:          0 ; 0x1d8: 0x00000000
           kfdhdb.acdb.ents:              0 ; 0x1dc: 0x0000
           kfdhdb.acdb.ub2spare:        0 ; 0x1de: 0x0000

        1) KFED returns a readable output only when devices are/were part of an ASM diskgroup.
        Otherwise (if the device hasn't been added to a diskgroup yet or the disk is not valid anymore) the output looks like:
        KFED-00322: Invalid content encountered during block traversal: [kfbtTraverseBlock][Invalid OSM block type][][0]
        2) In case of a non-default AU size, you should specify it in the command:
        $> kfed read <your_device> AUSZ=<au_size>

AODU> asm troubleshooting    ---asm故障诊断

        ****ASM 11gR2 instance Can Not Mount OCR/Voting Diskgroup On RAC****
         1) Please create a temporary pfile (on node #1 (+ASM1), with the next values on the <Grid Infrastructure Oracle Home>/dbs/init+ASM1.ora:
        2) Then startup the +ASM1 instance:
        $> cd < Grid Infrastructure Oracle Home>/dbs/
        $> export ORACLE_SID=+ASM1
        $> sqlplus / as sysasm
        SQL> STARTUP pfile=init+ASM1.ora
        3) Recreate the spfile
        SQL> create spfile='+OCRVDG' from pfile='/opt/grid/product/11.2.0/grid_1/dbs/init+ASM1.ora';
        File created.
        4) Restarted the OHAS/CRS stack on both nodes:
        4.1) Please shutdown all the services on both nodes as follow:
        Node #1:
        Connect as root user:
        # /opt/grid/product/11.2.0/grid_1/bin/crsctl stop crs
        Node #2:
        Connect as root user:
        # /opt/grid/product/11.2.0/grid_1/bin/crsctl stop crs
        4.2) Verify that the Grid Infrastructure stack has shutdown successfully on both nodes.
        The following command should show no output if the GI stack has shutdown:
        # ps -ef | grep diskmo[n]
        4.3) Start the Grid Infrastructure stack on the first node:
        # /opt/grid/product/11.2.0/grid_1/bin/crsctl start crs
        4.4) Wait until the Grid Infrastructure stack has started successfully on the first node. To check the status of the Grid Infrastructure stack,
        run the following command and verify that the "ora.asm" instance is started. Note that the command below will continue to
        report that it is unable to communicate with the Grid Infrastructure software for several minutes
        after issuing the "crsctl start crs" command above:
        # /opt/grid/product/11.2.0/grid_1/bin/crsctl status resource -t
        4.5) Start the Grid Infrastructure stack on the remaining node:
        # /opt/grid/product/11.2.0/grid_1/bin/crsctl start crs
        4.6) Monitor the startup progress (this could take several minutes):
        # /opt/grid/product/11.2.0/grid_1/bin/crsctl status resource -t
        4.7) Verify OHAS, CRS & CSS are running on each node:
        $> crsctl check has
        $> crsctl check crs
        $> crsctl check css



aodu(At Oracle Database Utility)之optim
aodu(At Oracle Database Utility)之asm(二)
aodu(At Oracle Database Utility)之asm(一)
aodu(At Oracle Database Utility)之rac(二)
aodu(At Oracle Database Utility)之rac(一)
aodu(At Oracle Database Utility)之ora600
aodu(At Oracle Database Utility)之asmdisk
aodu(At Oracle Database Utility)之unwrap
aodu(At Oracle Database Utility)之rdba
aodu(At Oracle Database Utility)之drux
aodu(At Oracle Database Utility)之time
aodu(At Oracle Database Utility)之odlog




    微  信: ohsdba





My Oracle Support

Exadata 12.1 Document

Exadata 12.2 Document

Oracle 11gR2 Document

Oracle 12cR1 Document

Oracle 12cR2 Document

GoldenGate 12c

Oracle Fusion Middleware

Mysql Document





QQ 375349564