ASM(一)多路径创建基于ASMLIB的磁盘

1 Check the disks :

ls -l /dev/mapper

brw-rw---- 1 root disk 253, 46 Jul 27 17:19 Prod_Orcl01

brw-rw---- 1 root disk 253, 67 Jul 27 17:59 Prod_Orcl02

brw-rw---- 1 root disk 253, 36 Jul 27 17:19 Prod_Orcl03

brw-rw---- 1 root disk 253, 58 Jul 27 18:00 Prod_Orcl04

 2Configure ASMLIB to use multipath  (from each node on RAC environments):

By any path the ASMLIB can found the disks, but, the best path is using the multipath :

Modify in /etc/sysconfig/oracleasm :
ORACLEASM_SCANORDER=”dm”
ORACLEASM_SCANEXCLUDE=”sd”

note: The Oracle ASMLib configuration file is located at /etc/sysconfig/oracleasm. It is a link to file /etc/sysconfig/oracleasm-_dev_oracleasm.

Restart ASMLIB (from each node on RAC environments):
/etc/init.d/oracleasm stop
/etc/init.d/oracleasm start

 

3. Create the ASMLIB disks on mapper partitions as follow:

/etc/init.d/oracleasm createdisk DSKORA1  /dev/mapper/Prod_Orcl01

/etc/init.d/oracleasm createdisk DSKORA2  /dev/mapper/Prod_Orcl02

After create the disks, the ASM put a mark on the disks to know which are your own.

 

4. If this is a RAC configuration, then from each node execute:

/etc/init.d/oracleasm scandisks

/etc/init.d/oracleasm listdisks

 

 

5. Verify if the configuration is correct:

 

5.1 During the disk discovery, ASMLIB uses file /proc/partitions, see :

# cat /proc/partitions

   8     0  877264896 sda

   8     1     104391 sda1

   8     2  877157032 sda2

   8    16  209715200 sdb

   8    32  382730240 sdc

   8    48  379596800 sdd

   8    64    2097152 sde

   8    80    2097152 sdf

   8    96 1169776640 sdg

 253     6  209715200 dm-6

 253     7  382730240 dm-7

 253     8  379596800 dm-8

 253     9    2097152 dm-9

 253    10    2097152 dm-10

5.2 The ASMLIB mount disks at /dev/oracleasm/disks, see:

# ls -la /dev/oracleasm/disks

brw-rw---- 1 grid asmadmin 2536 Ago 16 16:33 DSKORA1

brw-rw---- 1 grid asmadmin 2537 Ago 16 16:33 DSKORA2

5.3 Check if major and minor of disks “dm” not “sd”, is the same in /proc/partitions  and /dev/oracleasm/disks , see “253″ and “6″ bellow:

/proc/partitions 253     6  209715200 dm-6

/dev/oracleasm/disks

brw-rw---- 1 grid asmadmin 2536 Ago 16 16:33 DSKORA1

You can check using querydisk too :

# /etc/init.d/oracleasm querydisk -d DSKORA1

Disk "DSKORA1" is valid ASM disk on device [253, 6]

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/80930/viewspace-759319/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/80930/viewspace-759319/

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值