====== Installing to an iSCSI target using WDS ====== Windows Deployment Services (WDS) is the component of Windows Server that allows you to install Windows over the network. If you are using iPXE, then you can use Windows Deployment Services to install Windows Server 2008, Windows Server 2012, Windows 7, Windows 8, or Windows 10 directly to an iSCSI target on your network. ===== Prerequisites ===== You must already have a working Windows Deployment Services installation, complete with a Boot Image and at least one Install Image: {{ :screenshots:wds.png?730x319 |Windows Deployment Services console}} ===== Instructions ===== Create a DHCP reservation for each diskless computer that you want to install directly to an iSCSI target. Go to **Start** -> **Administrative Tools** -> **DHCP** and open up your DHCP scope. Right-click on **Reservations** and choose **New Reservation**: {{ :screenshots:msdhcp_new_reservation.png?375x411 |Adding a new reservation}} Fill in the basic details for this reservation: {{ :screenshots:msdhcp_reservation.png?358x345 |Filling in reservation details}} Click on **Add** to create the reservation, and then **Close** to close the dialog box. Right-click on the new reservation and choose **Configure Options**: {{ :screenshots:msdhcp_reservation_options.png?455x396 |Configuring new options}} Scroll down to option **017 Root Path** and enter the iSCSI root path for the installation. For example, to boot from the iSCSI target at ''10.253.253.1'' using the IQN ''iqn.2010-04.org.ipxe:rabbit'', you would set option **017 Root Path** to iscsi:10.253.253.1::::iqn.2010-04.org.ipxe:rabbit {{ :screenshots:msdhcp_set_root_path.png?414x462 |Configuring the iSCSI root path}} Boot the diskless computer using iPXE. (If the diskless computer does not have an iPXE boot ROM, then you will need to set up [[:howto:msdhcp#pxe_chainloading|PXE chainloading]].) You should see the diskless computer connect to the iSCSI target and then prompt you to "''Press F12 for network service boot''": {{ :screenshots:wds_boot.png?540x300 |Booting from WDS with an iSCSI root path}} Press ''F12'' to boot from the network, and proceed to install Windows as usual. When you reach the "''Where do you want to install Windows?''" screen, you should see the iSCSI disk appear as a possible install location: {{ :screenshots:wds_select_disk.png?600x450 |Selecting the iSCSI disk}} Congratulations on successfully using WDS to install Windows to an iSCSI target! {{ :clipart:smile.png?200x200 |Success}} ===== Troubleshooting ===== You may need to specify an [[:cfg:initiator-iqn|iSCSI initiator IQN]] to gain access to the iSCSI target. If the iSCSI disk does not appear as a possible install location, then you can use the Windows command prompt to diagnose the problem. Press ''Shift-F10'' to access the command prompt. * Type ''ipconfig'' and check that you have successfully obtained an IP address from your DHCP server. * Type ''route print'' and check carefully that the routing table appears to be sensible. Note that Windows [[http://support.microsoft.com/kb/960104|will always create a static route to the iSCSI target via the default gateway]], even if the iSCSI target is on the same subnet. Many routers will not forward packets back to the originating subnet, causing communication with the iSCSI target to fail once Windows takes over. You can work around this problem: * If the default gateway is not required for booting (i.e. if you are booting entirely from the local subnet), then you can use the iPXE [[:cmd|command]]set netX/gateway 0.0.0.0 to delete the default gateway before booting from the iSCSI target. * If the default gateway is required for booting, then you can configure the router to forward packets back to the originating subnet. For example, if your router is using [[http://www.shorewall.net/|Shorewall]], then adding the ''[[http://www.shorewall.net/manpages/shorewall-interfaces.html|routeback]]'' option should fix the problem. * Check that you can ping the iSCSI target. * Examine the Setup log using \\ notepad x:\windows\panther\setupact.logCheck for the ''DiskInfo'' lines, which should contain information such as \\ DiskInfo:===== Disk number [0] ===== DiskInfo: Friendly name: [LIO-ORG rabbit SCSI Disk Device] DiskInfo: Arc path: [multi(0)disk(0)rdisk(0)] DiskInfo: Disk signature [0x9A7083D5] DiskInfo: Size (bytes) [17179869184 / 0x400000000] DiskInfo: Disk bus type: [iSCSI] ...Also check for the line Callback_BootstrapApplyWpeSettings: Detected iBFT; setup will initialize networking support for iSCSI If you are unable to resolve your problem, then you can [[:contact]] the iPXE developers and other iPXE users.