Configure ASM using udev scsi Rules on Oracle Linux 5 and 6

Source: Internet
Author: User

UDEV ASMDisk Configuration
Because Oracle does not support the RHEL6 series ASMLib, we can change it to Udev to configure ASMDisk as follows:
 
Use udev to configure the block device information stored in ASM.
 
1. confirm that the udev package is installed.
[Root @ rac01 ~] # Rpm-qa | grep udev
Udev-147-2.40.el6.x86_64
 
2. Obtain the WWID system information of the hard disk.
(1) Use the following command in Oracle Linux 5
[Root @ rac01 ~] #/Sbin/scsi_id-g-u-s/block/sdb
SATA_VBOX_HARDDISK_VBd306dbe0-df3367e3 _
[Root @ rac01 ~] #/Sbin/scsi_id-g-u-s/block/sdc
SATA_VBOX_HARDDISK_VB46dec7e0-192e8000 _
[Root @ rac01 ~] #/Sbin/scsi_id-g-u-s/block/sdd
SATA_VBOX_HARDDISK_VBce8c63bb-ac67a172 _
[Root @ rac01 ~] #/Sbin/scsi_id-g-u-s/block/sde
SATA_VBOX_HARDDISK_VB7437a3b7-95b199cd _
 
(2) Use the following command in Oracle Linux 6
[Root @ rac01 ~] #/Sbin/scsi_id-g-u-d/dev/sdb
SATA_VBOX_HARDDISK_VBd306dbe0-df3367e3 _
[Root @ rac01 ~] #/Sbin/scsi_id-g-u-d/dev/sdc
SATA_VBOX_HARDDISK_VB46dec7e0-192e8000 _
[Root @ rac01 ~] #/Sbin/scsi_id-g-u-d/dev/sdd
SATA_VBOX_HARDDISK_VBce8c63bb-ac67a172 _
[Root @ rac01 ~] #/Sbin/scsi_id-g-u-d/dev/sde
SATA_VBOX_HARDDISK_VB7437a3b7-95b199cd _
3. The hard drive of/dev/sdb 4G is divided into two primary partitions, two GB for each partition, to achieve OCR information redundancy.
[Root @ rac01 ~] # Fdisk/dev/sdb
 
4. Divide the hard drive of/dev/sdc 8 GB into four logic units, each of which is 2 GB to store data files.
[Root @ rac01 ~] # Fdisk/dev/sdc
 
5. Configure the udev configuration file
Important: each configuration file contains a rule with a space between (comma) and the next keyword.
[Root @ rac01 ~] # Cd/etc/udev/rules. d/
[Root @ rac01 rules. d] # vi 99-oracle-asmdisk.rules
(1) Oracle Linux 5 uses the following parameters:
KERNEL = "sd? [1-2] ", BUS =" scsi ", PROGRAM ="/sbin/scsi_id-g-u-s/block/$ parent ", RESULT = "SATA_VBOX_HARDDISK_VBd306dbe0-df3367e3 _", NAME = "asm-disk1", OWNER = "grid", GROUP = "asmadmin", MODE = "0660 ″
KERNEL = "sd? [5-8] ", BUS =" scsi ", PROGRAM ="/sbin/scsi_id-g-u-s/block/$ parent ", RESULT = "SATA_VBOX_HARDDISK_VB46dec7e0-192e8000 _", NAME = "asm-disk2", OWNER = "grid", GROUP = "asmadmin", MODE = "0660 ″
KERNEL = "sd? 1 ", BUS =" scsi ", PROGRAM ="/sbin/scsi_id-g-u-s/block/$ parent ", RESULT =" SATA_VBOX_HARDDISK_VBce8c63bb-ac67a172 _", NAME = "asm-disk3", OWNER = "grid", GROUP = "asmadmin", MODE = "0660 ″
KERNEL = "sd? 1 ", BUS =" scsi ", PROGRAM ="/sbin/scsi_id-g-u-s/block/$ parent ", RESULT =" SATA_VBOX_HARDDISK_VB7437a3b7-95b199cd _", NAME = "asm-disk4", OWNER = "grid", GROUP = "asmadmin", MODE = "0660 ″
 
 
 
(2) Oracle Linux 6 uses the following parameters:
KERNEL = "sd? [1-2] ", BUS =" scsi ", PROGRAM ="/sbin/scsi_id-g-u-d/dev/$ parent ", RESULT = "SATA_VBOX_HARDDISK_VBd306dbe0-df3367e3 _", NAME = "asm-disk1", OWNER = "grid", GROUP = "asmadmin", MODE = "0660 ″
KERNEL = "sd? [5-8] ", BUS =" scsi ", PROGRAM ="/sbin/scsi_id-g-u-d/dev/$ parent ", RESULT = "SATA_VBOX_HARDDISK_VB46dec7e0-192e8000 _", NAME = "asm-disk2", OWNER = "grid", GROUP = "asmadmin", MODE = "0660 ″
KERNEL = "sd? 1 ", BUS =" scsi ", PROGRAM ="/sbin/scsi_id-g-u-d/dev/$ parent ", RESULT =" SATA_VBOX_HARDDISK_VBce8c63bb-ac67a172 _", NAME = "asm-disk3", OWNER = "grid", GROUP = "asmadmin", MODE = "0660 ″
KERNEL = "sd? 1 ", BUS =" scsi ", PROGRAM ="/sbin/scsi_id-g-u-d/dev/$ parent ", RESULT =" SATA_VBOX_HARDDISK_VB7437a3b7-95b199cd _", NAME = "asm-disk4", OWNER = "grid", GROUP = "asmadmin", MODE = "0660 ″
6. confirm that the configuration is normal and the block device permission is correct.
# Cd/dev
# Ls-al asm-disk *
Brw-rw -- 1 grid asmadmin 8, 17 Apr 8 asm-disk1
Brw-rw -- 1 grid asmadmin 8, 33 Apr 8 asm-disk2
Brw-rw -- 1 grid asmadmin 8, 49 Apr 8 asm-disk3
Brw-rw -- 1 grid asmadmin 8, 65 Apr 8 asm-disk4

Permanent link address of this article:

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.