>       I have a Dell 2300 running RedHat 7.1 with the 2.4.3 
> kernel. We are
> using a qlogic QLA2200 FC card to connect to a Zzyzx 
> RocketStor Raid array.
> The Zzyzx array has two FC ports which appear as two targets 
> on the SAN and
> can assign raid sets to arbitrary Lun numbers on either port. 
> The problem we
> observed is that the Linux host could not see any of the raid 
> sets on a
> given port unless the raid sets were assigned to sequential 
> Luns starting at
> 0. Furthermore, if there was a gap in the Luns, the Linux 
> host could not see
> any of the raid sets past the gap. For example, if we deleted 
> the raid set
> assigned to Lun 3, all of the raid sets with a Lun higher than 3 would
> "disappear" from the Linux host. I modified the blacklist in 
> scsi_scan.c and
> added the following entry:
> 
> {"Zzyzx", "RocketStor 500S", "*", BLIST_SPARSELUN}

         * Check the peripheral qualifier field - this tells us whether LUNS
         * are supported here or not.
         */
        if ((scsi_result[0] >> 5) == 3) {
                return 0;       /* assume no peripheral if any sort of error
*/


Even if LUN 0 is masked off from you, the SCSI layer must still present a
device at LUN 0 (per SCSI spec).  On the Dell PowerVault storage arrays I've
used, the test here returns 001b (The target is capable of supporting the
specified peripheral device type on this logical unit, however the physical
device is not currently connected to this logical unit - the case where you
can't access LUN 0 except for inquiry) or 000b (you can access this LUN).
If your device is returning 011b, the spec says "the target is not capable
of supporting a physical device on this logical unit", and this test should
properly force a return.

         * Check the peripheral qualifier field - this tells us whether LUNS
         * are supported here or not.
         */
        if ((scsi_result[0] >> 5) == 3) {
                return 0;       /* assume no peripheral if any sort of error
*/


I've found that you must add two lines to the blacklist, one for the case
where you can see a disk at LUN 0, and one for the case where you can't.
e.g.

{"DGC",  "RAID",      "*", BLIST_SPARSELUN}, // Dell PV 650F (tgt @ LUN 0)
{"DGC",  "DISK",      "*", BLIST_SPARSELUN}, // Dell PV 650F (no tgt @ LUN
0)


This way, the device at LUN 0 is found to start the scan, and then later 
        /* Use the peripheral qualifier field to determine online/offline */
        if (((scsi_result[0] >> 5) & 7) == 1)   SDpnt->online = FALSE;

we simply mark the LUN offline if we can't access it for real.

This has worked on all Dell PowerVault SANs.  If the RocketStor 500S is
returning 011b rather than 001b there, then I believe that's a bug in their
SCSI implementation.  Can you add a check to see what's actually in the
peripheral qualifier field when there's no LUN available?

Thanks,
Matt

-- 
Matt Domsch
Sr. Software Engineer
Dell Linux Solutions
www.dell.com/linux

-
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to [EMAIL PROTECTED]

Reply via email to