[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference ssdevo::hsz40_product

Title:HSZ40 Product Conference
Moderator:SSDEVO::EDMONDS
Created:Mon Apr 11 1994
Last Modified:Fri Jun 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:902
Total number of notes:3319

853.0. "Callable API (UNIX) to "talk to" HSZ40/HSZ50?..." by AMCUCS::SWIERKOWSKI (Quot homines tot sententiae) Wed Apr 23 1997 20:07

Greetings!

  Got a call from a developer today asking about a callable API (under Digital
UNIX) to the HSZ40/HSZ50.  I suspect he wants to enhance his application (a
general purpose device monitoring tool) to be able to poke around and find out
configuration/status information about disks attached to HSZ40's/HSZ50's doing
something similar to what I suspect HSZTERM and/or "DIGITAL StorageWorks Command
Console" does.  I have no experience with HSZTERM (or SWCC?) so I don't really
understand if it gives the kind of information the developer would like to
extract under program control or not, but I assume sort of "API" is being used
by those product(s) to talk to the HSZx0's.

  He also mentioned the "table() interface" to extract information about the 
system - does anyone know if this "table() interface" can deal with individual 
devices living behind a RAID controller (like HSZx0's)?  Any and all informa-
tion, pointers, etc. would be gratefully accepted since I struck out searching 
this conference, the ASK_SSAG conference and using COMETS to search for things 
with "API" and "HSZ40" and "UNIX" in it, cheers...



						Tony Swierkowski
						Digital Equipment Corporation
						Software Partner Engineering
						Palo Alto, California
						(415) 617-3601
						"[email protected]"
T.RTitleUserPersonal
Name
DateLines
853.1SSDEVO::ROLLOWDr. File System's Home for Wayward Inodes.Wed Apr 23 1997 23:2631
Last I knew, there were two ways to communicate with the HSZ40/50:

o  Serial port.
o  SCSI commands.

HSZterm uses the SCSI commands Send Diagnostic and Receive Diagnostic
(with the occasional Test Unit Ready thrown in).  It was hard to do
using the SCSI CAM interface and it wasn't safe when run against
logical units that were active.  I think the latest version of
HSZterm uses a library of routines that are safer, but when I saw
them poorly documented.  And, in my opinion, harder to use than
the raw SCSI CAM User Agent interface.

With a little creative use of popen(3) and HSZterm, a UNIX programmer
can create an interface for sending HSZ CLI commands and getting
the response.  The hard part (the REALLY hard part), is parsing
the CLI output.  It isn't very regular and doesn't lend itself to
parsing.  There's been talk of getting the same information through
vendor specific SCSI commands, mode sense pages or (once stable)
SCSI-3 RAID control commands.  Maybe before the turn of the century...

I spent about a year doing a GUI based around popen/HSZterm and
only got as far as the Motif based GUI that you may find other
notes for.  It worked back around the HSOF V25Z timeframe, but
was still pretty raw.  I wish this customer more luck than I
had.

re: table(2)

The operating system has no clue what's behind the logical units
presented by the controller.
853.2Thanks re: "API" for the HSZxx under Digital UNIX...AMCUCS::SWIERKOWSKIQuot homines tot sententiaeFri Apr 25 1997 18:4127
Greetings!

  Thanks for the quick answer!  I kind of suspected the base operating system
didn't supply some sort of "API" nor did it appear that products like HSZterm or
SWCC provided it.  I've advised the customer that this may be just the sort of
application he doesn't want to tackle for now given your comments in .1.  In any
event thanks for the feedback.

  I'm sort of on thin ice here so bear with me, but is there some sort of other
command, system function, RTL or utility in the operating system that can poke
the HSZXX (other than the "table() interface") that can provide any information
on the individual devices "hiding behind" an HSZxx?  

  I don't know much about the "raw SCSI CAM User Agent interface" but I suspect
this is the only way to code up something that would be able to do what the 
customer hopes to achieve since you've confirmed my suspicion that the "table()
interface" is oblivious to device-specific information on devices attached to 
an HSZXX.  Just curious...



						Tony Swierkowski
						Digital Equipment Corporation
						Software Partner Engineering
						Palo Alto, California
						(415) 617-3601
						"[email protected]"
853.3NABETH::alanDr. File System's Home for Wayward Inodes.Fri Apr 25 1997 20:4359
	re: Some other way.

	Nope, because the HSZ doesn't present anything.  The operating
	system sees the logical units.  For arrays and notransportable
	disks the operating system sees an HSZ40 (HSZ50 or whatever)
	device.  In the place or two that matters, Digital UNIX happens
	to know that this class of device doesn't have a a constant
	capacity or geometry.  But, the HSZ being a good SCSI device
	provides this information via the Read Capacity and Mode Sense
	commands.

	Transportable and passthrough devices (tapes & loaders) will
	present themselves as whatever they are.

	The only way to get information on what is on the other
	side is to parse the output from "show device, "show storage"
	and "show unit".  One thing I will note is that when I was
	working on the GUI I needed all the configuration information
	for these devices.  The customer might be able to get by
	with just the simple output.  For example, where I was
	trying to parse:

Ramoth> show d205

    LUN                                      Uses
--------------------------------------------------------------

  D205                                       DISK250
        Switches:
          RUN                    NOWRITE_PROTECT        READ_CACHE            
          MAXIMUM_CACHED_TRANSFER_SIZE = 32
        State:
          ONLINE to this controller
          Not reserved
          PREFERRED_PATH = THIS_CONTROLLER
        Size: 4110480 blocks
  <repeat for each unit...>

	The customer may find it easier to handle:

Ramoth> show unit

    LUN                                      Uses
--------------------------------------------------------------

  D2                                         DISK220
  D200                                       DISK200
  D201                                       DISK210
  D203                                       DISK230
  D205                                       DISK250
  P0                                         TAPE140
  P1                                         LOADER867

	What I was doing, the code to parse controllers, device,
	licenses, storage sets and units for three different
	versions of HSOF was over 4,000 lines of code.  Someone
	not wanting as much information may get by with less
	and HSZterm does lend itself to being used by popen(3);
	I changed it so that it would...