====== Installing the iSCSI Enterprise Target on Fedora 8 ====== ==== Background ==== The words //target// and //initiator// have special meanings in the storage world. An //initiator// requests disk services from a //target//. You can generally think of the the disk drive itself as the target and the storage controller as the initiator. Initiators initiate transactions with targets. A simple desktop computer has a single SCSI drive. The SCSI controller is the initiator and the SCSI hard drive is the target. Let's say we have a server that has a SCSI controller connected to an external RAID storage array. The SCSI controller is still the initiator. The RAID storage controller is a fancier target that provides virtual disk services. The RAID controller presents one or more virtual disks that are higher-performance and/or more reliable than individual physical disks. Fibre Channel (FC) storage systems were designed primarly to overcome some of the electrical limitations of the SCSI bus. In the FC world, the initiator is generally called a Host Bus Adapter, or HBA for short. The target in a Fibre Channel Storage Area Network FC SAN is a SAN storage controller. The FC SAN storage controller presents SCSI virtual disks to FC HBA initiators on the SAN. FC initiators and targets encapsulate SCSI command data blocks and send them over the Fibre Channel transport. iSCSI is an encapsulation of SCSI commands in a TCP/IP transport. This allows exchange of SCSI data over standard networks using stock hardware. A hardware iSCSI initiator is called an iSCSI HBA. An iSCSI HBA has a 1Gb NIC (Network Interface Card) built into it along with a dedicated CPU that implements the TCP/IP stack. A software iSCSI initiator uses the TCP/IP stack that is built into the operating system to send iSCSI commands over the NIC (or NICs) that are built into the computer. An iSCSI target presents virtual SCSI disks over TCP/IP transport. Many NAS (Network Addressable Storage) systems have built-in support for iSCSI. Existing FC SANs can also be extended to support iSCSI. The manufacturer of a FC SAN storage controller sells an optional component called an //iSCSI head// that does iSCSI <-> Fibre Channel translation. Third party vendors sell //storage routers// that perform a similar function. Finally, some manufacturers build dedicated iSCSI SAN storage arrays. ==== iSCSI Enterprise Target Overview ==== The iSCSI Enterprise Target, IET, (http://iscsitarget.sourceforge.net/) provides iSCSI target services on Linux. You can think of it as a software implementation of a SCSI disk drive that uses iSCSI encapsulation. The storage that it uses for these virtual disk drives comes from the file system. Essentially, if you want to present a 5G disk then create a 5G file and configure IET to share it with the appropriate initiator. Unfortunately, as of Jan 2008 setting up IET is non-trivial. RPM packages are not part of the standard Fedora repositories so you need to do a little work to get IET up and running. Compiling IET from the sources requires compilation of kernel modules that are kernel-version specific. This level of complexity is something that scares away many linux users. This How-To documents an alternate method that describes how to install and configure iSCSI Enterprise Target on Fedora 8 using RPM packages from the http://rpm.livna.org/ repositories. ==== Here we go ==== As of January 2008 ... * Install Fedora 8 * execute all the following commands as root * use ''pup'' or ''yum update'' to get the latest packages [root@dl360g2c ~]# yum update Setting up Update Process No Packages marked for Update [root@dl360g2c ~]# * reboot if you downloaded a new kernel. If in doubt, reboot. * observe that there is more than one kernel kernel package on your system [root@dl360g2c ~]# rpm -qa | grep kernel-2.6 kernel-2.6.23.1-42.fc8 kernel-2.6.23.9-85.fc8 [root@dl360g2c ~]# * get ''yum'' access to the livna http://rpm.livna.org Fedora 8 repository [root@dl360g2c ~]# rpm -ivh http://rpm.livna.org/livna-release-8.rpm Retrieving http://rpm.livna.org/livna-release-8.rpm warning: /var/tmp/rpm-xfer.CBhaqZ: Header V3 DSA signature: NOKEY, key ID a109b1ec Preparing... ########################################### [100%] 1:livna-release ########################################### [100%] [root@dl360g2c ~]# * try to install the iscsitarget kernel modules [root@dl360g2c ~]# yum install kmod-iscsitarget livna 100% |=========================| 2.1 kB 00:00 primary.sqlite.bz2 100% |=========================| 192 kB 00:00 Setting up Install Process Parsing package install arguments Resolving Dependencies --> Running transaction check ---> Package kmod-iscsitarget.i686 1:0.4.15-5.svn142.lvn8 set to be updated --> Processing Dependency: kmod-iscsitarget-2.6.23.8-63.fc8 = 1:0.4.15-5.svn142.lvn8 for package: kmod-iscsitarget --> Running transaction check ---> Package kmod-iscsitarget-2.6.23.8-63.fc8.i686 1:0.4.15-5.svn142.lvn8 set to be updated --> Processing Dependency: iscsitarget-kmod-common >= 1:0.4.15 for package: kmod-iscsitarget-2.6.23.8-63.fc8 --> Processing Dependency: kernel-i686 = 2.6.23.8-63.fc8 for package: kmod-iscsitarget-2.6.23.8-63.fc8 --> Running transaction check ---> Package kmod-iscsitarget-2.6.23.8-63.fc8.i686 1:0.4.15-5.svn142.lvn8 set to be updated --> Processing Dependency: kernel-i686 = 2.6.23.8-63.fc8 for package: kmod-iscsitarget-2.6.23.8-63.fc8 ---> Package iscsitarget.i386 1:0.4.15-8.svn142.lvn8 set to be updated --> Finished Dependency Resolution Error: Missing Dependency: kernel-i686 = 2.6.23.8-63.fc8 is needed by package kmod-iscsitarget-2.6.23.8-63.fc8 [root@dl360g2c ~]# * Huh? Didn't work :( Problem is that that this is dependent upon ''kernel-2.6.23.8-63'' and we are running ''kernel-2.6.23.9-85'' * We are going to download this .rpm by hand and force the installation. [root@dl360g2c ~]# wget http://livna-dl.reloumirrors.net/fedora/8/i386/kmod-iscsitarget-2.6.23.8-63.fc8-0.4.15-5.svn142.lvn8.i686.rpm --11:18:27-- http://livna-dl.reloumirrors.net/fedora/8/i386/kmod-iscsitarget-2.6.23.8-63.fc8-0.4.15-5.svn142.lvn8.i686.rpm => `kmod-iscsitarget-2.6.23.8-63.fc8-0.4.15-5.svn142.lvn8.i686.rpm' Resolving livna-dl.reloumirrors.net... 193.28.235.37 Connecting to livna-dl.reloumirrors.net|193.28.235.37|:80... connected. HTTP request sent, awaiting response... 200 OK Length: 36,313 (35K) [application/x-rpm] 100%[====================================>] 36,313 116.24K/s 11:18:27 (115.99 KB/s) - `kmod-iscsitarget-2.6.23.8-63.fc8-0.4.15-5.svn142.lvn8.i686.rpm' saved [36313/36313] [root@dl360g2c ~]# ls *.rpm kmod-iscsitarget-2.6.23.8-63.fc8-0.4.15-5.svn142.lvn8.i686.rpm ** Hmmm ... failed miserably ** ** I fear that this isn't going to work and that perhaps we'll have to compile the sources ** to be continued ...