tag:blogger.com,1999:blog-497573883669761770.post-62618902637543059172007-12-19T17:10:00.000-08:002007-12-19T17:12:36.417-08:00Windows, iSCSI and NAS (Network-attached Storage) in Test Environment<p>Recently, I worked on a project to be deployed on a <strong>Windows servers cluster</strong>.<br />Before setting up the production environment, it was necessary to check if one of the required applications will work on a cluster.<br /><br />To those of you who doesn’t know what a cluster is, just take a look at what’s written on Wikipedia: <a href="http://thesystemadministrator.com/redir?en.wikipedia.org/wiki/Computer_cluster" title="" target="_blank">http://en.wikipedia.org/wiki/Computer_cluster</a></p> <p> That time, I had no extra servers for testing, so I decided to setup the cluster in a virtual environment. To do this, I created 2 <strong>Windows 2003 Servers </strong>on my <strong>VMWARE </strong>station.<br />However, the biggest problem was the storage space.<br /><br />Anyone who worked at least once with clusters, knows that they need a shared storage, also called a <strong>NAS</strong> (<strong><em>Network-attached Storage</em></strong>).<br />Unfortunately, I have no <strong>NAS</strong> in my lab, so I used another technique for my test.<br />If you do Googling a bit, you will find a lot of Linux-based NAS software, like <strong>FreeNAS</strong>.<br /><br />However, I wanted a Windows-based software and I founded probably one of the best (IMHO), which is <strong>StarWind</strong>, available for <strong>FREE</strong> in a <em><strong>Personal edition</strong></em>.<br />Now, I’m not going to show you how to install a cluster, I just would like to show how to connect two (or more) servers to the same <strong>Network-attached Storage</strong> by using the <strong>iSCSI technology</strong>, and how to do this in a test environment.</p> <p>When you launch StarWind for the first time, you will see a screen like this one:</p> <div align="center"><img alt="" title="" src="http://thesystemadministrator.com/images/iSCSI-tartget-1.png" height="" width="" /><br /></div> <p> The first step is to add a device.<br />To do this, right click on the <em><strong>localhost:3260</strong></em> icon and select <strong>Connect</strong>.<br />For the <em><strong>username</strong></em> and <em><strong>password</strong></em>, simply use the word <span style="color:#ff0000;"><strong><em>test</em></strong></span>.<br /><br />When the connection will be established, click on the <strong>Add device</strong> button to display the following screen:</p> <div align="center"> <p><img alt="" title="" src="http://thesystemadministrator.com/images/iSCSI-tartget-2.png" height="" width="" /><br /></p></div> <p>Here, select <strong>Image File device</strong> and click on the<strong> Next </strong>button.<br /><br />On the next window, select <strong>Create new image</strong> and click on the <strong>Next </strong>button. You'll have to enter a name, a location and a size for the image.<br />For best performance, it's recommended to avoid image compression and encryption.<br />The next screen is of the highest importance.</p> <div align="center"><img alt="" title="" src="http://thesystemadministrator.com/images/iSCSI-tartget-3.png" height="" width="" /><br /></div> <p><strong>REMEMBER</strong> to select <strong><em>Allow multiple concurrent iSCSI connections (clustering)</em></strong>. <br />If you forgot to select this option, your cluster setup will fail.<br /><br />The next steps are just about few clicks on some <strong>Next</strong> buttons and a <strong>Finish</strong> one.<br /><br />Finally, you should see a screen similar to this one:</p> <div align="center"><img alt="" title="" src="http://thesystemadministrator.com/images/iSCSI-tartget-4.png" height="" width="" /><br /></div> <p> Before connecting the <strong>Windows Server 2003</strong> to the <strong>iSCSI storage</strong>, we need to install the <strong>iSCSI Initiator</strong>, that can be downloaded from Microsoft.<br /><br />While I was writing this article, the setup of a <strong>Windows Server 2008 RC1 with Hyper-V Beta</strong> finished.<br /><br />Since the procedure for connecting iSCSI disks to a Windows Server 2008 is quite similar to connecting them to a Windows Server 2003, I'd like to show how to do this on a Windows Server 2008.<br /><br />So, from the Control Panel we start iSCSI initiator. When we do that for the first time, we get the message below:</p> <div align="center"><img alt="" title="" src="http://thesystemadministrator.com/images/iSCSI-tartget-5.png" height="" width="" /><br /></div> <p> Click on the <strong>Yes</strong> button. On the next window also click on the <strong>Yes</strong> button and you will see the following window:</p> <div align="center"><img alt="" title="" src="http://thesystemadministrator.com/images/iSCSI-tartget-6.png" height="" width="" /><br /></div> <p> Click on the <strong>Discovery</strong> tab, click on the <strong>Add Portal </strong>button, enter the<strong> IP address</strong> of the <strong>iSCSI </strong>machine (<em>where StarWind is installed</em>), and click on the <strong>OK</strong> button.<br /><br />Click on the <strong>Targets</strong> tab, and click on the <strong>Log on</strong> button.<br /><br />Select the options according to the picture below, and then don't forget to click on the <strong>OK</strong> button.</p> <div align="center"><img alt="" title="" src="http://thesystemadministrator.com/images/iSCSI-tartget-7.png" height="" width="" /><br /></div> <p> Click on the <strong>Volumes and Devices</strong> tab, and click on the <strong>Autoconfigure</strong> button.<br /><br />Now, we are ready to click on the last <strong>OK </strong>button, and go to the <strong>Disk Management</strong>.<br /><br />If all the previous steps were done correctly, you should see a screen similar to this one:</p> <div align="center"><img alt="" title="" src="http://thesystemadministrator.com/images/iSCSI-tartget-8.png" height="" width="" /><br /></div> <p> The next steps are very simple, and I don't think that I've to explain how to create a <strong>volume</strong> and a <strong>partition</strong> in Windows.<br /><br />When done, if we open <strong>My Computer </strong>we will see a new <strong>Local Disk</strong>, like in my example:</p> <div align="center"><img alt="" title="" src="http://thesystemadministrator.com/images/iSCSI-tartget-9.png" height="" width="" /><br /></div> <p> At this point, we have successfully configured an <strong>iSCSI storage</strong> under <strong>Windows</strong>, and we are ready to go on.</p>Michael Khaninhttp://www.blogger.com/profile/10032281165922418711noreply@blogger.com