Sunday, 19 March 2017

How to present NetApp Cluster Mode LUN to Redhat Linux via iSCSI Protocol

On the SVM side: I assume the iSCSI License is added and the iSCSI service is up and running.
1. Carve out a volume, or let it create during LUN create process via gui..
2. Create a LUN and also create a iGROUP and add the 'Redhat Linux' Initiator to this iGROUP and make sure you it says online and mapped.

Note: Use this command to obtain the Redhat Initiator:
[root@redhatcentos Desktop]#cat /etc/iscsi/initiatorname.iscsi

On the Redhat side: Just remember these three letters- D,L,S [Discovery, Login & Scan]
[root@redhatcentos Desktop]# iscsiadm -m discovery -t st -p 192.168.0.29:3260
[root@redhatcentos Desktop]# iscsiadm -m node -l
Note: If you see any old stale connections, just get rid of them.
[root@redhatcentos Desktop]# iscsiadm -m node -o delete -T iqn.1992-08.com.netapp:sn.4082367740
[root@redhatcentos Desktop]# iscsiadm -m session --rescan
Rescanning session [sid: 1, target: iqn.1992-08.com.netapp:sn.34636feba74e11e6a5bb000c2900a32a:vs.2, portal: 192.168.0.29,3260]

Finally, run the following command to see the LUN:
[root@redhatcentos Desktop]# multipath -ll
3600a09807770457a795d4a6736723230 dm-0 NETAPP,LUN C-Mode
size=1.0G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=rw
`-+- policy='round-robin 0' prio=4 status=active
  `- 3:0:0:0 sdb 8:16 active ready running
[root@redhatcentos Desktop]#

If you don't have multipath module driver installed, you can use this command;
[root@redhatcentos Desktop]# lsscsi

No comments:

Post a Comment