[dm-devel] Re: Bug in multipath detecting devices

Matthias Rudolph Matthias.Rudolph at hds.com
Wed Aug 9 13:58:55 UTC 2006


Hi Jeff,

in Oracle Clusterware, RAC and ASM you have to use RAW devices - as you
mentioned. In Linux you have to bind the SCSI block devices to a RAW
device.

In RedHat:
# vi /etc/sysconfig/rawdevices
/dev/raw/raw1 /dev/disk/by-name/1HITACHI_D60085320025
/dev/raw/raw2 /dev/disk/by-name/1HITACHI_D60085320018

In Suse:
# vi /etc/raw
raw1:disk/by-name/1HITACHI_D60085320025
raw2:disk/by-name/1HITACHI_D60085320018

After restarting the RAW subsystem you only work with /dev/raw/raw.*.
The mapper device name is fixed and depends on the storage type, serial
number and storage internal lun number. With the binding also the RAW
device names are fixed. In Oracle ASM you enter /dev/raw/raw.* and the
complete path is binded.

If you use the Oracle ASMlib (easy to install) you do not need to bind
the RAW devices.
Example:

# multipath -ll
1HITACHI_D60H02610121
[size=1 GB][features="0"][hwhandler="0"]
\_ round-robin 0 [prio=1][active]
 \_ 1:0:1:1 sdj  8:144  [active][ready]
\_ round-robin 0 [enabled]
 \_ 2:0:1:1 sdan 66:112 [active][ready]

# /etc/init.d/oracleasm createdisk DISK1
/dev/disk/by-name/1HITACHI_D60H02660121
Marking disk "/dev/disk/by-name/1HITACHI_D60H02660121" as an ASM disk:
done

# /etc/init.d/oracleasm listdisks
DISK1

# /etc/init.d/oracleasm querydisk DISK1
Disk "DISK1" is a valid ASM disk on device [253, 6]

SHUTDOWN the server
Exchange the LUN number with another LUN for an different scanning
sequence.
BOOT the server
Now other major and minor numbers are used:

# multipath -l
1HITACHI_D60H02610121
[size=1 GB][features="0"][hwhandler="0"]
\_ round-robin 0 [active]
 \_ 1:0:1:0 sdi  8:128  [active][ready]
\_ round-robin 0 [enabled]
 \_ 2:0:1:0 sdam 66:96  [active][ready]

# /etc/init.d/oracleasm listdisks
DISK1

# /etc/init.d/oracleasm querydisk DISK1
Disk "DISK1" is a valid ASM disk on device [8, 32]

# /etc/init.d/oracleasm querydisk
/dev/disk/by-name/1HITACHI_D60H02660121
Disk "/dev/disk/by-name/1HITACHI_D60H02660121" is marked an ASM disk
with the label "DISK1"

No problem for ASM to find the correct disk.

Regards, Matthias





More information about the dm-devel mailing list