No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

FusionCube DB 3.1 Database Best Practice 03 (Oracle RAC 11g R2)

Rate and give feedback :
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Configuring ASM Disks

Configuring ASM Disks

Use the Linux kernel manager udev to configure ASM disks. The udev commands vary with the OSs.

Procedure

  1. Query the SCSI IDs of all shared logical volumes.

    NOTE:

    All volumes are shared and mounted to all database nodes. Therefore, you can run the query command on any database node.

    • If the database node uses Oracle Linux 6 or Red Hat Enterprise Linux 6 and sdb and sdc are used as an example, run the following commands:
      [root@dbn01~]# /sbin/scsi_id -g -u -d /dev/sdb  
      3688860300000000ae036568967094421 
      [root@dbn01~]# /sbin/scsi_id -g -u -d /dev/sdc  
      36888603000000009e036568967094421 
      
      ...
    • If the database node uses Red Hat Enterprise Linux 7 and sdb and sdc are used as an example, run the following commands:
      [root@dbn01~]# /usr/lib/udev/scsi_id -g -u -d /dev/sdb  
      3688860300000000ae036568967094421
      [root@dbn01~]# /usr/lib/udev/scsi_id -g -u -d /dev/sdc  
      36888603000000009e036568967094421
      
      

  2. Log in to each database node as user root and edit the udev rule file.

    • Name the volumes in SYMLINK mode. Do not use the NAME mode.
    • In the udev rules, each device has a configuration item and each configuration item contains multiple parameters. The SCSI ID of each volume is unique.
    • Configure the following parameters based on the actual situation:
      • RESULT: The parameter format is RESULT=="3688860300000000ae036568967094421". The value for each device is unique and equals the SCSI ID. You can query the SCSI ID by running the scsi_id -g -u /dev/sdb command.
      • SYMLINK: The parameter format is SYMLINK+="asmdisk/OCRDISK01". asmdisk indicates the directory under /dev/ where the ASM disk group is located, and OCRDISK01 indicates the ASM disk name.
      • Owner and GROUP: The parameter format is OWNER= 'grid', GROUP= 'asmadmin'. Set the parameters based on the data plan in Oracle RAC Node User Plan. In this section, the user is grid, and the user group is asmadmin.
    • If the database node uses Oracle Linux 6 or Red Hat Enterprise Linux 6 and sdb and sdc are used as an example, add the rules of the disks to be expanded in the following format to the rule file:
      [root@dbn01 u01]# vi /etc/udev/rules.d/99-oracle-asmdevices.rules     
      KERNEL=="sd*", BUS=="scsi", PROGRAM=="/sbin/scsi_id --whitelisted --replace-whitespace --device=/dev/$name", RESULT=="3688860300000000ae036568967094421", SYMLINK+="asmdisk/OCRDISK01", OWNER="grid", GROUP="asmadmin", MODE="0660", OPTIONS="nowatch"  
      
      KERNEL=="sd*", BUS=="scsi", PROGRAM=="/sbin/scsi_id --whitelisted --replace-whitespace --device=/dev/$name", RESULT=="36888603000000009e036568967094421", SYMLINK+="asmdisk/OCRDISK02", OWNER="grid", GROUP="asmadmin", MODE="0660", OPTIONS="nowatch"  
      ...
    • If the database node uses Red Hat Enterprise Linux 7 and sdb and sdc are used as an example, add the rules of the disks to be expanded in the following format to the rule file:
      [root@dbn01 u01]# vi /etc/udev/rules.d/99-oracle-asmdevices.rules     
      KERNEL=="sd*", ENV{DEVTYPE}=="disk", SUBSYSTEM=="block", PROGRAM=="/usr/lib/udev/scsi_id --whitelisted --replace-whitespace --device=/dev/$name", RESULT=="3688860300000002404f9d2f611850357", SYMLINK+="asmdisk/OCRDISK01", OWNER="grid", GROUP="asmadmin", MODE="0660", OPTIONS="nowatch" 
      
      KERNEL=="sd*", ENV{DEVTYPE}=="disk", SUBSYSTEM=="block", PROGRAM=="/usr/lib/udev/scsi_id --whitelisted --replace-whitespace --device=/dev/$name", RESULT=="3688860300000002204f9d2f611850357", SYMLINK+="asmdisk/OCRDISK02", OWNER="grid", GROUP="asmadmin", MODE="0660", OPTIONS="nowatch" 
      

  3. Save the file and run the following commands for the rules to take effect:

    [root@dbn01 u01]# /sbin/udevadm control --reload-rules
    [root@dbn01 u01]# /sbin/udevadm trigger --type=devices --action=change

    Do not run the /sbin/start_udev command to make the rules take effect during service running.

  4. Check whether the ASM disks are configured successfully.

    [root@dbn01 u01]# ll /dev/asmdisk/ 
    lrwxrwxrwx 1 root root 6 Jun 29 11:28 OCRDISK01 -> ../sdb 
    lrwxrwxrwx 1 root root 6 Jun 29 11:45 OCRDISK02 -> ../sdc 
    lrwxrwxrwx 1 root root 6 Jun 29 11:45 OCRDISK03 -> ../sdd 
    lrwxrwxrwx 1 root root 6 Jun 29 11:45 OCRDISK04 -> ../sde 
    lrwxrwxrwx 1 root root 6 Jun 29 11:45 OCRDISK05 -> ../sdf 
    lrwxrwxrwx 1 root root 6 Jun 29 11:45 FRADISK01 -> ../sdg  
    lrwxrwxrwx 1 root root 6 Jun 29 11:28 DATADISK001 -> ../sdh 
    lrwxrwxrwx 1 root root 6 Jun 29 11:45 DATADISK002 -> ../sdi 
    lrwxrwxrwx 1 root root 6 Jun 29 11:28 DATADISK003 -> ../sdj 
    lrwxrwxrwx 1 root root 6 Jun 29 11:45 DATADISK004 -> ../sdk     

Translation
Download
Updated: 2018-12-26

Document ID: EDOC1100035759

Views: 20619

Downloads: 30

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next