linux_wiki:iscsi

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
linux_wiki:iscsi [2015/12/17 15:29]
billdozor created
linux_wiki:iscsi [2019/05/25 23:50] (current)
Line 1: Line 1:
-====== Iscsi ======+====== iSCSI ======
  
 **General Information** **General Information**
Line 6: Line 6:
  
 **Checklist** **Checklist**
-  * Enterprise Linux 6+  * Distro(s): Enterprise Linux 6/7 
 + 
 +---- 
 + 
 +====== Adding Disks ===== 
 + 
 +  - Get the iscsi initiator name on the client<code bash>cat /etc/iscsi/initiatorname.iscsi</code> 
 +  - Use the initiator name to configure the Host Group, LUN, and Host Affinity on your storage device. (Or send the initiator name to the storage admin) 
 +  - From the client, discover the available LUNs on the storage device<code bash>iscsiadm --mode discovery -t sendtargets --portal <storage-ip-address></code> 
 +  - Start and enable the iscsi daemon 
 +    - EL6<code bash>service iscsid start 
 +chkconfig iscsid on</code> 
 +    - EL7<code bash>systemctl start iscsid 
 +systemctl enable iscsid</code> 
 +  - Log-in to the LUN with the iscsi client<code bash>iscsiadm --mode node --targetname <iqn-LUN#-here> --portal <storage-ip-address>:<port> --login</code> 
 +  - Create /etc/multipath.conf if it doesn't exist<code bash>mpathconf --enable</code> 
 +  - Configure multipath<code bash>vim /etc/multipath.conf 
 +# Blacklist exception for your device 
 +blacklist_exceptions { 
 +    # WWN of LUN via iSCSI LUN group 
 +    wwid "123456789" 
 +
 + 
 +# Setup your storage device specifics 
 +devices { 
 +      device { 
 +              vendor "DELL" 
 +              product "MODEL-HERE" 
 +              # specify other options 
 +      } 
 + } 
 + 
 +# Setup the multipath 
 +multipaths { 
 +   multipath { 
 +      wwid 123456789 
 +      alias friendly_name_here 
 +   } 
 +
 +</code> 
 +  - Start and enable multipathd 
 +    - EL6<code bash>service multipathd start 
 +chkconfig multipathd on</code> 
 +    - EL7<code bash>systemctl start multipathd 
 +systemctl enable multipathd</code> 
 +  - Re-scan the scsi bus<code bash>echo "- - -" > /sys/class/scsi_host/<host_number>/scan</code> 
 +    - Where <host_number> is something like: host0 (there will probably be host0-3) 
 +    - The hyphens represent controller,channel,lun, so – - – indicates all controllers, all channels, and all luns should be scanned. 
 +  - Verify paths<code bash>multipath -ll</code> 
 +  - Add mount entry to /etc/fstab 
 + 
  
 ---- ----
Line 66: Line 116:
  
 After, restart multipathd to ensure it doesn't come back After, restart multipathd to ensure it doesn't come back
-<code bash> +  * EL6<code bash>service multipathd restart</code> 
-service multipathd restart +  * EL7<code bash>systemctl restart multipathd</code>
-</code>+
  
 ---- ----
  
  • linux_wiki/iscsi.1450384153.txt.gz
  • Last modified: 2019/05/25 23:50
  • (external edit)