8 Replies Latest reply: Jun 7, 2010 8:02 AM by Chinar RSS

    how to identify which rawdevice Disk Is named as VOL1 IN ASM from os level

    rajeysh
      Hi Friends,

      disk creation using the ASMLIB
      I want to know which disk is named as VOL1,VOL2,VOL3 etc,. from operating system LINUX .

      i know using v$asm_disk we can query name,path, status, label, etc...

      i want to know which raw device disk is named or configured as VOL1 from operating system(LINUX )

      thanks in advance.

      rajesh.

      Edited by: rajeysh on Jun 3, 2010 3:49 PM
        • 1. Re: how to identify which rawdevice Disk Is named as VOL1 IN ASM from os level
          Rajesh Lathwal
          rajeysh wrote:
          Hi Friends,

          I want to know which disk is named as VOL1,VOL2,VOL3 etc,. from operating system LINUX .

          i know using v$asm_disk we can query name,path, status, label, etc...

          i want to know which raw device disk is named or configured as VOL1 from operating system(LINUX )

          thanks in advance.

          rajesh.
          VOL1/VOL2 names are logical names and defined at ASM level and you can not use these names to see info at OS level.

          At OS level , you will to check at complete path of the disk.

          Regards
          Rajesh
          • 2. Re: how to identify which rawdevice Disk Is named as VOL1 IN ASM from os level
            Aman....
            I believe you are mentioning the disk creation from the ASMLIB. If yes, its the stamping of the disk from the asm driver. You won't come to know about it from the physical level.

            Aman....
            • 3. Re: how to identify which rawdevice Disk Is named as VOL1 IN ASM from os level
              rajeysh
              hi aman..
              hearty thanks for your reply.

              Regards,
              rajesh

              Edited by: rajeysh on Jun 3, 2010 3:32 PM
              • 4. Re: how to identify which rawdevice Disk Is named as VOL1 IN ASM from os level
                Chinar
                Hi, do you mean
                [oracle@localhost init.d]$ oracleasm listdisks
                VOL1
                VOL2
                [oracle@localhost init.d]$ 
                • 5. Re: how to identify which rawdevice Disk Is named as VOL1 IN ASM from os level
                  rajeysh
                  which device is named as VOL1?
                  FOR eg:

                  linux5:oracle:+ASM:/home/oracle>/etc/init.d/oracleasm scandisks
                  Scanning the system for Oracle ASMLib disks: [  OK  ]
                  linux5:oracle:+ASM:/home/oracle>/etc/init.d/oracleasm listdisks
                  VOL1
                  VOL2

                  SQL> select path from v$asm_disk;

                  PATH
                  --------------------------------------------------------------------------------
                  ORCL:VOL1
                  ORCL:VOL2

                  i want to know which DISK (eg: /dev/raw/raw1) is configured as VOL1.
                  I want to view the output
                  eg: /dev/raw/raw1

                  ok thanks for all your replies.

                  Edited by: rajeysh on Jun 3, 2010 3:42 PM

                  Edited by: rajeysh on Jun 3, 2010 3:51 PM
                  • 6. Re: how to identify which rawdevice Disk Is named as VOL1 IN ASM from os level
                    Chinar
                    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>
                    this is answer your question. :-)
                    • 7. Re: how to identify which rawdevice Disk Is named as VOL1 IN ASM from os level
                      rajeysh
                      thanks chinar, i checked it.

                      thank you all for your replies.