FC HBA Driver for Linux Kernel 2.4.x

  

FC H BA D r ive r for Lin u x Ke r n e l 2 .4 .x

This soft ware license applies only t o QLogic cust om ers.

  QLogic Corporat ion.

  All right s reserved.

  

Ta ble of Con t e n t s

1. 2. 3.

  4.

  4.1

  4.2

  4.3

  4.4

   5.

  5.1

  5.2

  5.3

   6.

  6.1

  6.2

  6.3

  6.4

  6.5

  6.6

  6.7

  6.8

   7.

  1 . Pa ck a ge Con t e n t s The follow ing t able describes t he cont ent s provided in t he FC HBA Driver for Linux package. Filename Description drvrinstall Linux installation script. libinstall Script file to install/setup HBA API library. libremove Linux script to remove libqlsdm.so from

  /usr/lib

  or/and

  # # /usr/lib64 .

  qla2x00src-v x.yy.zz.tgz Compressed package that contains the driver and all support documents.

  NOTE: x.yy.zz represents the driver package version number. qlapi-v x.yybuildbb-rel.tgz Compressed package that contains the HBA API software and all support documents.

  NOTE: x.yy represents the version and bb represents the build number. readme.qla2x00 Text version of this package readme file.

  2 . OS Su ppor t The FC HBA Driver for Linux is com pat ible wit h t he follow ing OS plat form s. Operating Systems OS N a m e OS Type H a r dw a r e Pla t for m Red Hat RHEL AS 3.0 32-bit/64-bit Intel x86, Intel EM64T, AMD64, Intel IA64, and PPC64 platforms Novell SLES 8 32-bit/64-bit Intel x86, Intel AMD64,Intel IA64, and PPC64 platforms

  

N OTE: For specific OS service packs ( SP) and updat es, refer t o t he descript ions w here t his soft w are version is

post ed on t he QLogic websit e ( .

  3 . Su ppor t e d Fe a t u r e s

  The FC HBA Driver for Linux support s t he follow ing: FCAL - direct at t ach loop Point - t o- point Fabric support I nit iat or m ode only Fault recovery on down loops Persist ent binding Ext ended LUN support up t o 255 LUNs FC t ape support Non- Failover and Failover capabilit y

  4 . Usin g t h e D r ive r

  This sect ion provides procedures for saving t he driver t o a disket t e, inst alling t he driver, and using t he SNI A API library package.

  To save t he driver dist ribut ion t o a disket t e:

  1. Dow nload t he driver dist ribut ion file: qla2x00-vx.yy.zz-dist.tgz or t he driver source file qla2x00src-vx.yy.zz.tgz from QLogic's websit e

  2. I f prom pt ed " What would you like to do with this file?" choose Sa ve t his file t o disk .

  3. I nsert a blank disket t e and download t o t he disket t e direct ly.

  4 .2 I n st a llin g t h e D r ive r

  The source t gz package provides t he cont ent needed t o build qla2200.o or qla2300.o for eit her UP or SMP syst em s: Build a single processor ( UP) driver version ( see .

  Build a Sym et ric Mult iprocess ( SMP) driver version ( see . Aft er building t he driver version, do one of t he follow ing: Manually load t he driver using insmod or modprobe ( see .

  Creat e a ram disk im age t o aut om at ically load t he driver ( see ) .

  4 .2 .1 Bu ildin g a Sin gle Pr oce ssor ( UP) D r ive r V e r sion

  For Re d H a t RH EL D ist r ibu t ion s, ent er t he com m ands shown in t he following st eps:

  1. Using t he disket t e creat ed in copy t he dist ribut ion file ( qla2x00-vx.yy.zz-dist.tgz) or t he driver source file ( qla2x00src-vx.yy.zz.tgz) t o /qla2x00. Ent er t he following com m ands from t he

  " /" ( root ) direct ory: # mkdir qla2x00 # cd qla2x00 # mount /mnt/floppy # cp /mnt/floppy/*.tgz . ( t he period at t he end is required) # tar -xvzf *.tgz ( Execut e t he following addit ional st eps if you have copied t he dist ribut ion file qla2x00-vx.yy.zz-dist.tgz) # cd qlogic # ./drvrinstall ( t his ext ract s t he driver source files t o t he current direct ory)

  2. Build t he Driver qla2200.o and qla2300.o from t he source code: # make all

  For N ove ll SLES D ist r ibu t ion s, ent er t he com m ands shown in t he following st eps:

  1. I nst all t he kernel- source from t he SLES dist ribut ion CD- ROM: # yast -i kernel-source or # yast2 -i kernel-source

  2. Creat e a soft link ( /usr/src/linux) t o t he kernel source ( /usr/src/<linux-version>) : # ln -sf /usr/src/<linux-version> /usr/src/linux

  3. To ensure kernel version synchronizat ion bet w een t he driver and running kernel ( for kernel version below 2.4.21) : # cd /usr/src/linux # make mrproper ( com plet ely clean t he kernel t ree) # cp /boot/vmlinuz.config .config ( copy t he new config) # make oldconfig ( updat e configurat ion using .config) # make dep ( rebuild t he dependencies) # make modules ( build t he m odules)

  

N OTE: The st eps above do not apply t o SLES kernel 2.4.21 and above since it is dist ribut ed w it h pre-

build kernel- headers.

  4. Using t he disket t e you creat ed in t o t he root ( / ) direct ory and copy t he dist ribut ion file ( qla2x00-vx.yy.zz-dist.tgz) or t he driver source file ( qla2x00src-vx.yy.zz.tgz) t o /qla2x00: # mkdir qla2x00 # cd qla2x00 # mount /mnt/floppy # cp /mnt/floppy/*.tgz . ( t he period at t he end is required) # tar -xvzf *.tgz ( Run t he following addit ional com m ands if you copied t he qla2x00-vx.yy.zz-dist.tgzdist ribut ion file) # cd qlogic # ./drvrinstall ( t his ext ract s t he driver source files t o t he current direct ory)

  5. Build t he Driver qla2200.o and qla2300.o from t he source code: For Kernel Version below 2.4.21: # make all OSVER=linux For Kernel Version 2.4.21 and above: # make all OSVER=linux-include/<configuration-name> For exam ple, for kernel version

  2.4.21-107-itanium2, itanium2 is t he configuration-name and /usr/ src/linux-include is a soft link t o /usr/src/linux-2.4.21-107-include.

  N OTE: To load t he driver m anually, see .

  4 .2 .2 Bu ildin g a Sym m e t r ic M u lt ipr oce ssor ( SM P) D r ive r V e r sion

  For Re d H a t D ist r ibu t ion , ent er t he com m ands shown in t he following st eps:

  1. Using t he disket t e you creat ed in go t o t he root ( /) direct ory and copy t he dist ribut ion file ( qla2x00-vx.yy.zz-dist.tgz) or t he driver source file ( qla2x00src-vx.yy.zz.tgz) t o /qla2x00: # mkdir qla2x00 # cd qla2x00 # mount /mnt/floppy # cp /mnt/floppy/*.tgz .

  # tar -xvzf *.tgz ( Run t he following addit ional com m ands if you copied t he qla2x00-vx.yy.zz-dist.tgz dist ribut ion file.) # cd qlogic # ./drvrinstall ( t his ext ract s t he driver source files t o t he current direct ory)

  2. Build t he driver qla2200.o or qla2300.o from t he source code: # make all SMP=1

  For N ove ll SLES D ist r ibu t ion s, ent er t he com m ands shown in t he following st eps:

  1. I nst all t he kernel- source from t he SLES dist ribut ion CD- ROM: # yast -i kernel-source or # yast2 -i kernel-source

  2. Creat e a soft link ( /usr/src/linux) t o t he kernel source ( /usr/src/<linux-version>) :

  # ln -sf /usr/src/<linux-version> /usr/src/linux

  3. To ensure kernel version synchronizat ion bet w een t he driver and running t he kernel ( for kernel version below 2.4.21) : # cd /usr/src/linux # make mrproper ( com plet ely clean t he kernel t ree) # cp /boot/vmlinuz.config .config ( copy t he new .config) # make oldconfig ( updat e configurat ion using .config) # make dep ( rebuild t he dependencies) # make modules ( build t he m odules)

  N OTE: The st eps above do not apply t o SLES kernel 2.4.21 and above since it is dist ribut ed w it h pre -build kernel-headers.

  4. Using t he disket t e you creat ed in go t o t he root ( /) direct ory and copy t he dist ribut ion file ( qla2x00-vx.yy.zz-dist.tgz) or t he driver source file ( qla2x00src-vx.yy.zz.tgz) t o /qla2x00: # mkdir qla2x00 # cd qla2x00 # mount /mnt/floppy # cp /mnt/floppy/*.tgz .

  # tar -xvzf *.tgz ( Run t he following addit ional com m ands if you copied t he qla2x00-vx.yy.zz-dist.tgz dist ribut ion file.) # cd qlogic # ./drvrinstall ( t his ext ract s t he driver source files t o t he current direct ory)

  5. Build t he driver qla2200.o or qla2300.o from t he source code: For Kernel Version below 2.4.21: # make all SMP=1 OSVER=linux For Kernel Version 2.4.21 and above: # make all SMP=1 OSVER=linux-include/<configuration-name> For exam ple, for kernel version 2.4.21-107-itanium2, itanium2 is t he configuration-name and /usr/ src/linux-include is a soft link t o /usr/src/linux-2.4.21-107-include.

  N OTE: To load t he driver m anually, see .

  4 .2 .3 Loa d t h e D r ive r M a n u a lly u sin g in sm od or m odpr obe

  The driver m odule qla2300.o support s bot h 2Gb and 4Gb FC HBAs. For exam ple, if a QLA234x HBA and a QLA246x HBA are inst alled in t he sam e server, run t he follow ing com m and t o init ialize bot h HBAs: # modprobe -v qla2300 Before loading t he driver m anually, build t he driver binary from t he driver source TGZ as described in sect ions

  

  To load t he driver direct ly from t he local build direct ory: # insmod qla2200.o or # insmod qla2300.o To load t he driver using m odprobe:

  1. Build t he driver qla2200.o or qla2300.o from t he source code: For Re d H a t D ist r ibu t ion : # make all install ( build and copy driver t o t he right locat ion) For SLES D ist r ibu t ion : # make all OSVER=linux install ( build and copy driver t o t he right locat ion)

  2. Load t he driver: # modprobe -v qla2200 or # modprobe -v qla2300

  4 .2 .4 Cr e a t e a r a m disk I m a ge t o Loa d t h e D r ive r

  To creat e a ram disk im age:

  1. Build t he driver binary files ( see

  .

  2. I nst all t he driver: For Re d H a t D ist r ibu t ion : # make all install For SLES D ist r ibu t ion : # make all OSVER=linux install

  3. Add t he following line t o /etc/modules.conf: For Re d H a t D ist r ibu t ion : alias scsi_hostadapter0 qla2200_conf alias scsi_hostadapter1 qla2200 or alias scsi_hostadapter0 qla2300_conf alias scsi_hostadapter1 qla2300

  N OTE: Add one ent ry for each HBA in t he syst em . For exam ple, if bot h QLA2200 and QLA2300 HBAs are

  inst alled add t he following: alias scsi_hostadapter0 qla2200_conf alias scsi_hostadapter1 qla2200 alias scsi_hostadapter2 qla2300_conf alias scsi_hostadapter3 qla2300 For SLES D ist r ibu t ion , m odify t he /etc/sysconfig/kernel file t o specify which m odules are added during ram disk creat ion.

  N OTE: Make sure t he configurat ion m odule is list ed before t he act ual driver m odule. For exam ple:

  INITRD_MODULES="aic7xxx qla2300_conf qla2300 qla2200_conf qla2200" 4. Ent er t he appropriat e com m and. For Re d H a t D ist r ibu t ion : # mkinitrd -f <ramdisk image file name> <kernel version> N OTE: This com m and overwrit es t he original ram disk im age file if execut ed w it hin t he /boot direct ory. Specify a unique ram disk im age nam e t o preserve t he original ram disk im age.

  On I A- 3 2 , copy t he newly built <ramdisk image file name> file t o /boot. On I A- 6 4 , copy t he newly built <ramdisk image file name> file t o /boot/efi/efi/RedHat. For SLES D ist r ibu t ion : # /sbin/mk_initrd By default , t he syst em creat es t he ram disk im ages as: /boot/initrd /boot/initrd.SLES

  N OTE: This com m and overwrit es t he original ram disk im age file. To preserve t he original ram disk im age

  specify a unique ram disk im age nam e: # /sbin/mk_initrd -k <kernel name> -i <ramdisk image file name>

  5. Configure t he boot loader wit h t he new ram disk im age for GRUB: For Re d H a t D ist r ibu t ion :

  a. Add " initrd /<ramdisk file name>" in /etc/grub.conf file under one of t he kernel ent ries t o use t he ram disk im age. For exam ple: kernel /vmlinuz-2.4.18-14 ro root=LABEL=/ initrd /initrd-2.4.18-14.img b. Reboot t he syst em .

  For SLES D ist r ibu t ion :

  a. Add " initrd (hd0,1)/boot/<ramdisk file name>" in /boot/grub/menu.lst file under one of t he kernel ent ries t o use t he ram disk im age. For exam ple: kernel (hd0,1)/boot/vmlinuz root=/dev/hda2 max_scsi_luns=128 initrd (hd0,1)/boot/initrd b. Reboot t he syst em . The SNI A API library package ( qlapi-<api_version>-rel.tgz) is included in t he driver com bo package ( qla2x00-vx.yy.zz-dist.tgz) or ( qla2x00-vx.yy.zz-fo-dist.tgz) . Using t he disket t e you creat ed in , go t o t he root (

  /) direct ory and copy t he dist ribut ion file ( qla2x00-vx.yy.zz-dist.tgz) t o /qla2x00: # mkdir qla2x00 # cd qla2x00 # mount /mnt/floppy # cp /mnt/floppy/*.tgz . ( t he period at t he end is required) # tar -xvzf *.tgz # cd qlogic

  To inst all t he SNI A API Library, ent er t he follow ing com m and in t he current direct ory t o inst all/ set up API library: # ./libinstall ( t his inst alls/ set s up HBA API library) To uninst all t he SNI A API Library, ent er t he following com m and in t he current direct ory t o rem ove API library: # ./libremove ( script file t o rem ove HBA API library)

  4 .4 En a blin g I P Su ppor t

  This sect ion describes how t o load t he I P driver and configure t he net w ork int erface t o allow TCP/ I P applicat ions t o com m unicat e wit h I P- enabled FC HBAs. For det ails, see:

  

  4 .4 .1 Loa din g t h e I P D r ive r

  Before loading t he driver m anually, build t he driver binary from t he driver source files as described in

   . Ent er t he insmod or modprobe com m ands t o load t he I P driver:

  To load t he driver direct ly from t he local build direct ory: # insmod qla2300.o # insmod qla2xip.o To load t he driver using modprobe:

  a. I nst all t he driver m odule ( *.o) files t o t he appropriat e kernel m odule direct ory: # make install

  b. Load t he driver for qla23xx HBAs: # modprobe -v qla2300 # modprobe -v qla2xip

  To unload t he driver using modprobe: # modprobe -r qla2xip # modprobe -r qla2300 The qla2xip driver creat es a net work- int erface binding t o each I P- capable recognized HBA. Aft er loading t he I P driver, you can view t he binding ent ries in t he m essages file. For exam ple: qla2xip: QLogic IP via Fibre Channel Network Driver qla2xip: Driver Version 1.0b2, Entry point: e08e5060 qla2xip: Mapping interface fc0 to adapter 210100e08b20a15b qla2xip: Mapping interface fc1 to adapter 210200e08b40a25b To allow TCP/ I P applicat ions running on t he host t o com m unicat e w it h ot her I P- capable FC HBAs, you m ust configure t he net work int erfaces:

  1. Com pile t he following basic host inform at ion t o allow t he I P driver t o pass TCP/ I P dat a over FC HBAs in your host :

  Interface name: fc0 (From above)

  • * IP Address: 192.168.1. x (A non-routable address)

  Netmask: 255.255.255.0 (Standard class C mask) Interface name: fc1 (From above)

  IP Address: 192.168.2. * x (A non-routable address) Netmask: 255.255.255.0 (Standard class C mask)

  • *x in the IP address is a unique number between (1 and 254)

  2. Use t he ifconfig program t o configure an int erface wit h t he com piled host inform at ion: # ifconfig fc0 192.168.1.x up

  3. Configure ot her int erfaces ( if m ult iple I P- capable HBAs are present in t he host ) : # ifconfig fc1 192.168.1.x up

  4. Verify t he configured int erfaces: # ifconfig The screen displays det ails on t he newly configured int erfaces, as show n in t he follow ing exam ple: fc0 Link encap:Ethernet HWaddr 00:E0:8B:20:A1:5B inet addr:192.168.1.1 Bcast:192.168.1.255 Mask:255.255.255.0 UP BROADCAST RUNNING MTU:4096 Metric:1 RX packets:1214577458 errors:0 dropped:0 overruns:0 frame:0 TX packets:1214213174 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:32 RX bytes:3081095492 (2938.3 Mb) TX bytes:2751945609 (2624.4 Mb) fc1 Link encap:Ethernet HWaddr 00:E0:8B:40:A2:5B inet addr:192.168.2.1 Bcast:192.168.2.255 Mask:255.255.255.0 UP BROADCAST RUNNING MTU:4096 Metric:1 RX packets:1204464697 errors:0 dropped:0 overruns:0 frame:0 TX packets:1194873236 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:32 RX bytes:1454694706 (1387.3 Mb) TX bytes:991094469 (945.1 Mb) This com plet es configurat ion.

  5. Verify t hat basic net working is possible bet w een t w o host s connect ed via t w o HBAs using a sim ple ping com m and: # ping 192.168.1.2 For m ore det ails on Linux net working, refer t o t he Linux Net w orking " HOWTOs" available at

   .

  5 . D r ive r Pa r a m e t e r s

  This sect ion describes t he following driver param et ers:

  

  

   You can configure support for m ult iple LUNs in one of t hree w ays. Current ly, t he syst em can scan up t o 255 LUNs t hat for each device ( 2.4.9- 21 or above) .

  N OTE: I f you have m ult iple HBAs, set max_scsi_luns t o t he largest num ber of LUNs support ed by any one of t hese HBAs. I f t h e SCSI M id- La ye r is com pile d in t h e k e r n e l, you ca n con figu r e t h e boot loa de r t o sca n for m u lt iple LUN s e a ch t im e t h e syst e m boot s.

  On I A- 32, for GRUB, follow t he st eps for your OS plat form .

  For Re d H a t D ist r ibu t ion : 1. Append t he max_scsi_luns param et ers t o each of t he kernel im ages list ed in t he /etc/grub.conf file.

  For exam ple: kernel /vmlinux-2.4.7-10 ro root=/dev/hda2 max_scsi_luns=255

  2. Reboot t he syst em . For SLES D ist r ibu t ion :

  1. Append t he max_scsi_luns param et ers t o each of t he kernel im ages list ed in t he /boot/grub/menu.lst file. For exam ple: kernel (hd0,1)/boot/vmlinuz root=/dev/hda2 max_scsi_luns=25 2. Reboot t he syst em .

  On I A- 64, follow t he st eps for your OS plat form .

  For Re d H a t D ist r ibu t ion : 1. Add t he following line t o each of t he kernel im ages list ed in t he /boot/efi/efi/Red Hat/elilo.conf.

  For exam ple: append="max_scsi_luns=128"

  2. Reboot t he syst em . For SLES D ist r ibu t ion :

  1. Add t he following line t o each of t he kernel im ages list ed in t he /boot/efi/SLES/elilo.conf. For exam ple: append="max_scsi_luns=128" 2. Reboot t he syst em .

  I f t h e SCSI M id- La ye r is com pile d a s a m odu le :

  1. Add t he following line t o t he /etc/modules.conf file t o scan for m ult iple LUNs at each boot : options scsi_mod max_scsi_luns=255

  2. Rebuild t he ram disk im age, as described in .

  5 .2 N V RAM Pa r a m e t e r s

  The driver reads t he NVRAM param et ers during init ializat ion. Any changes m ade for t he part icular NVRAM feat ure in t he Fast ! Ut il t ake effect aft er reloading t he driver or changing t he param et ers using t he ut ilit ies in SANsurfer FC HBA Manager or SANsurfer FC CLI .

  5 .3 D r ive r Com m a n d Lin e Pa r a m e t e r s The driver get s it s param et ers from t he com m and line or from modprobe opt ion direct ive found in t he modules.

  conf file. The param et ers use t he following form at :

  <keyword>

  =value form at ( for exam ple, ql2xfailover=1) w here <keyword> is one of t he opt ion param et ers described in t he follow ing paragraphs. Usage: modprobe -v qla2300 <keyword>=value Exam ples: # modprobe -v qla2300.o ql2xfailover=1 # modprobe -v qla2300.o qlport_down_retry=60

  Command Line Parameter Descriptions

  Parameter Description Default ql2xfailover This parameter defines whether failover mode is enabled or disabled. 0 to disable; 1 to enable. ql2xmaxqdepth This parameter defines the maximum queue depth

  32 reported to SCSI Mid-Level per device. The Queue depth specifies the number of outstanding requests per LUN. ql2xmaxsgs This parameter defines the maximum number of

  32 scatter gather entries reported to SCSI Mid-Level per request for the HBA. ql2xmaxsectors This parameter defines the maximum number of 512 sectors reported to SCSI Mid-Level per request for the HBA. ql2xlogintimeout This parameter defines the Login timeout value in 20 seconds seconds during the initial login. qlport_down_retry This parameter defines how long to wait for a port 0 (use value specified in NVRAM) that returns a PORT-DOWN status before returning I/

  O back to the OS. ql2xretrycount This parameter defines the maximum number of 20 (standard mode value) 30 (failover mode value) SCSI Mid-Level retries allowed per command. max_srbs This parameter defines the maximum number of 4096 simultaneous commands accepted from the SCSI

  Mid-Level per HBA. displayConfig This parameter defines whether to display the current

  1 configuration. 1 - display the configuration 0 - don't display the configuration.

  Binding method This parameter defines what target persistent binding 0 (portname binding) method to use: 0 - bind by Portname 1 - bind by PortID. extended_error_logging This parameter defines whether to enable (1) or 0 (disable) Disable (0) writing the debug information to /var/log/ messages. MaxPathsPerDevice This parameter defines maximum number of paths to 8 (compile time only) a device.

  MaxRetriesPerPath This parameter defines how many retries to perform

  3 on the current path before failing over to the next path in the path list. MaxRetriesPerIo This parameter defines total retries to do before (MaxRetriesPerPath * MaxPathsPerDevice ) + 1 failing the command and returning to the OS with selection timeout (DID_NO_CONNECT). QlFailoverNotifyType This parameter defines type of failover notification 0 (none) mechanism to use when a failover or failback occurs.

  Certain storage systems require special CDBs issued to do failover or failback. ConfigRequired This parameter defines how to bind the devices.

  0 - Present all the devices discovered to the OS. 1 - Present only the configured devices (i.e. the device defined in /etc/qla2300_conf) to the OS.

  FailbackTime This parameter defines the delay in seconds before 5 seconds performing a failback to ensure all paths are available. RecoveryTime This parameter defines the recovery time in seconds 10 seconds required before sending commands to the restored path. ql2xprocessnotready This parameter defines how the driver should handle

  1 a "NOT READY" indicator. 1 - Handled by the driver 0 - Disable the handling within the driver ql2xautorestore This parameter enables or disables the logic that restores the previous failed preferred path and/or controller for a given LUN. This option toggles the default state. Combine one or more of the following model numbers into an inclusion mask: 0x80 - MSA A/A (auto-restore disabled) 0x20 - HSV111, HSV101, HSV200, HSV210 (auto- restore disabled) 0x10 - DSXXX (auto-restore disabled) 0x04 - HSV110, HSV100 (auto-restore disabled) 0x02 - MSA1000 (auto-restore disabled) 0x01 - XP (auto-restore enabled) ql2xlbType This parameter defines the load Balance Method for the driver to use either static or dynamic:

  0 (None) - Expose LUNs on the first active path and make them the preferred path or the first active optimize path and make them the preferred path (storages: MSA A/A and EVA A/A). 1 (Static load balancing) - Distribute and expose the LUNs across the active optimize ports or active un- optimize ports and HBAs. 2 (Least outstanding I/O) - Send command to the path with the lowest I/O count. 3 (Least Service time) - Send request to the path with the shortest execution time. ql2xexcludemodel This parameter excludes device models from being a failover capable target. Combine one or more of the following model numbers into an exclusion mask: 0x80 - MSA A/A 0x20 - HSV111, HSV101, HSV200, HSV210 0x10 - DSXXX, 0x04 - HSV110, HSV100 0x02 - MSA1000, 0x01 - XP ql2xtgtemul Enable/Disable target level grouping emulation. This 1 (Enable) option is necessary for the GUI to work correctly if the driver is set for LUN level grouping of paths by lunid. The following storages uses this method of combining paths: HSV210, DSXXX, HSV110,

  1 - Enable target level grouping emulation 0 - Disable target level grouping emulation To view all available param et ers, ent er one of t he follow ing com m ands: # modinfo -p qla2300 # modinfo -p qla2200

  6 . Addit ion a l N ot e s

  This sect ion provides t he following addit ional inform at ion:

  

  

  

  

  

  

  

   6 .1 Pr oc File syst e m Su ppor t

  The /proc filesyst em for t he QLA2200, QLA23xx, and QLA246x driver are locat ed in t he /proc/scsi/ qla2200/ and /proc/scsi/qla2300/ direct ories. These direct ories cont ain a file for each FC HBA in t he syst em . Each file present s inform at ion about t he HBA and t ransfers st at ist ics for each discovered LUN.

  6 .2 Fa ilove r Su ppor t

  This sect ion describes how t o provide failover support . For det ails, see t he follow ing t opics:

  

  

   6 .2 .1 H ow t o En a ble t h e Fa ilove r Su ppor t I n Th e D r ive r To im plem ent failover support in t he QLA2xxx driver, enable t he m acro MPIO_SUPPORT in qla_settings.h file.

  For exam ple: # define MPIO_SUPPORT 1 As an alt ernat ive, specify t he opt ion on t he com m and line: # modprobe -v qla2300 ql2xfailover=1 N OTE: The failover dist ribut ion package ( qla2x00-vx.yy.zz-fo-dist.tgz) as t his m acro enabled by default .

  6 .2 .2 Usin g SAN su r fe r FC H BA M a n a ge r w it h QLA2 x x x Driver for t he First Tim e

  To w ork w it h SANsurfer: 1. Build t he driver wit h MPIO_SUPPORT set t o 1 in qla_settings.h.

  2. Add t he following param et er in modules.conf file: options qla2200 ql2xfailover=1 or options qla2300 ql2xfailover=1

  3. Add as a com m and line param et er: # modprobe -v qla2300 ql2xfailover=1 The Linux SCSI m id- layer requires com m unicat ing w it h t he t arget via LUN 0; t herefore, t he driver cannot m ask LUN 0 w hen defined t hrough t he applicat ion. For t he new LUN m asking configurat ion t o t ake effect , you m ust reload t he driver. To m odify t he configurat ion using t he SANsurfer FC HBA Manager:

  1. Load t he driver: modprobe <driver>

  2. Load t he qlremote agent .

  3. St art t he GUI and connect it t o t he dest inat ion syst em .

  4. Make LUN m asking changes.

  5. Disconnect t he host from GUI and st op qlrem ot e agent .

  6. Unload t he driver: modprobe -r <driver>

  7. Reload t he driver: modprobe <driver>

  9. St art t he GUI and connect it t o t he dest inat ion syst em . You should now see t he updat ed LUN m asking configurat ion.

  N OTE: When using modprobe t o load t he driver, t he lengt h of t he opt ion line specified in /etc/modules.conf file has a lim it of 2K charact ers. Any longer opt ion line causes a st ring overflow error from modprobe.

  6 .3 Pe r sist e n t Bin din g

  The persist ent binding inform at ion consist s of som e HBA configurat ion ent ries along w it h som e t arget ent ries, w hich are specified in t wo form at s: verbose and short en. The short en form at allow s a bigger configurat ion t o fix in t he lim it ed space on t he com m and line. As an alt ernat e t o using t he com m and line, you can use t he configurat ion file.

  You can specify persist ent binding in t wo ways: m anually or using SANsurfer FC HBA Manager or SANsurfer FC HBA CLI . We recom m end using SANsurfer t ools for ease of use. The follow ing procedure shows how t o m anually add persist ent binding com m ands. The driver displays t he current configurat ion w hen t he displayConfig com m and line opt ion is specified. The persist ent binding configurat ion is found in var/log/messages file. I t print s t he configurat ion inform at ion in t he form at required by t he driver. The best w ay t o ext ract configurat ion m essages is t o use grep and direct t he out put t o a file. You need t o rem ove t he Linux t im est am p at t he beginning each m essage and com bine t hem t oget her on single line. For exam ple: # modprobe -v qla2300 displayConfig=1 # grep "scsi-qla" /var/log/messages > /tmp/info.cfg The form at of t he persist ent binding com m ands is as follow s: scsi-qla<#>-adapter-port=<HBA port name value>; or

  <#>

  • w=<HBA port name value>; * * short en form at * * The designat ed by qla<#>, where t he <#> is t he HBA inst ance num ber. The param et er specifies t he FC port nam e t o be used for t he HBA w here <HBA port name value> is t he FC port nam e value in hexadecim al form at . I f t his ent ry is not specified in t he configurat ion file, t he default value is t he HBA's port nam e as saved in t he NVRAM. For exam ple: scsi-qla00-adapter-port=210000e08b01158d\; w here host HBA inst ance 0 has a port nam e of 210000e08b01158d scsi-qla<#1>-tgt-<#2>-di-<#3>-node=<device FC name>; or

  <#1>-<#2>-<#3>

  • n=<device FC name>; * * short en form at * *
This param et er associat es t he specified <device FC name> w it h t he SCSI t arget I D value specified by <#2> and a device id value specified by <#3> where <device FC name> t ype is t he FC node nam e of t he device,

  <#2> is t he SCSI t arget I D t o be assigned t o t he device, and <#3> is t he device unique id.

  where

  <#1>

  specifies t he HBA inst ance num ber

  <#2>

  specifies t he SCSI I D of t arget

  <#3>

  specifies t he pat h/ device id scsi-qla<#1>-tgt-<#2>-di-<#3>-port=<device FC name>; or

  <#1>-<#2>-<#3>

  • p=<device FC name>; * * short en form at * * This param et er associat es t he specified <device FC name> w it h t he SCSI t arget I D value specified by <#2> and a device id value specified by <#3> where <device FC name> t ype is t he FC port where

  <#1>

  specifies t he inst ance num ber

  <#2>

  specifies t he SCSI I D of Target

  <#3>

  specifies t he pat h/ device id ( always 0 for non- failover) nam e of t he device, <#2> is t he SCSI t arget I D t o be assigned t o t he device, and <#3> is t he device unique id. scsi-qla<#1>-tgt-<#2>-di-<#3>-disabled=<256 bit mask>; or

  <#1>-<#2>-<#3>

  • d= <256 bit mask>; * * short en form at * * This param et er associat es t he specified <256 bit mask> w it h t he SCSI t arget I D value specified by <#2> and a device id value specified by <#3>. w here

  <#1>

  specifies t he HBA inst ance num ber

  <#2>

  specifies t he SCSI I D of Target <#3> specifies t he pat h/ device id <256 bit mask> msb lsb 000000000000000000000000000000000000000000000000000000000000000F The m ask above m akes t he first four LUNs, 3, 2, 1, and 0 of a given Target disabled on t hat t arget / pat h.

  This m ask specificat ion is heavily t ype checked t o be a sequence of 64 hex digit s.

  6 .4 Con figu r a t ion D a t a

  Configurat ion/ persist ent dat a loads in t he driver aut om at ically w hen inst alling and loading t he driver. Norm ally t his inform at ion passes t o t he driver using t he com m and line, but due t o t he const raint s inherent in using t he com m and line, you m ay prefer using an alt ernat e m et hod: QLA_OPTS. For det ails, see t he follow ing t opics:

  

  

   6 .4 .1 QLA_ OPTS QLA_OPTS reads t he configurat ion dat a from qla2x00.conf and updat es t he binary m odule qla2x00_conf.o.

  The driver aut om at ically t ries t o load t he binary m odule qla2x00_conf.o at driver init ializat ion t im e. Once loaded, t he m odule passes t he configurat ion inform at ion direct ly t o t he driver. The configurat ion dat a and m odule are st ored in /etc/ wit h t he filenam e based on t he I SP board t ype:

  Configuration File Module Name /etc/qla2200.conf qla2200_conf.o /etc/qla2300.conf qla2300_conf.o

  N OTE: Approxim at ely 300K of configurat ion space has been pre- allocat ed w it hin t he

  qla2200_conf/ qla2300_conf m odule for configurat ion/ persist ent dat a. QLA_OPTS works seam lessly wit h updat ed SANsurfer FC HBA Manager applicat ions. Originally, when t he applicat ion saved a configurat ion, it saved t he corresponding dat a t o t he options sect ion of t he modules. conf file in a form sim ilar t o t he following: ql2xopts=scsi-qla0-HBA-port=210000e08b000000\;scsi-qla0-tgt-1-di- 0-node=20000020371682e7\;scsi-qla0-tgt-1-di-0-port=21000020371682e7\; scsi-qla0-tgt-1-di-0-pid=0000e2\;scsi-qla0-tgt-1-di-0-control=00\; The applicat ion now saves t he dat a t o t he appropriat e qla2[2|3]00.conf file in /etc and t hen brands it t o t he binary file of t he corresponding configurat ion m odule ( qla2200_conf.o or qla2300_conf.o) : /lib/modules/<CURRENT_KERNEL_VERSION>/kernel/drivers/scsi where CURRENT_KERNEL_VERSION is t he result of t he com m and uname -r.

  This operat ion occurs aut om at ically and requires no user int ervent ion. How ever, if you loaded t he driver from an initrd im age, as before wit h t he modules.conf int erface, you would need t o rebuild t he init rd im age aft er updat ing a configurat ion.

  6 .4 .3 Upda t in g t h e Con figu r a t ion M a n u a lly

  Manually updat ing t he /etc/qla2x00.conf file is st rongly discouraged. Because it can cause t he binary m odule and t he configurat ion file t o get out of sync. I f necessary, you can change t he persist ent / configurat ion m anually. To change a value m anually: 1. Change t he /etc/qla2x00.conf file.

  2. Run make install from t he driver's build direct ory t o updat e t he configurat ion m odule.

  6 .5 For cin g D e vice Re sca n

  Beginning w it h driver version v6.06.00b12, t he driver provides a w ay t o force t he driver t o re- scan t he devices t o allow you t o add a new device. This t riggers t he driver t o init iat e LUN discovery process. When scanning, first scan t he driver ( qla2300/ qla2200 driver et c) , t hen t he Linux scsi m id layer ( such as an OS scan) . For exam ple, ent er t he com m ands: # echo "scsi-qlascan" > /proc/scsi/<driver-name>/<HBA-id> ( qlogic driver re- scans) w here

  <driver-name>

  is qla2100, qla2200, or qla2300

  <HBA-id>

  is t he inst ance num ber of t he HBA Aft er doing t his, you can force t he SCSI m id layer t o perform it s ow n scan and build t he device t able ent ry for t he new device: # echo "scsi add-single-device 0 1 2 3" >/proc/scsi/scsi ( scsi m id layer re- scans) w here 0 1 2 3 is replaced by your Host Channel I D LUN.

  6 .6 Boot in g fr om SAN

  To boot from SAN, creat e a driver disk ( DD Kit ) im age, w hich enables you t o inst all t he Red Hat / SLES 8 OS and QLogic driver ( qla2300) on t he Fibre Channel boot disk connect ed t o t he HBA ( QLA23XX/ QLA63XX) . To build t he driver disk im age for RH 3 I A- 3 2 , follow t hese st eps:

  1. Dow nload 7.x_linux_driver_ddkit_for_Red Hat_SLES_dist.tgz from t he QLogic websit e:

  

  2. Unt ar t he t gz file: # tar -xvzf *.tgz

  3. Ent er: # dd if=qla2x00-vx.yy.zz-x86-dd-RHEL3-U5.img of=/dev/fd0 bs=1440k ( requires a 1.44MB floppy)

  6 .7 For cin g a LI P

  The follow ing NVRAM param et ers m ust be set in order t o perform t he LI P reset : Enable Lip Reset Enable Target Reset ( if t he at t ached t arget s should be also be reset ) I f bot h t he above param et ers are disabled, a Full Login LI P is execut ed. Execut e t he following com m and t o init iat e t he LI P reset process: # echo "scsi-qlalip " > /proc/scsi/qla2300/<host_no>

  6 .8 Ge t t in g Fir m w a r e D u m p

  The ext ras direct ory in t he driver source cont ains a ut ilit y used t o ret rieve t he firm w are dum p on a specific host . To know if firm ware dum p has happened in t he driver, search for " Firm w are dum p" in /var/log/ messages.

  For exam ple: # grep "Firmware dump" /var/log/messages localhost kernel: scsi(0): Firmware dump saved to temp buffer (0/e0306000). ^_ 0 is the host_no To ret rieve t his firm ware dum p, ent er t he follow ing com m and: # cd extras # ./qla_gdmp 0 Info: Firmware dumped to file fw_dump_0_20061128_152019.bin Info: Firmware dump on 0 -- dumped 324586 bytes...

  The ut ilit y saves t he dum p file in t he current direct ory w it h a .bin ext ension.

  N OTE: The dum p can be ret rieved only once.

  The dum p is in binary form at , t o convert t he binary form at int o t ext form at , ent er t he follow ing com m and: ./qla_dmp < <FW dump bin file name> For exam ple: # ./qla_dmp < fw_dump_0_20061128_152019.bin

  7 . Con t a ct in g Su ppor t

  Please feel free t o cont act your QLogic approved reseller or QLogic Technical Support at any phase of int egrat ion for assist ance. QLogic Technical Support can be reached by t he follow ing m et hods: Web: Nort h Am erica Cont act I nform at ion Em ail: Phone: ( 952) 932- 4040 Support cont act inform at ion for ot her regions of t he w orld is available at t he QLogic w ebsit e:

  

  © Copyright 2007. All right s reserved w orldw ide. QLogic, t he QLogic logo, and t he Powered by QLogic logo are regist ered t radem arks of QLogic Corporat ion. All ot her brand and product nam es are t radem arks or regist ered t radem arks of t heir respect ive ow ners.