Intro
-----
This is a heavily modified version to the original mpt-status-1.0 tool.
mpt-status is a query tool to access the running configuration of a (currently)
LSI 1030 RAID controller.


Where can I get this
--------------------
Homepage of modified version: http://www.drugphish.ch/~ratz/mpt-status/
Homepage of original version: http://www.red-bean.com/~mab/mpt-status.html

The original version will not work on 2.6.x kernels and is also not maintained
anymore. The author has never replied to any of my emails, though, so it's only
an assumption.


How can I compile, install or uninstall mpt-status
--------------------------------------------------
Read doc/INSTALL for further information on building mpt-status. Basically you
should be fine invoking

    make


What does it do (Matt Braithwaite)
----------------------------------
mpt-status:
Get status of LSI 1030 RAID (mptlinux, fusion, mpt, ioc) controller.
This is a little Linux C program I wrote to tell you the status of the physical
and logical drives attached to your LSI 1030 RAID controller. Here is some
sample output: 

  ioc0 vol 0 type IM, 2 phy, 68 GB, flags ENABLED, state OPTIMAL
  ioc0 phy 0 IBM-ESXS MAS3735NC     FN C901, 68 GB, state ONLINE
  ioc0 phy 1 IBM-ESXS ST373453LC    FN B85D, 68 GB, state ONLINE

I have compiled it against various 2.4 kernels running on x86_64. Comments and
patches relating to portability will be especially welcome. The program probably
also needs improvement in its handling of multiple controllers, or indeed of any
configuration other than a simple mirror, which is all I have access to.

Motivation:
I am aware of at least two Java-based programs that can provide the same
information. But they are old, and I had all kinds of trouble installing them
on x86_64 systems. And who wants to run a GUI to get information that should be
available from /proc? 


What does this package do additionally (Roberto Nibali)
-------------------------------------------------------
For now it should be improved regarding compilation on different systems, also
different kernels. But the output has changed as well. See for yourself:

SR2400:~# ./mpt-status -i 0
ioc0 vol_id 0 type IS, 0 phy, 0 GB, state OPTIMAL, flags NONE
SR2400:~# ./mpt-status -i 1
ioc0 vol_id 1 type IM, 2 phy, 68 GB, state OPTIMAL, flags ENABLED
ioc0 phy 0 scsi_id 1 SEAGATE  ST373207LC       0003, 68 GB, state
ONLINE, flags NONE
ioc0 phy 1 scsi_id 3 SEAGATE  ST373207LC       0003, 68 GB, state
ONLINE, flags NONE

You can now specify the scsi_id of the primary disk of an array. This is in
case you've got an array but your primary disk is not physically in the slot 0
in your chassis (scsi id 0) but in another one. The following excerpt from the
source code should clarify what I mean:

            This represents the id of the primary disk of an array. If you have
            following setup, the ID of the primary disk would be 1.

            +---+---+---+---+---+---+---+---+----
   SCSI ID  | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | ...
            +---+---+---+---+---+---+---+---+----
                   \   \   \___  Array: Secondary Disk
                    \   \______  Array: Spare Disk
                     \_________  Array: Primary Disk

            In the following setup without a Spare Disk, the ID of the primary
            disk would be 2.

            +---+---+---+---+---+---+---+---+----
   SCSI ID  | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | ...
            +---+---+---+---+---+---+---+---+----
                       \   \___  Array: Secondary Disk
                        \______  Array: Primary Disk



Random Notes
------------
The includes pci.h, config.h, header.h are from pciutils. Most distros might
have a pciutils-devel package or somthing similar. My package compiles on my
own distribution, on a SuSE 9.0, a SuSE 9.1 and on SuSE 9.2. This implies
kernel 2.4.x and 2.6.x. It also compiles and links against uclibc provided you
have the kernel includes in your buildroot. Static and dynamic linking is
possible.

NEW: It also compiles on all Redhat derivates to my avail. And preliminary
     support for ultra-sparc has been added. It's only so I don't forget how
     to compile the stuff for 64bit architectures. The key is the -m64 switch
     in gcc.

NEW (1.1.4):
     Also supported are various RedHat based distributions. I got word of
     success from a Gentoo user and various Debian Sarge users. Time for people
     to submit some specs and debs.


Directory structure
-------------------
./doc/AUTHORS	          : This file lists the authors of the mpt-status code
./doc/Changelog           : Keeps track of the changes in prosa 
./doc/COPYING	          : The GNU v2 License copy
./doc/INSTALL	          : The installation documents
./doc/README	          : This document
./doc/ReleaseNotes        : The actual release notes, read them carefully
./doc/TODO	          : Stuff that needs to be done
./doc/THANKS	          : A small thank you endroit for the contributors
./doc/DeveloperNotes      : Some information on the message API of mpt
./incl/config.h           : Include file from pciutils
./incl/header.h           : Include file from pciutils
./incl/pci.h	          : Include file from pciutils
./Makefile	          : Used to build the mpt-status binary
./mpt-status.c	          : The mighty tool itself
./mpt-status.h	          : The main include file for mpt-status
./contrib/mpt-status.spec

-- 
Roberto Nibali, ratz (ratz at drugphish dot ch)
