Troubleshooting ASMLIB on Linux

 

 

ASMLIB Disk Discovery troubleshooting checklist
————————————————

In Oracle10g, storage management and provisioning for Oracle databases is more simplified with a new feature called Automatic Storage Management (ASM).

In order to simplify the operating system to database interface, and to exploitthe capabilities and strengths of vendors’ storage arrays, the ASM API was developed.

The scope of the ASM API (ASMLIB), which is an add-on to ASM, is providing an alternative interface for the ASM enabled-Oracle kernel to identify and access block devices.

Oracle provides an ASM library driver for the Linux OS. With this library the steps of raw device binding become unnecessary. This ASM library driver must be installed prior to installing any other Oracle database software. Additionally, it is recommended that any ASM disk devices required by the database be prepared and created before the OUI database install.

This note, which is specifically geared towards the Oracle ASMLIB on Linux, will address disk discovery issues than can occur either at disk group database creation; e.g. when using DBCA, or creating disk groups manually.

The following checklist is intended to be a top-down list of items to review and validate, when performing the install of AMSLIB.

TROUBLESHOOTING STEPS

  1. Use current release (1.0.1 at the writing of this article) of Oracle ASMLIB.
    The Oracle ASMLIB software is available on the Oracle Technology Network (OTN) for download. The 1.0.0 versions of the library and the library driver are current versions.

The only package that needs an upgrade is the support files (oracleasm-support).

2. Install ASMLIB per the Installation documentation.

3. Make sure that ‘oracleasm configure’ was properly run.
This configuration command will configure the on-boot properties of the Oracle ASM library driver as well as set the appropriate file permissions.
To confirm this configuration, perform the following:

a. Execute the ‘lsmod’ command (as root), to show the loaded oracleasm module.

The oracleasm should be listed with a “Used by” column setting of ‘1’.

[<root_user>@<node_name>2 root]# lsmod
Module Size Used by Not tainted
ide-cd 35296 0 (autoclean)
cdrom 35520 0 (autoclean) [ide-cd]
soundcore 7940 0 (autoclean)
oracleasm 16384 1
cpqfc 53376 1
autofs 13796 0 (autoclean) (unused)
ocfs 302088 3
eepro100 21968 2
ext3 70944 6
jbd 55444 6 [ext3]
cpqarray 26080 10
sd_mod 13920 1
scsi_mod 126812 2 [cpqfc sd_mod]

 

  1. Perform a ‘cat /proc/filesystems’, and make sure an entry named “oracleasmfs” exists in this filesystem listing.

[<oracle_user>@<node_name>1 oracle]$ cat /proc/filesystems
nodev rootfs
nodev proc
nodev sockfs
nodev tmpfs
nodev shm
nodev pipefs
ext2
iso9660
nodev devpts
nodev pcihpfs
ext3
ocfs
nodev oracleasmfs
nodev autofs

  1. Perform a ‘df –ha’, this should show you that /dev/oracleasmfs is mounted.

[oracle@racnode1 oracle]$ df -ha
Filesystem Size Used Avail Use% Mounted on
/dev/ida/c0d0p1 5.0G 1.6G 3.2G 32% /
none 0 0 0 – /proc
none 0 0 0 – /dev/pts
/dev/ida/c0d0p3 3.9G 2.2G 1.5G 59% /home
/dev/ida/c0d0p2 8.6G 1.7G 6.5G 20% /opt
none 502M 0 501M 0% /dev/shm
/dev/ida/c0d0p10 2.0G 35M 1.8G 2% /tmp
/dev/ida/c0d0p11 1.9G 33M 1.7G 2% /users
/dev/ida/c0d0p5 2.0G 101M 1.8G 6% /var
oracleasmfs 0 0 0 – /dev/oracleasm

 

  1. Make sure ‘oracleasm createdisk’ was properly run for the candidate disks.
    In order to use a disk for ASMLIB, a disk must be “marked” by the createdisk command.
    When a disk is “marked”, it means there is a signature written to the header of the disk; i.e., stamped for ASM use) Why is Marked all caps?]

This can be validated using the following commands:

  1. Perform ‘oracleasm listdisks’ to display useable, “marked” ASMLIB disks.
    This will list all MARKED disks.b. Perform ‘oracleasm querydisk’ for each disk marked, to make sure it is MARKED.
  2. Execute ‘ls -l /dev/oracleasm/disks’ to make sure the ownership/permissions are oracle:oinstall (or whatever was used in configure command) for each disk
    name that was created using the ‘oracleasm createdisk’ command

[<oracle_user>@<node_name>1 oracle]$ ls -l /dev/oracleasm/disks
total 0
brw-rw—- 1 oracle oinstall 8, 32 Apr 9 16:09 DISK1
brw-rw—- 1 oracle oinstall 8, 48 Apr 9 16:09 DISK2
brw-rw—- 1 oracle oinstall 8, 64 Apr 9 16:09 DISK3
brw-rw—- 1 oracle oinstall 8, 80 Apr 9 16:10 DISK4

  1. Verify the use of the following ASMLIB search [discovery!] string (either at the DBCA prompt or in the ASM init.ora): “ORCL:*”. Also, if the ASM instance
    is active, then check the ASM alert.log to see if the correct string is being.

    7. The current version of Oracle 10g (10.1.0.2 as of this writing) requires that a Custom Oracle Install be performed to enable ASM and discover the MARKED
    ASMLIB disks. This restriction will be removed in the next release of 10g.

    8. Tail the ASM alert.log to see if ASM is displaying any messages regarding discovery.

  2. A successfully loaded ASMLIB will display the following general message (depending on version):
    Loaded ASM Library – Generic Linux, version 1.0.0 library for asmlib interface
  3. If there are other diskgroups already created, verify if they are being mounted. Then following message will be displayed in the alert.logSQL> /* OracleOEM */ ALTER DISKGROUP DG1 MOUNT
    Mon Apr 12 13:07:10 2004
    NOTE: cache registered group DG1 number=1 incarn=0xb41e396c
    Mon Apr 12 13:07:11 2004
    NOTE: cache opening disk 0: DISK1 path:ORCL:DISK1
  4. The following query shows disks that are properly discovered by the ASM librarySQL> select library, path from v$asm_disk;

    LIBRARY PATH
    ——————————————- —————-
    ASM Library – Generic Linux, version 1.0.0 ORCL:DISK4
    ASM Library – Generic Linux, version 1.0.0 ORCL:DISK1
    ASM Library – Generic Linux, version 1.0.0 ORCL:DISK2
    ASM Library – Generic Linux, version 1.0.0 ORCL:DISK3

 

Reference – 269194.1

Recent Posts

Start typing and press Enter to search