Hej James,

On 09:13 Mon 15 Feb     , James Vincent wrote:
> Does anyone know of a way to get info/status on luns on FCPs that are _not_
> active (failed state)?
>
> This is the scenario:
> zLinux machine with one active lun (non-NPIV)
> A new lun 0x000e000000000000 was added to /etc/zfcp.conf (yes, triple
> checked content for accuracy)
> Ran zfcpconf.sh - no errors, no kernel messages, NO DEVICE added in
> /dev/mapper

As Note: It will probably not make your case better, but for future
         reference, please use the method described in the RHEL manual
         [1]. In other words: use the uevent trigger (this will safe you
         trouble in case Redhat ever extends those udev-rules and
         only calling zfcpconf.sh is not enough anymore). Still, the
         zfcpconf.sh script is not programmed to do any error-reporting.
         Depending on the error, it should be visible in the syslog
         though.

> Ran multipath -ll - nothing to report; new lun had no info there
> Ran lsluns - can see the old and new lun in the list (there is a -a flag in
> lsluns which shows the active luns, but nothing to show 'failed' luns)
>
> Finally traversed down one of the FCPs
> to /sys/bus/ccw/drivers/zfcp/0.0.0100/0x50000973001c8d9c/ and noted both
> luns are there; looked in the 0x000e000000000000 directory and failed is 1
> and status is 0x60800000  So the lun didn't get added as a device, but
> nothing told us that - no errors/msgs at all.
>
> I was hoping there was something more better to run to tell me that though.
>  ie, lsluns -f (for failed) or lsluns -s (to show the full status of the
> luns)

Strictly spoken, this is not the intended Usecase for lsluns. Rather,
lsluns is for discovering LUNs that are accessible for your machine, not
what is already attached.

>
> Does anyone have an idea of how to show lun status info like this easier?
>

`lszfcp -D' will show all SCSI devices that zfcp currently knows of (in
much the same way as you discovered it). It doesn't show whether the
device is online and operational though. For that you can either call it
with the -a switch `lszfcp -Da --lun=0x5022000000000000', this will show
you the attributes of the device (you want to look at 'zfcp_failed' and
'state'). Or you can use the output of lszfcp as input for the `lsscsi'
tool (a standard linux-tool), for example `lsscsi -dL 3:0:1:25', which
also prints the state-information (the same as in lszfcp).

Thats the best ways I can remember just now.



[1] - https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/
      7/html/Installation_Guide/sect-post-installation-fcp-attached-luns-s390
      .html#sect-post-installation-fcp-attached-luns-persistent-s390


                                                    Beste Grüße / Best regards,
                                                      - Benjamin Block
--
Linux on z Systems Development         /         IBM Systems & Technology Group
                  IBM Deutschland Research & Development GmbH
Vorsitz. AufsR.: Martina Koederitz     /        Geschäftsführung: Dirk Wittkopp
Sitz der Gesellschaft: Böblingen / Registergericht: AmtsG Stuttgart, HRB 243294

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390
----------------------------------------------------------------------
For more information on Linux on System z, visit
http://wiki.linuxvm.org/

Reply via email to