ASM Disk Addition(Linux)

1. Introduction

ASM Disk is used by Oracle Database server. However, Unix team need to scan the new disk allocated to the server by Storage team and Label the new luns if required. Once the new disk/lun is visible in the server we will provide the details to Database Team so that they can add the disk into their Database.

Implementation:

Step 1:
Scan the new Luns. Check how many Scsi hosts are available

# ls –l /sys/class/scsi_host/

# echo “- – -” > /sys/class/scsi_host/host1/scan

# echo “- – -” > /sys/class/scsi_host/host2/scan

# echo “- – -” > /sys/class/scsi_host/host3/scan

# echo “- – -” > /sys/class/scsi_host/host4/scan

For fibre channel you have to scan like below.

# echo “1” >/sys/class/fc_host/host0/issue_lip
# echo “1” >/sys/class/fc_host/host1/issue_lip

Step 2:

Verify the new Lun with the LDEV number provided by Storage side.

# multipath –ll | grep –I

# /opt/osit/linux/bin/xpinfo -il | grep -i

Step 3:

Provide the new lun details to Requestor/Database Team

Step 4:

Add the Alias name for the new lun which they have provided..
Example:

Before change:

# vi /var/lib/multipath/bindings

mpatha 3600508b1001034323720202020200000 mpathd 350002ac92e6c1340 mpathe 350002ac92ec31340 mpathf 350002ac92ec81340

After Change:

# vi /var/lib/multipath/bindings

mpatha 3600508b1001034323720202020200000

IVR_DATA_14 350002ac92e6c1340 IVR_DATA_15 350002ac92ec31340 IVR_DATA_16 350002ac92ec81340

Step 5:

Reload the multipath daemon

# service multiapthd reload

Step 6:

#create Partition or relabeled it.

/dev/mapper/asm001p1

#cd /dev/asmdevices

ls -lrt asm001p1 you can see the partition here.

 

Step 7:

#check which oracleasm

/#/etc/init.d/oracleasm listdisks—list all the oracle asm disk

Step 8:

need to add newly created partion over oracle asm

#/etc/init.d/oracleasm createdisk <ASMdevicename> /dev/asmdevices/asm001p1

below output will come

marking disk “ASMdevicename” as an ASM disk

 

#/etc/init.d/oracleasm scandisks

 

#/etc/init.d/oracleasm listdisks

================================================

for querydisk ASMdevicename

 

# /etc/init.d/oracleasm querydisk ASMdevicename
Disk “ASMdevicename is a valid ASM disk on device [8, 81]—>you
will get major and minor no.

Then check the numbers belongs to which disk.
]# ls -l /dev | grep 8,| grep 81
brw-rw—-1 root dis 8 , 81 Oct 29 20:42 sdf1

 

Leave a comment