Wednesday, 19 March 2014

iscsi -multipath-and emc power path config and start in linux

iscsi -multipath-and emc power path config and start in linux

Configure Target on Client (Without Multipath)
--------------------------

1) start iscsi service
   # /etc/init.d/iscsi start


2) Discover the Targets
   # iscsiadm -m disovery -t st -p 192.168.2.1   

3) Persistent Logging & Binding the Lun on client.
   # iscsiadm -m node -T iqn.2008-09.com.vrk:iso.storet1 -p
192.168.2.133 -l
               (or just restart the service)
   # /etc/init.d/iscsi restart 

4) fdisk -l 



Remove the Target from client
-----------------------------
1) Just logoff the target 
   # iscsiadm -m node -T iqn.2008-09.com.vrk:iso.storet1 -p
192.168.2.133 -u

2) Delete the record from the buffer 
   # iscsiadm -m node -o delete  -T iqn.2008-09.com.vrk:iso.storet1
-p
192.168.2.133 -u

3) fdisk -l



Multipath configration:
------------------------

1) Discover ISCSI Luns 
2) Restart ISCSI service to get Luns
3) Configure Multipath:
   # vi /etc/multipath.conf
        ...
        ...
     ######### Modify blockdevices (exclude the HDD already exists )
######
      blacklist {
        devnode "^hd[a-z]|sda|dm-[0-9]*"
 }
      
     ######## Cofigure Multipaths ##########
     
       multipaths {

        #### Path1
 multipath {
                wwid                   
14f70656e66696c000000000002000000d45300000f000000
                alias                   yellow  ## Alias name for
Path1
                path_grouping_policy    multibus
                path_checker            readsector0
                path_selector           "round-robin 0"
                failback                manual
                rr_weight               priorities
                no_path_retry           5
        }

 #### Path2
        multipath {
                wwid                   
14f70656e66696c000000000001000000674500000f000000
                alias                   green ## Alias name for Path2
                path_grouping_policy    multibus
                path_checker            readsector0
                path_selector           "round-robin 0"
                failback                manual
                rr_weight               priorities
                no_path_retry           5
        }
 }

 #########
        Generate wwid number using command
        /sbin/scsi_id -g -u -s /block/sda
        /sbin/scsi_id -g -u -s /block/sdb...

4) Restart Multipath service
       # /etc/init.d/multipathd start

5) Disk usage
   ----------
   Use the disk names with Yellow,Greewn ...(Alias names defined in
mulitpath configuratoin)

   /dev/mapper/yellow
   /dev/mapper/greenp1  (Partition1 on Disk name green)


   # fdisk /dev/mapper/yellow
   # mount /dev/mapper/greenp1 /mountpoint

*****************************************************************
iscsiadm -m discovery -t sendtargets -p 192.168.5.210
iscsiadm -m discovery -t sendtargets -p 192.168.5.211

service iscsi restart
df -H

 powermt display dev=all
 pvscan
 vgscan
df -H
lvdisplay
cat /etc/fstab
mount -a
/etc/init.d/iscsi status
/etc/init.d/iscsi restart
/etc/init.d/multipathd status
/etc/init.d/multipathd start
/etc/init.d/multipathd status
multipath -l
fdisk -l
/etc/init.d/multipathd stop
sh /etc/init.d/emcp_mond.sh
sh /etc/init.d/emcp_mond.sh start
history grep |emc
 iscsiadm -m discovery -t sendtargets -p 192.168.5.210
/etc/init.d/PowerPath start
 powermt  config
powermt display dev=all
fdisk -l
df -H
pvscan
vgscan
mount -a
df -H
cd /u05
ll
cd  oradata/
ll
cd ..
su - oracle
history
exit
history

No comments:

Post a Comment