• How to create Oracle ASM devices using device-mapper multipath devices in Red Hat Enterprise Linux 6


    How to create Oracle ASM devices using device-mapper multipath devices in Red Hat Enterprise Linux 6?

    环境

        Red Hat Enterprise Linux 6
        Device-Mapper Multipath (DM Multipath)
        Oracle ASM
        Udev

    决议

        Please use the following steps to create Oracle ASM disks with dm-multipath on RHEL 6 systems:

        Determine the DM_UUID value for each multipath device that is required to be used for Oracle ASM. You could use following command for the same:

        $ udevadm info --query=all --name=/dev/mapper/mpathN |grep -i DM_UUID

        Please replace mpathN in above command with name of the multipath devices used in your setup/environment.

        The output of above command would be similar to the one shown below:

        $ udevadm info --query=all --name=/dev/mapper/mpathd|grep -i DM_UUID
        E: DM_UUID=mpath-1234567890abcdefghijklmnopqrstuvwxyz

        Above command would be required to be repeated for each multipath device to be used with Oracle ASM, and please note down the DM_UUID value retrieved for each multipath device. This value would be used to create udev rule.

        Create a udev rule file /etc/udev/rules.d/96-asmmultipath.rules and add a udev rule for each multipath device using it's DM_UUID value:

        ACTION=="add|change", ENV{DM_UUID}=="mpath-<UUID>", SYMLINK+="oracleasm/asm01", GROUP="dba", OWNER="oracle", MODE="0660"

        e.g. to create Oracle ASM disk /dev/oracleasm/asm01 using above multipath device mpathd following udev rule could be used:

        $ cat /etc/udev/rules.d/96-asmmultipath.rules
        ACTION=="add|change", ENV{DM_UUID}=="mpath-1234567890abcdefghijklmnopqrstuvwxyz", SYMLINK+="oracleasm/asm01", GROUP="dba", OWNER="oracle", MODE="0660"

        Note that we have replaced mpath-<UUID> in above rule with the DM_UUID retrieved in step [1]. Similarly a udev rule for each multipath device would be required to be appended in /etc/udev/rules.d/96-asmmultipath.rules file.

        You could also modify Symlink path (e.g. oracleasm/asm01 in above udev rules), Group, Owner permissions as per requirement.

        Reload the udev service for the changes to take effect and create the ASM disks.




  • 相关阅读:
    洛谷 P6599 「EZEC-2」异或 题解
    线段树懒标记以及标记永久化的两种实现方法(模板)
    洛谷P3834 【模板】可持久化线段树 1 题解
    Codeforces 1012B Chemical table (思维+二分图)
    HDU 6386 Age of Moyu (最短路+set)
    CodeForces 739B Alyona and a tree (二分+树上差分)
    Codeforces 444C DZY Loves Colors (线段树)
    HDU 5441 Travel (离线dsu)
    Codeforces 1000E We Need More Bosses (边双连通+最长链)
    CodeForces 219D Choosing Capital for Treeland (树形DP)经典
  • 原文地址:https://www.cnblogs.com/djinmusic/p/4179643.html
Copyright © 2020-2023  润新知