Technical article 127084

Getting started with 'mpio' on SCO Unix

OpenServer 6.0.0UnixWare 7.1.4

Written · Last revised

Problem

How do I get started with SCO Unix's 'mpio', Multi Path I/O, feature?

HARDWARE: Any Storage Cabinet Solution that supports Multi Path I/O

Solution

'mpio' is available for SCO OpenServer6 and UnixWare7 only.

Let's consider the hardware.  It is assumed that the Single, Shared
or SAN Storage Cabinet you are connecting to, supports multi-path
attachments.

Please check with the Storage Cabinet vendor to ensure it supports Multi Path attachments.

In a typical and simple configuration, you are connecting two leads from a Dual Channel (or multi-channel) fibre controller into a storage cabinet with a single logical volume connected.

In this example, this disk is the DISK XYRATEX, is attached to a qlogic 2342 (dual channel controller):

# sdiconfig -l
0:0,2,0: HBA     : (ide,1) Generic IDE/ATAPI
  0,0,0: DISK    : ST3250410AS             3.AA
1:0,7,0: HBA     : (qlc2300,1) QLogic QLA2300
  0,0,0: DISK    : XYRATEX F5402E
  1,7,0: HBA     : (qlc2300,1) QLogic QLA2300
  2,7,0: HBA     : (qlc2300,1) QLogic QLA2300
  3,7,0: HBA     : (qlc2300,1) QLogic QLA2300
  4,7,0: HBA     : (qlc2300,1) QLogic QLA2300
  5,7,0: HBA     : (qlc2300,1) QLogic QLA2300
  6,7,0: HBA     : (qlc2300,1) QLogic QLA2300
  7,7,0: HBA     : (qlc2300,1) QLogic QLA2300
2:0,7,0: HBA     : (qlc2300,2) QLogic QLA2300
  1,7,0: HBA     : (qlc2300,2) QLogic QLA2300
  2,7,0: HBA     : (qlc2300,2) QLogic QLA2300
  3,7,0: HBA     : (qlc2300,2) QLogic QLA2300
  4,7,0: HBA     : (qlc2300,2) QLogic QLA2300
  5,7,0: HBA     : (qlc2300,2) QLogic QLA2300
  6,7,0: HBA     : (qlc2300,2) QLogic QLA2300
  7,7,0: HBA     : (qlc2300,2) QLogic QLA2300
3:0,2,0: HBA     : (ide,2) Generic IDE/ATAPI
  0,0,0: CDROM   : HL-DT-STDVDRAM GSA-H44N RB01
ie:

In the example below the Storage Cabinet is entry:

0,0,0: DISK    : XYRATEX F5402E

and it is attached to a QLogic Dual Channel Controller:

It is assumed that you can mount this disk and read and write to the
files on a filesystem on this disk.   This would be achieved with the
"mkdev hd" command for OpenServer6 and "diskadd" command for
Unixware7.

It is assumed that you will have the latest maintenance installed for your operating system.

For OpenServer6:
---------------
To enable 'mpio', run:
# mkdev mpio

This command allows you to enable or disable the MPIO functionality of this SCO Open Server 6 system.

MPIO is currently disabled
What do you wish to do (enable|disable|quit)?

It is recommend to relink the kernel and reboot after it is enabled.

For UnixWare7:
-------------
By default mpio isn't installed on UW7.

You will need to install the 'mpio' package if it is not already there.

You can check with the command:
# pkginfo -l mpio
You can install the 'mpio' before or after Maintenance.  The 'mpio'
package contains the kernel elements while the Maintenance contains
the 'mpio' tools, ie. "sdipath".
ie.  The controlling program for 'mpio' is 'sdipath' and this is
installed as part of the base system and updated by Maintenance and
is not included with the 'mpio' package.

To install the 'mpio' package you need to insert CD1 from the UW7 installation media and run:

# pkgadd -d cdrom1 mpio

At the end of the installation the kernel will be relinked and you have to reboot the system.

Now mpio is active.
Preparation:
-----------
Once your server has rebooted, run:
# sdighost -l

If the number of disks shown do not match the number of DISKS shown in the command:

# sdiconfig -l

or it denotes ghost names then please run:

# sdighost -r

and reboot your server to ensure there are no ghost disk stamps (vtoc) recorded in the server's Resource Manager (resmgr).

Here is an example of what the "sdighost -l" command should return, as per our example above:

# sdighost -l
Device      Stamp         Real Address   Ghost Address
disk1    FWLUMRCTGjBN    c0b0t0d0sXX
disk2    IsLogMFFTVLd    c1b0t0d0sXX

UX:sdighost: INFO: Currently, no names are in use as Ghost Names

Usage:
------
Assuming "mpio" is now installed and "sdighost -l" is correctly
reporting the disks you have, run:
# sdipath -o list

and you should see something like, as per our example above:

Device   PhysDevice   Path      State     CPU Group   Reads   Writes
-------- ------------ ------    --------  ---------   ------- -------
disk1    c0b0t0d0     path85    Active        0       3644    3314
disk2    c1b0t0d0     path107   Active        0          7       0
disk2    c2b0t0d0     path108   Active        0          6       0
Where 'disk1' is the 'root' disk and is, therefore, not going to be
used with 'mpio'.  Whereas, 'disk2' is the logical volume we are
concerned about which will take advantage of 'mpio'.
'mpio' determines whether a 'disk' is accessible in multiple paths
via the driver the disk is attached to.  There is no real file
"c2b0t0d0" in /dev/dsk, this is a placeholder.

You will not see any difference in "sdiconfig -l", the only way to determine if 'mpio' is enabled to see what disks are configured with 'mpio' is to use the 'sdipath' command.

If there were ghost disk stamps still recorded in the "sdighost -l" command then you see multiple disks defined here which would be in error.

However, in this example now, everything is ready and 'mpio' is now fully in use.

Testing:
-------
1.  Unplug the SECOND lead connecting the Qlogic controller to the
    storage cabinet:
You should see:
# sdipath -o list
Device   PhysDevice   Path      State     CPU Group   Reads   Writes
-------- ------------ ------    --------  ---------   ------- -------
disk1    c0b0t0d0     path85    Active        0       3928    4248
disk2    c1b0t0d0     path107   Active        0        277      22
disk2    c2b0t0d0     path108   Failed        0         37       3

However, if you don't see a "Failed" status immediately once you try to do some read or writes on the mounted disk then you should see it go to a "Failed" status otherwise you can mark the path as failed with the "sdipath -o fail" command manually, see 'man sdipath', see below.

Once you've put the lead back, the path will not 'repair' itself automatically.

You will need to use the 'sdipath' command to repair it with:

# sdipath -o repair -d disk2 path108
Then you should see:
# sdipath -o list
Device   PhysDevice   Path      State     CPU Group   Reads   Writes
-------- ------------ ------    --------  ---------   ------- -------
disk1    c0b0t0d0     path85    Active        0       3929    4634
disk2    c1b0t0d0     path107   Active        0        277      45
disk2    c2b0t0d0     path108   Active        0         37       9

Next, unplug the FIRST lead connecting the Qlogic controller to the storage cabinet:

You should see:
# sdipath -o list
Device   PhysDevice   Path      State     CPU Group   Reads   Writes
-------- ------------ ------    --------  ---------   ------- -------
disk1    c0b0t0d0     path85    Active        0       3931    4742
disk2    c1b0t0d0     path107   Failed        0        277      45
disk2    c2b0t0d0     path108   Active        0       19288     19

Again, once you've plugged the lead back in then you can repair it as above.

You have now successfully installed, tested and become familiar with the 'mpio' commands necessary to administer your server.

To automate this facility, a suggestion would be to run "sdipath -o list" in a cron job and email an Administrator should a Failed condition arise.

To fail manually:
----------------
# sdipath -o fail disk2         - disk2 path109
:4:Path path109 has been failed.
# sdipath -o list
Device   PhysDevice   Path      State     CPU Group   Reads   Writes
-------- ------------ ------    --------  ---------   ------- -------
disk1    c0b0t0d0     path87    Active        0       8620    9540
disk2    c1b0t0d0     path109   Failed        0       42700   130
disk2    c2b0t0d0     path110   Active        0       58137   137

See also

http://uw714doc.xinuos.com/en/FEATS/ou800_mpio.html
sdipath(ADM) - OpenServer6
sdipath(1M) - UnixWare7

From the Xinuos technical article database, record 127084. Reproduced with permission. The original is at www.sco.com/ta/127084, which is reachable but blocked from search engines.

Next step

Need this fixed rather than explained?

Tell us the release, what the system runs and what it is doing. We will reply by email with what we would do next.

  • You deal with the people who do the work
  • No obligation, and no upgrade required before we will help
  • We tell you plainly if something is not worth doing

Send an enquiry

We reply by email. If a server is down, say so in the first line. You can also write to help@scoexpert.com.