{"id":10,"date":"2010-04-17T13:32:37","date_gmt":"2010-04-17T20:32:37","guid":{"rendered":"http:\/\/inbaudwetrust.com\/?p=10"},"modified":"2010-04-17T13:32:37","modified_gmt":"2010-04-17T20:32:37","slug":"enabling-round-robin-and-mpio-on-esxi-4","status":"publish","type":"post","link":"https:\/\/inbaudwetrust.com\/wp\/?p=10","title":{"rendered":"Enabling Round Robin and MPIO on vSphere4"},"content":{"rendered":"<p>The purpose of this article is explain how to enable round  robin and multipathing on an ESXi4 cluster.<\/p>\n<p>Our environment consists of:<\/p>\n<ul>\n<li>48 HP BL460cG1 servers running ESXi4 embedded with qlogic fc mezzanine cards(2 hba&#8217;s\/host)<\/li>\n<li>3 C7000 Chassis with VC-Enet modules and Cisco MDS9124 switches<\/li>\n<li>SAN fabric connected to an HP EVA 8400<\/li>\n<\/ul>\n<p>These instructions are primarily from HP and are SPECIFICALLY FOR THE EVA!\u00a0 Check with your SAN vendor for their recommendations.\u00a0 The shared storage in our environment is all fibre channel, so these instructions will most likely not work on iSCSI or shared storage over other protocols.\u00a0 This article assumes you have two hba&#8217;s per host as well.\u00a0 Also make sure that your SAN or LUN\u2019s are setup for an  active\/active configuration otherwise you\u2019ll have problems with LUN  trespassing.\u00a0 Most newer SAN\u2019s are active\/active by default, but some  SAN\u2019s such as some of the older EMC CX series are setup for  active\/passive and you have to use powerpath or a vendor specific product in order to setup true multi-pathing on a host.\u00a0 Perform these steps at your own risk!  If you&#8217;re not comfortable with any part of this then do some research, reference the sources at the bottom of the page, or call VMWare support before you go ahead with this.  Now that we\u2019ve  got the disclaimers out of the way, let\u2019s get down to the good stuff.\u00a0 The whole process consists of approximately 3 steps: enabling round robin on all LUN&#8217;s on all hosts in the cluster, setting each host to use both preferred and non-preferred paths, and finally telling each host how many iops before it switches paths, utilzing both paths more effectively and helping to spread the load across both controllers on your SAN.<\/p>\n<p><strong>Enabling Round Robin<\/strong><br \/>\nSet multi-path policy to Round Robin on all LUN&#8217;s on all hosts in a cluster using PowerCLI:<\/p>\n<pre>Get-VMHost -Location &lt;Clustername&gt;|Get-ScsiLun -LunType \"disk\"|where {$_.MultipathPolicy \u2013ne \"RoundRobin\"}|Set-ScsiLun -MultipathPolicy \"RoundRobin\"<\/pre>\n<p>Check to see if it took:<\/p>\n<pre>Get-VMHost -Location &lt;Clustername&gt;|Get-ScsiLun<\/pre>\n<p><span style=\"color: #ff0000;\"><em>The following steps are run in the &#8220;unsupported console&#8221;.\u00a0 Google to see how to enable ssh on each host.<\/em><\/span><\/p>\n<p><strong>Set the default Path Selection Policy(PSP) to Round Robin and SATP to VMW_SATP_ALUA on each host<br \/>\n<\/strong><\/p>\n<pre>esxcli nmp satp setdefaultpsp --satp VMW_SATP_ALUA --psp VMW_PSP_RR<\/pre>\n<p><strong>Set the LUN&#8217;s to use preferred and non-preferred paths<\/strong><br \/>\nLogin to each host and type in the following command:<\/p>\n<pre>for i in `ls \/vmfs\/devices\/disks\/ | grep naa.600` ; do esxcli nmp roundrobin setconfig --useANO 1 --device $i ;done<\/pre>\n<p>You might get some errors, but run this command to see if it took:<\/p>\n<pre>esxcli nmp device list |grep ANO=<\/pre>\n<p><strong>Set amount of iops before it switches paths<\/strong><\/p>\n<pre>for i in `ls \/vmfs\/devices\/disks\/ | grep naa.600` ; do esxcli nmp roundrobin setconfig --type \"iops\" --iops=1 --device $i ;done<\/pre>\n<p>By default this is set to 1000, and you&#8217;ll have to write a script that runs on startup as the setting doesn&#8217;t keep over a reboot.  In fact it seems that if you touch the iops= setting, then after a reboot it&#8217;s replaced with a random number.<br \/>\nCheck the sources below for more detailed information, especially the top link which is the HP &#8220;Official&#8221; best practices document for this scenario.<\/p>\n<p>-bb<\/p>\n<p><em>Sources:<\/em><\/p>\n<ul>\n<li><a title=\"Configuration best practices for HP StorageWorks Virtual Array and VMWare vSphere 4\" href=\"http:\/\/h20195.www2.hp.com\/v2\/GetPDF.aspx\/4AA1-2185ENW.pdf\" target=\"_blank\">Configuration best practices for HP StorageWorks Enterprise Virtual Array (EVA) family and VMware vSphere 4<\/a><\/li>\n<li> <a href=\"http:\/\/blogs.vmware.com\/storage\/2009\/10\/vstorage-multi-paths-options-in-vsphere.html\">vStorage Multi Paths Options in vSphere<\/a><\/li>\n<li><a href=\"http:\/\/www.boche.net\/blog\/index.php\/2010\/02\/04\/configure-vmware-esxi-round-robin-on-emc-storage\/\" target=\"_blank\">Configure VMWare ESXi Round Robin on EMC Storage<\/a><\/li>\n<li> <a href=\"http:\/\/www.ivobeerens.nl\/?p=465\" target=\"_blank\">Best Practices for HP EVA, vSphere 4 and Round Robin multi-pathing<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>The purpose of this article is explain how to enable round robin and multipathing on an ESXi4 cluster. Our environment consists of: 48 HP BL460cG1 servers running ESXi4 embedded with qlogic fc mezzanine cards(2 hba&#8217;s\/host) 3 C7000 Chassis with VC-Enet modules and Cisco MDS9124 switches SAN fabric connected to an HP EVA 8400 These instructions&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[20,27,28,31,36],"class_list":["post-10","post","type-post","status-publish","format-standard","hentry","category-vsphere","tag-hp-eva","tag-mpio","tag-multi-pathing","tag-powercli","tag-round-robin"],"_links":{"self":[{"href":"https:\/\/inbaudwetrust.com\/wp\/index.php?rest_route=\/wp\/v2\/posts\/10","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/inbaudwetrust.com\/wp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/inbaudwetrust.com\/wp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/inbaudwetrust.com\/wp\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/inbaudwetrust.com\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=10"}],"version-history":[{"count":0,"href":"https:\/\/inbaudwetrust.com\/wp\/index.php?rest_route=\/wp\/v2\/posts\/10\/revisions"}],"wp:attachment":[{"href":"https:\/\/inbaudwetrust.com\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=10"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/inbaudwetrust.com\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=10"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/inbaudwetrust.com\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=10"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}