How to resize ASM disks

Hi! I have Oracle RAC on Centos with one active node and share storage HP MSA1500 12x500 Gb FC. Also, i have two servers which i want install new rac database.
[oracle@server ~]$ crsctl query css votedisk
0. 0 /u04/sync/oracrs/CSSFile
located 1 votedisk(s).
[oracle@server ~]$ ocrcheck
Status of Oracle Cluster Registry is as follows :
Version : 2
Total space (kbytes) : 262120
Used space (kbytes) : 1672
Available space (kbytes) : 260448
ID : 1521772939
Device/File Name : /u04/sync/oracrs/CRSFile
Device/File integrity check succeeded
Device/File not configured
Cluster registry integrity check succeeded
[oracle@server ~]$
CRS & CSS install on ocfs.
Затем, через oracleasm
[oracle@server ~]$ /etc/init.d/oracleasm listdisks
VOL8
VOL9
[oracle@server ~]$
[root@server ~]# /etc/init.d/oracleasm querydisk /dev/sda1
Disk "/dev/sda1" is not marked an ASM disk
[root@server ~]# /etc/init.d/oracleasm querydisk /dev/sdb1
Disk "/dev/sdb1" is marked an ASM disk with the label ""
[root@server ~]# /etc/init.d/oracleasm querydisk /dev/sdc1
Disk "/dev/sdc1" is marked an ASM disk with the label ""
[root@server ~]# /etc/init.d/oracleasm querydisk /dev/sdd1
Disk "/dev/sdd1" is marked an ASM disk with the label "VOL8"
[root@server ~]# /etc/init.d/oracleasm querydisk /dev/sdd2
Disk "/dev/sdd2" is marked an ASM disk with the label "VOL9"
[root@server ~]# /etc/init.d/oracleasm querydisk /dev/sdd3
Disk "/dev/sdd3" is not marked an ASM disk
[root@server ~]#
[root@server ~]# fdisk -l
Disk /dev/cciss/c0d0: 72.8 GB, 72833679360 bytes
255 heads, 32 sectors/track, 17433 cylinders
Units = cylinders of 8160 * 512 = 4177920 bytes
Device Boot Start End Blocks Id System
/dev/cciss/c0d0p1 * 1 50 203984 83 Linux
/dev/cciss/c0d0p2 51 1305 5120400 82 Linux swap
/dev/cciss/c0d0p3 1306 17433 65802240 83 Linux
Disk /dev/sda: 1048 MB, 1048657920 bytes
33 heads, 61 sectors/track, 1017 cylinders
Units = cylinders of 2013 * 512 = 1030656 bytes
Device Boot Start End Blocks Id System
/dev/sda1 1 1017 1023580 83 Linux
Disk /dev/sdb: 500.0 GB, 500071791104 bytes
255 heads, 63 sectors/track, 60796 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 60796 488343838+ 83 Linux
Disk /dev/sdc: 499.0 GB, 499025092608 bytes
255 heads, 63 sectors/track, 60669 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdc1 1 60669 487323711 83 Linux
Disk /dev/sdd: 500.0 GB, 500073750528 bytes
255 heads, 63 sectors/track, 60797 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdd1 1 1000 8032468+ 83 Linux
/dev/sdd2 1001 2000 8032500 83 Linux
/dev/sdd3 2001 3000 8032500 83 Linux
[root@server ~]#
Than in sqlplusi see, what disks use ASM:
SQL> select name, total_mb, free_mb,path from v$asm_disk;
NAME TOTAL_MB FREE_MB PATH
VOL1 476898 431798 /dev/raw/raw1
VOL2 475902 475379 /dev/raw/raw2
SQL> select name, total_mb, free_mb from v$asm_diskgroup;
NAME TOTAL_MB FREE_MB
DATA 476898 431798
RECOVERY_AREA 475902 475379
SQL> select name, type from V$asm_diskgroup;
NAME TYPE
DATA EXTERN
RECOVERY_AREA EXTERN
Also i see what disks use diskgroups DATA and RECOVERY:
[root@server ~]# cat /etc/sysconfig/rawdevices
# This file and interface are deprecated.
# Applications needing raw device access should open regular
# block devices with O_DIRECT.
# raw device bindings
# format: <rawdev> <major> <minor>
# <rawdev> <blockdev>
# example: /dev/raw/raw1 /dev/sda1
# /dev/raw/raw2 8 5
/dev/raw/raw1 /dev/sdb1
/dev/raw/raw2 /dev/sdc1
/dev/raw/raw8 /dev/sdd1
/dev/raw/raw9 /dev/sdd2
[root@server ~]#
[root@server ~]# mount
/dev/cciss/c0d0p3 on / type ext3 (rw)
none on /proc type proc (rw)
none on /sys type sysfs (rw)
none on /dev/pts type devpts (rw,gid=5,mode=620)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/cciss/c0d0p1 on /boot type ext3 (rw)
none on /dev/shm type tmpfs (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
configfs on /config type configfs (rw)
ocfs2_dlmfs on /dlm type ocfs2_dlmfs (rw)
/dev/sda1 on /u04/sync type ocfs2 (rw,_netdev,datavolume,nointr,heartbeat=local)
oracleasmfs on /dev/oracleasm type oracleasmfs (rw)
[root@server ~]#
[root@server ~]# ls -l /dev/oracleasm/disks/
total 0
brw-rw---- 1 oracle dba 8, 49 Aug 8 19:34 VOL8
brw-rw---- 1 oracle dba 8, 50 Aug 8 19:34 VOL9
[root@server ~]#
How i could resize asm disk from 450 G for example to 100 Gb for my new rac installation?
Sorry for my english:(

Hi mmusette, hi all,
please, allow a little clarification. ASM allows resizing disks:
From: http://download.oracle.com/docs/cd/B19306_01/server.102/b14231/storeman.htm#sthref1727
Resizing Disks in Disk Groups+
The RESIZE clause of ALTER DISKGROUP enables you to perform the following operations:
Resize all disks in the disk group
Resize specific disks
Resize all of the disks in a specified failure group
If you do not specify a new size in the SIZE clause then ASM uses the size of the disk as returned by the operating system. This could be a means of recovering disk space when you had previously restricted the size of the disk by specifying a size smaller than disk capacity.
The new size is written to the ASM disk header record and if the size of the disk is increasing, then the new space is immediately available for allocation. If the size is decreasing, rebalancing must relocate file extents beyond the new size limit to available space below the limit. If the rebalance operation can successfully relocate all extents, then the new size is made permanent, otherwise the rebalance fails.
However, if you have setup the ASM disk on a physical disk partition, you probably will not be able to resize the partition without destroying the data on the disk. If you, however, used a volume manager to create volumes and you based your ASM disks on those volumes (through RAW devices or directly) AND your volume manager allows resizing the volumes, you should be able to make use of the command mentioned above.
Thanks,
Markus

Similar Messages

  • How to add ASM Disk to Disk Group that is shown as MEMBER?

    HI,
    We have a Production Oracle RAC on HP-UX. We have Two Disk Groups one for Arcive (ARC_DISK) and other for Database(DATA_DISK).
    Today I wanted to add another 200 GB of Disk Space to the DATA_DISK Group.
    I opened DBCA and could not find the new disk in the 'Show Candidates' option. But after the Unix admin changed the ownership and permission of the Disk, it was shown in 'Show Candidates' option. I selected this Disk and continued but got an error later as we didnt change the ownership and permission from the 2nd Unix server. After doing this, , when I open DBCA to add disk, nothing is shown in 'Show Candidates' option but when we click on 'Show All', the new disk is listed as MEMBER (header status) but not allocated to any Disk Group.
    I would like to know how to allocate this Disk (which is already shown as MEMBER) to the DATA_DISK - ASM diskgroup. This is a production database system.
    Rgds,
    Thiru

    user1983888 wrote:
    Hi,
    Due to huge difference in Disk Size which I am trying to add to the existing Disk Group which has 1024 GB of Disk, would it be a better idea to create a new Disk Group with 200g GB Disk? Will this command work as the header_status is already MEMBER?
    SQL>CREATE DISKGROUP DATA_DISK1
    EXTERNAL REDUNDANCY
    DISK 'disk path';
    Thanks.Yes, you can create new diskgroup (DATA_DISK1). Just make sure all datafile in DATA_DISK autoextend off, then create all your new datafile to the new diskgroup DATA_DISK1. The command will not work as the header_status is MEMBER. You'll receive ORA-15018 & ORA-15033 error. As I mentioned before, you need to use FORCE option or format the disk using dd* command before perform above command.
    1st Option : (Format the raw disk using dd command creating new diskgroup. Header_status MEMBER -> CANDIDATE). E.g.
    1. dd if=/dev/zero of=/dev/rdsk/c2t1d0 bs=8192 count=1000 //any rac nodes
    2. # chown oracle:oinstall /dev/rdsk/c2t1d0 //perform on both node. This apply if using LVM or direct access to raw
    3. SQL> create diskgroup data_disk1 external redundancy disk '/dev/rdsk/c2t1d0'; //any RAC node in ASM instance
    4. SQL> alter diskgroup data_disk1 mount; //try to mount on the other node
    2nd Option : (Using FORCE option when creating the new diskgroup. Header_Status = MEMBER)
    1. # chown oracle:oinstall /dev/rdsk/c2t1d0 //perform on both node. This apply if using LVM or direct access to raw
    2. SQL> create diskgroup data_disk1 external redundancy disk '/dev/rdsk/c2t1d0' force; //any RAC node in ASM instance
    3. SQL> alter diskgroup data_disk1 mount; //try to mount on the other node
    Just be careful when using FORCE option or DD command. If you perform this operation on existing ASM disk groups disk, it may destroy existing disk groups.

  • How to map ASM disk path to physical disk on AIX?

    Hi Everyone,
    I am working on a plug-in for Oracle Enterprise Manager 10gR2 on AIX 5.3 which provides monitoring of storage arrays and supports ASM databases in addition to the 'emrep' database. One of the metric of that plug-in is populated by the result from a korn shell script. The script directly runs on the AIX host (connected to the storage array by FC cables via HBA ports) and retrieves the mapping for -- Physical disk - Logical Disk - LUN - ASM Disk.
    Now, I was able to get the mapping for Physical Disk – Logical Disk – LUN, but could not map ASM Disk. I googled a lot for any clue but did not find the answer to this specific problem.
    Now, I have the list of physical disks used for ASM by the command—
    lspv
    hdisk0 0001c22ac8d664ca rootvg active
    hdisk1 0001c22aa51f496a Oracle active
    hdisk2 0001c22ac478263a scratch active
    hdisk3 0001c22ac472549a Oracle active
    hdisk4 0001c22ac4725d6a Oracle active
    hdisk5 none None
    hdisk6 none None
    hdisk7 none None
    hdisk8 none None
    hdisk9 none None
    hdisk10 none None
    hdisk11 none None
    hdisk12 none None
    hdisk13 none None
    hdisk14 none None
    hdisk15 none None
    hdisk16 none None
    The disks hdisk5-16 are ASM disks and there are no PVID’s present.
    I also have the list of ASM disks by the command—
    ls –l /dev | grep oracle
    crw-rw---- 1 oracle dba 22, 6 May 12 00:02 asm_rd10_1a
    crw-rw---- 1 oracle dba 22, 10 Apr 21 07:27 asm_rd10_1b
    crw-rw---- 1 oracle dba 22, 7 May 09 13:53 asm_rd10_1c
    crw-rw---- 1 oracle dba 22, 8 May 09 13:53 asm_rd5_1a
    crw-rw---- 1 oracle dba 22, 4 May 12 00:02 asm_rd5_1b
    crw-rw---- 1 oracle dba 22, 9 Apr 21 07:28 asm_rd5_1c
    crw-rw---- 1 oracle dba 22, 12 May 12 00:02 asm_xbb2_rd10_1a
    crw-rw---- 1 oracle dba 22, 11 Apr 24 07:34 asm_xbb2_rd10_1b
    crw-rw---- 1 oracle dba 22, 13 May 09 13:53 asm_xbb2_rd10_1c
    crw-rw---- 1 oracle dba 22, 16 May 12 00:02 asm_xbb2_rd5_1a
    crw-rw---- 1 oracle dba 22, 14 Apr 24 07:34 asm_xbb2_rd5_1b
    crw-rw---- 1 oracle dba 22, 15 May 09 13:54 asm_xbb2_rd5_1c
    Now I am looking for a way to map these two lists with each other, and had no luck so far.
    Does oracle provide this information somewhere in the OEM installation structure or is there a command in AIX which could give some way to map the ASM disks to the physical disks?
    Any help on this is greatly appreciated. Thanks in advance…
    FYI: ASMLib driver is not present on the system.

    The view you are talking about here gives the ASM DISK NAME (like DGRXBB_0001) and ASM DISK PATH (like /dev/asm_rd_10_1a) and I am already using it, but this is not what I asked in mt original post. If you read carefully, I want to establish a mapping between the ASM DISK PATH (like /dev/asm_rd_10_1a) and the AIX Physical disk (like /dev/hdisk5) and did not find any view giving this info. If you know of some views which could help establish this mapping or some AIX commands or files that could help do this using shell script, it is most welcome

  • ASM disk resize

    Hi All
    I have a requirement to resize ASM disks to a smaller size
    Currently My ASM disk group is have a single disk with 500GB
    I want to resize it to 200 GB .The current disk usage is 50GB
    How can i do it?
    * Can an online resize of disk from OS level will help to resize the ASM Disk
    * Does this operation is supported by ASM instance to perform as online
    * Does the space reclaim will happen online without restarting asm instance
    Additional info
    rdbms: 11g R2 11.2.0.3.0
    Asm redundancy : external

    user7993571 wrote:
    Hi All
    I have a requirement to resize
    Nobody here prevents you from doing as required.
    Please proceed to do so without further delay.
    How do I ask a question on the forums?
    https://forums.oracle.com/message/9362002#9362002

  • How to find the physical path of the ASM disks?

    I am in a dilemma on how to find out the physical path of the ASM disks. I tried the following query, but as you can see it is not providing me the physical path of the LUN. This is a 2 node 10.2.0.4 RAC Cluster using asmlib package.
    col name format a20
    col path format a20
    col label format a20
    select name, path, label from v$asm_disk;
    NAME PATH LABEL
    ORCL:ASM103 ASM103
    ORCL:ASM104 ASM104
    ORCL:ASM117 ASM117
    ASM101 ORCL:ASM101 ASM101
    ASM102 ORCL:ASM102 ASM102
    ASM105 ORCL:ASM105 ASM105
    ASM106 ORCL:ASM106 ASM106
    ASM107 ORCL:ASM107 ASM107
    ASM108 ORCL:ASM108 ASM108
    ASM109 ORCL:ASM109 ASM109
    ASM110 ORCL:ASM110 ASM110
    NAME PATH LABEL
    ASM111 ORCL:ASM111 ASM111
    ASM112 ORCL:ASM112 ASM112
    ASM113 ORCL:ASM113 ASM113
    ASM114 ORCL:ASM114 ASM114
    ASM115 ORCL:ASM115 ASM115
    ASM118 ORCL:ASM118 ASM118
    ASM119 ORCL:ASM119 ASM119
    ASM120 ORCL:ASM120 ASM120
    ASM121 ORCL:ASM121 ASM121
    ASM122 ORCL:ASM122 ASM122
    ASM123 ORCL:ASM123 ASM123
    NAME PATH LABEL
    ASM124 ORCL:ASM124 ASM124
    ASM125 ORCL:ASM125 ASM125
    ASM126 ORCL:ASM126 ASM126
    ASM127 ORCL:ASM127 ASM127
    ASM302 ORCL:ASM302 ASM302
    ASM303 ORCL:ASM303 ASM303
    ASM304 ORCL:ASM304 ASM304
    ASM305 ORCL:ASM305 ASM305
    ASM306 ORCL:ASM306 ASM306
    ASM307 ORCL:ASM307 ASM307
    32 rows selected.
    Any help will be appreciated.
    --MM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    hi
    use the following linux command as root:
    $oracleasm listdisks
    hth

  • How reInstall Gride Infrastructure and Use old ASM disk groups

    <pre>Hello to all
    I installed Grig Infrastructure 11gR2 on a standalone server (OS is Linux)
    and I configured ASM and my database created on ASM
    Conceive that my OS disk corrupted and OS doesn't start and the Gride Home is on that disk,
    and I have to install OS again
    My ASM disks are safe , Now how can I install Grig Infrastructure again somehow that it can use previous ASM disks
    and disk groups and I don't oblige to create my database again ?
    In the step 2 of installing Gride Infrastructure it has four options
    <pre>
    1.Install and configure Oracle Grid Infrastructure for a Cluster
    2.Configure Oracle Grid Infrastructure for a Standalone Server
    3.Upgrade Oracle Gride Infrastructure or Oracle Automatice Storage Management
    4.Install Oracle Gride Infrastructure Software Only
    </pre>
    If I select the option 2 it wants to create a disk group again
    I guess that I need to select option 4 and then do some configuration but I don't know what I must configure
    Do you know answer of my question , if yes please explain it's stages
    Thank you so much
    </pre>

    Hi,
    no you are not obliged to recreate your database again. However there is a small flaw in the installation procedure, which does not make it 100% easy...
    When you installed the Oracle Restart (Standalone GI), your ASM diskgroup will contain the SPFILE of the ASM instance. And this is exactly the small flaw you will be encountering. So you have 2 options for "recovery":
    1.) Do a software only install (4), and run roothas.pl. This however will not create any ASM entries. You would have to add it manually (using srvctl) and you can specify the ASM Spfile with the srvctl command. Problem here is however to have to know where your ASM spfile has been. If you have a backup of your OLR and a backup of the GPNP profile, this might be easier to find out.
    2.) Do a new installation (2) and configure a new diskgroup (with a "spare" disk or small lun and a new name), that Oracle restart creates ASM instance and the new ASMSpfile for you.
    Then you can simply mount the diskgroup containing your database additionally. You then shoudl however move your new ASMSpfile to the new diskgroup (or simply exchange it with the existing one). In this case it is easier to find out where it was - however you will need a spare (though small) LUN for the new spfile (temporarily, until you exchange it).
    In either case after you have your ASM instance back (and access to your old diskgroup), you have to reregister your database and services - if you do not have an OLR backup.
    Again => It is doable and you can simply mount the ASM diskgroup containing your database. However I suggest you try this one time to know what really needs to be done in this case.
    Regards
    Sebastian

  • How to open RAC node2 usng spfile which will stay in ASM disk?

    Hi,
    I have installed oracle 11g r2 rac with asm in two nodes. OS is hp-Unix.
    I have installed oracle11g Active Data Guard using Single alone Database.
    Both RAc and Active Data Guard works fine.
    I have not configure Data Guard Broker.
    N.B Rac node1 is running using spfile which is in ASM disk (+DATA/spfiledcpdb.ora) but node2 is running using pfile.
    Question: how to open node 2 using spfile which will stay in ASM disk like node 1?
    Thanks
    Solaiman
    Edited by: 876149 on Apr 1, 2013 10:08 AM

    Modify your PFILE to specify only IFILE='location_of_spfile'
    OR
    use STARTUP PFILE='location_of_spfile'
    Ensure that the spfile does have the 2nd instance specific parameters defined correctly.
    Hemant K Chitale

  • How to identify ASM DiskGroup attached to which Disks ???

    Hi Guys,
    In 11gR2 RAC, How to identify which ASM Diskgroup is attached to which Disks...( OS is RHEL 5.4).
    We could list ASM Diskgroups by,
    *#oracleasm listdisks* but this command doesn't show the disks assigned to ASM DiskGroup.
    Even for checking location of OCR and Voting Disks only show Diskgroup name and not the actual disks.
    $ocrcheck
    $crsctl query css votedisk
    ( like in 10gR2 RAC, We do entry in /etc/rules.d/udev/60-raw-rules file for raw mapping of OCR, Voting Disk and Other ASM Diskgroup)
    Plz help me, As one of the client place, I could see so many LUNs assigned to the Server and not getting exact idea which Disks have been used for OCR, Voting Disk and DATA Diskgroup.
    Thanks,
    Manish

    Well for this you can use oracleasm querydisk.Using this you can identify which device as marked for asm or not. for example you can see this below example.
    [oracle@localhost init.d]$ sqlplus "/as sysdba"
    SQL*Plus: Release 10.2.0.4.0 - Production on Thu Jun 3 11:52:12 2010
    Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    SQL> select path from v$asm_disk;
    PATH
    /dev/oracleasm/disks/VOL2
    /dev/oracleasm/disks/VOL1
    SQL> exit;
    [oracle@localhost init.d]$ su
    Password:
    [root@localhost init.d]# /sbin/fdisk -l
    Disk /dev/sda: 80.0 GB, 80000000000 bytes
    255 heads, 63 sectors/track, 9726 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
       Device Boot      Start         End      Blocks   Id  System
    /dev/sda1   *           1        1305    10482381   83  Linux
    /dev/sda2            1306        9401    65031120   83  Linux
    /dev/sda3            9402        9662     2096482+  82  Linux swap / Solaris
    /dev/sda4            9663        9726      514080    5  Extended
    /dev/sda5            9663        9726      514048+  83  Linux
    Disk /dev/sdb: 80.0 GB, 80026361856 bytes
    255 heads, 63 sectors/track, 9729 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
       Device Boot      Start         End      Blocks   Id  System
    /dev/sdb1               1        4859    39029886   83  Linux
    /dev/sdb2            4860        9729    39118275   83  Linux
    [root@localhost init.d]# ./oracleasm querydisk /dev/sdb1
    Device "/dev/sdb1" is marked an ASM disk with the label "VOL1"
    [root@localhost init.d]# ./oracleasm querydisk /dev/sdb2
    Device "/dev/sdb2" is marked an ASM disk with the label "VOL2"
    [root@localhost init.d]# ./oracleasm querydisk /dev/sda1
    Device "/dev/sda1" is not marked as an ASM disk
    [root@localhost init.d]#Also in windows :
    C:\Documents and Settings\comp>asmtool -list
    NTFS                             \Device\Harddisk0\Partition1           140655M
    ORCLDISKDATA1                    \Device\Harddisk0\Partition2             4102M
    ORCLDISKDATA2                    \Device\Harddisk0\Partition3             4102M
    NTFS                             \Device\Harddisk0\Partition4           152617M
    C:\Documents and Settings\comp>answered by chinar.
    refer:-how to identify which rawdevice Disk Is named as VOL1 IN ASM from os level
    Happy New Year.
    regards,

  • How to create ASM device disk groups

    I have new Oracle unbreakable linux installed. I have Oracle 11g running. Now I'm wanting to install ASM. When going through dbca - there are no available disk groups. When I click on "Create New" - there are no member disks for me to use. Normally these are already created for me by unix admin, but this is home set-up. Appreciate any help.

    Hi,
    You need to apply below RPM's and configure the ASMLIB, follow below steps, after the setup install the ASM and then it will show the avaliable disks.
    Required RPM for ASM Configuration
    oracleasm-support-2.0.1-1.i386.rpm
    oracleasm-2.4.21-37.EL-1.0.4-1.i686.rpm
    oracleasmlib-2.0.1-1.i386.rpm
    Configuring ASMLib
    Before using ASMLib, you must run a configuration script to prepare the driver. Run the following command as root, and answer the prompts as shown in the example below. Run this on each node in the cluster.
    /etc/init.d/oracleasm configure
    Configuring the Oracle ASM library driver
    This will configure the on-boot properties of the Oracle ASM library driver. The following questions will determine whether the driver is loaded on boot and what permissions it will have. The current values
    will be shown in brackets ('[]'). Hitting <ENTER> without typing an answer will keep that current value. Ctrl-C will abort.
    Default user to own the driver interface []: oracle Default group to own the driver interface []: dba Start Oracle ASM library driver on boot (y/n) [n]: y Fix permissions of Oracle ASM disks on boot (y/n) [y]: y
    Writing Oracle ASM library driver configuration: [ OK ] Creating /dev/oracleasm mount point: [ OK ] Loading module "oracleasm": [ OK ] Mounting ASMlib driver filesystem: [ OK ] Scanning system for ASM disks: [ OK ]
    Next you tell the ASM driver which disks you want it to use. Oracle recommends that each disk contain a single partition for the entire disk. See Partitioning the Disks at the beginning of this section for an example of creating disk partitions.
    You mark disks for use by ASMLib by running the following command as root from one of the cluster nodes, run it from node 1:
    /etc/init.d/oracleasm createdisk DISK_NAME device_name
    Tip: Enter the DISK_NAME in UPPERCASE letters.
    Ex:
    [root@vmractest1 ASMlib]# /etc/init.d/oracleasm createdisk VOL1 /dev/sdc1
    Marking disk "/dev/sdd1" as an ASM disk: [ OK ]
    [root@vmractest1 ASMlib]# /etc/init.d/oracleasm createdisk VOL2 /dev/sdd1
    Marking disk "/dev/sdd1" as an ASM disk: [ OK ]
    [root@vmractest1 ASMlib]# /etc/init.d/oracleasm createdisk VOL3 /dev/sde1
    Marking disk "/dev/sde1" as an ASM disk: [ OK ]
    Verify that ASMLib has marked the disks:
    [root@vmractest1 ASMlib]# /etc/init.d/oracleasm listdisks
    VOL1
    VOL2
    VOL3
    On all other cluster nodes, run the following command as root to scan for configured ASMLib disks:
    /etc/init.d/oracleasm scandisks
    Ex:
    [root@vmractest2 ASMlib_install]# /etc/init.d/oracleasm scandisks
    Scanning system for ASM disks: [ OK ]
    [root@vmractest3 ASMlib_install]# /etc/init.d/oracleasm scandisks
    Scanning system for ASM disks: [ OK ]
    And then check that everything is as in the first node:
    [root@vmractest2 ASMlib_install]# /etc/init.d/oracleasm listdisks
    VOL1
    VOL2
    VOL3
    [root@vmractest3 ASMlib_install]# /etc/init.d/oracleasm listdisks
    VOL1
    VOL2
    VOL3
    The above steps are clearly explained in the document " http://blogs.oracle.com/content/dav/oracle/mtblog/A/Al/AlejandroVargas/gems/StepbyStepRAConLinux3.pdf " under section *11- Configure ASMlib for ASM Management*
    If you still have issues please do let us know.
    Regards,
    Satya.

  • How can we monitor ASM disk usage on Standby Database.

    I am looking for an option to automate deleting the archivelog which is on ASM diskgroup. I could do it if they were not in the ASM disk group with writing a script but with ASM I can't. Is there anything that I can monitor and get notified periodically reg. disk utilization on ASM and then write a script to delete some of the files especially archivelogs if needed.

    Hi
    what is your Oracle version and your OS?

  • How to move or migrate whole directories between ASM disk groups?

    Hello everyone!
    I'm playing around with Oracle ASM and Oracle Database (11g R1), I'm a student. This is just for testing purposes.
    Computer specifications are:
    Processor: Intel Pentium 4 HT 3.00 Ghz.
    RAM Memory: 2 GB.
    Hard Disk: 250 GB
    O.S.: Windows XP Professional Edition SP 2.
    I installed Oracle ASM, I created an ASM disk group (+FRA), I installed Oracle Database and I created a testing database. The database is working properly over the ASM disk group. Days ago, I got help about the initialization parameters DB_CREATE_FILE_DEST, DB_CREATE_ONLINE_LOG_DEST_1, DB_CREATE_ONLINE_LOG_DEST_2 and DB_RECOVERY_FILE_DEST, based on their function, I created another 3 ASM disk groups (+FILES, LOG1, LOG2). Currently, the four initialization parameters are pointing to its corresponding ASM disk group. As you can deduce, at the installation moment of the Oracle Database I used the ASM disk group "+FRA" and inside it were created the directories: CONTROLFILE, DATAFILE, ONLINELOG, PARAMETERFILE, TEMPFILE and the SPFile.
    My point is I wanna move or migrate the directories DATAFILE, PARAMETERFILE, TEMPFILE and the SPFile to "+FILES", ONLINELOG and CONTROLFILE to "+LOG1" and "+LOG2", this way, the ASM disk group "+FRA" will contain the Flash Recovery Area only. What is the procedure to do this?
    Thanks in advance!

    user1987306 wrote:
    Hello everyone!
    My point is I wanna move or migrate the directories DATAFILE, PARAMETERFILE, TEMPFILE and the SPFile to "+FILES", ONLINELOG and CONTROLFILE to "+LOG1" and "+LOG2", this way, the ASM disk group "+FRA" will contain the Flash Recovery Area only. What is the procedure to do this?
    Thanks in advance!
    Hi,
    There are couple of approaches you can use, here is some of them
    - To move datafile, start the database in mount state
    RMAN > copy datafile '+FRA/xxx' to '+FILES1';
    SQL > alter database rename file '+FRA/xxx' to '+FILES1/xxx';
    - To move tempfile
    SQL > alter tablespace TEMP add tempfile '+FILES1' SIZE 10M;
    SQL > alter database tempfile '+FRA/xxx' drop;
    - To move onlinelog
    SQL > alter database add logfile member '+LOG1' to group 1;
    SQL > alter database add logfile member '+LOG2' to group 1;
    SQL > alter database drop logfile member '+FRA/xxx';
    - To move controlfile
    SQL > restore controlfile to '+FILES1' from '+FRA/xxx';
    update the spfile to reflect new location of controlfile
    Cheers

  • How to simulate the ASM disk corruption & recover it back ?

      Hi DBA's,
          we are creating a new grid .SO we would like to simulate the ASM disk corruption & recover it back . Do you have any way that we can simulate the situation ?

    Hi,
    >>>>>>>>>>>>>>>>>>>>> Please do not try this on production. >>>>>>>>>>>>>>>>>>>>>
    Simulate ASM disk corruption:
    dd if=/dev/zero of=/dev/sdb1 bs=1024 count=4
    Solution:
    kfed repair /dev/sdb1     >>>>>>> will fix only asm header issue
    Thanks,
    Rajasekhar

  • Asm disk removed taking too much time to boot

    hi
    a local machine is configured with ASM by oracleasm with a total disk.As it was a training purpose so i have removed the disk eg /dev/sdb bluntly ie. just removing it from box.now i tried fsck -c -c -f /dev/ in rescue mode its didnot worked even not mounting the /mnt/sysimage.It claims for ext2fs error and mounting the fs etc.
    Then after lots of days has gone.i fed up with this issues and reinstalled OS.
    but my question is what exactly to do?obviously re-installation is not the exact way to do.
    regards

    If the +/dev/sdb+ was an ASM disk, then it should not impact the o/s when it is removed. ASM instance itself will fail with an error saying something like it was not able to mount the disk group.
    If your system failed to boot correctly after this disk was removed, then +/dev/sdb+ contained more than just ASM data.
    We dynamically add and remove ASM (multipath'ed) disks via kpartx - while o/s is running. No reboot. No problems.
    I fail to see how a ASM disk could cause the type of problems you describe - unless it was more than just a disk used by ASM alone.

  • Creation of ASM disk for OUI

    I need to install a Oracle Database in order to install Enterprise Manager Cloud Control 12c.
    Need the database to use a ASM disk.
    I used the following command to create the disk, per the Oracle Database Installation Guide.
    #/usr/sbin/oracleasm createdisk DISK1 /dev/sdd1
    #oracleasm listdisks
    DISK1
    However, when running the OUI for Oracle Database 12c (understand 11.2.0.3 is certified for Cloud Control), step 7
    errors INS-30517 when attempting to select "Oracle Automatic Storage Management" for "Storage type".
    Researched the error at this location but no cause or action was provided.
    http://docs.oracle.com/cd/E16655_01/server.121/e26079/common_errormessages.htm
    INS-30517: Automatic Storage Management software is not configured on this system.
    The database install guide states that I need to ensure the "disk discovery string" is set the "ORCL:*" or is left empy ("") so the installer discovers these disks.
    It doesn't show how to confirm or change the settings.
    At this point I'm at a stopping point.

    All ASMLib installations require the oracleasmlib and oracleasm-support packages. The oracleasm kernel driver is included in the Oracle UEK kernel. Perhaps you are missing the oracleasmlib package. You can download it from:
    Oracle Linux: Oracle ASMLib | Oracle Technology Network
    Oracleasmlib is not necessary for ASM to work, but it contains software necessary for Linux oracleasm, including the /usr/sbin/oracleasm-discover utility, which the Oracle installer used in the previous 11g version to detect available ASM volumes.

  • How does 1 ASM instance in a 10 node RAC cause all 10 ASM instance to hang

    Linux RHEL4
    11.2.0.1.0 GI
    11.2.0.1.0 RDBMS
    11.1.0.7.0 RDBMS
    10.2.0.4.4 RDBMS
    Yesterday we had one of the ASM instance on our 10-node cluster hang with a latch "ASM file allocation latch". Oracle support has stated we are hitting a bug with is fixed in the latest PSU.
    What I am trying to understand is how a latch on one ASM instance caused all 10 ASM instances to hang?
    Oracle Supports explanation still does not answer how all 10 ASM instance were affected other then the faulty code that the patch fixes. Bellow is info out of the SAR.
    Data Guard Site:
    ================
    ARC1 PID 21508 reports ORA-240 'control file enqueue held for more than 120 seconds' at Thu Oct 28 11:35:54 2010. This message means ARC1 PID 21508 was holding the enqueue past the maximum tine limit of 120 seconds.
    Next ARC0 PID 17398 reports ORA-16146: 'control file enqueue unavailable' at Thu Oct 28 11:36:52 2010. This means ARC0 PID 17398 tried to access the controlfile and it could get the lock.
    ARC1 PID 21508 is then killed at Thu Oct 28 11:49:57 2010.
    Killing enqueue blocker (pid=21508) on resource CF-00000000-00000000 by (pid=23078) by killing session 5.3
    We see that RSM has been restarted by Broker. This matches to the alert.log and messages showing RSM being restarted several time. i.e. RSM0 started with pid=84, OS id=27915
    Since this started happening around 11:14, the problem may have really started then instead of w/ the CF enqueue block.
    The primary appears to be shipping redo to the standby using asynchronous mode. Unless there was a gap, I do no know if ARC1 should have been doing any remote network I/O. Because a log switch to thread 1 sequence 5235 had just happened at 11:33am, I suspect it was a local disk I/O that was started at least. The ORA-240 is reported at 11:35, exactly 120 sec (or 2min) from this log switch. Notice also the entry to show the log thread 1 sequence 5234 was registered to the controlfile didn't happen yet.
    ASM Side:
    ============
    From the systemstate dump on ASM, multiple processes are waiting on 'ASM file allocation latch' and we are kind of stuck on stack:
    ksedsts()+461<-ksdxfstk()+32<-ksdxcb()+1782<-sspuser()+112<-0000003218E0C5B0<-kfuhInsert()+175<-kffilCreate()+601<-kfnsUFG()+3691<-kfnsBackground()+4382<-kfnDispatch()+527<-opiodr()+1149<-ttcpip()+1251<-opitsk()+1633<-opiino()+958<-opiodr()+1149<-opidrv()+570<-sou2o()+103<-opimai_real()+133<-ssthrdmain()+214<-main()+201<-__libc_start_main()+219
    This caused the hang on the ASM side and hence ASM was not responding to the database. The CF Enqueue issue on the database was a side effect of this.
    This is a direct <BUG:9232266> which is a duplicate of <BUG:8974548>

    Thanks Murali,
    I was little reluctent to open a tar since my experince says that its better to troubleshoot the issue yourself instead of spending time with the Oracle support :)
    Well, I got some more information on this : the sql for the process id of ASM instance is :
    Alter Diskgroup mount all;
    It looks like it is unable to mount the diskgroup and get hunged at that point , is it due to the new disk added to the system or do we missed something after adding the new disk.
    Also, the ASM process can not be killed from unix box while the ASM is down.
    Will appreciate your time if we can move in any directions from here ..
    Thanks ,
    Ankur

Maybe you are looking for