HP 3000 Manuals

Adding Your Own Tools [ NS3000/iX Operations & Maintenance Reference Manual ] MPE/iX 5.0 Documentation


NS3000/iX Operations & Maintenance Reference Manual

Adding Your Own Tools 

You can add you own diagnostic tools to by following some simple rules.
You can also provide help information on the user-provided tools.

To Add User Tools 

Information needed to run a user-provided tool must reside in
USERINFO.NET.SYS. You can create this file with any text editor.  It must
have a record length of 80 characters or less.

You can describe up to 20 user tools in the file.  For each tool, two
types of entries are needed:  the one word command which will initiate
the tool from the root level of NETTOOL, and a list of the MPE commands
required to start the tool (as if it were being used standalone).

The first character in the tool command must be alphabetic.  The command
can be up to 20 characters in length.  It must not duplicate any NETTOOL
global command, core tool name, or associated tool name.

The first character in a line containing an MPE command must be an
exclamation mark.  Characters may be either lower or upper case, but
NETTOOL does not distinguish between the two.  NETTOOL does not interpret
the string after the exclamation mark in any way.  Up to 79 characters
may follow the exclamation mark.

The list of MPE commands must follow the command name.  For example, a
valid set of entries in the file might be:

     NEATPROG2
     !file input=fromhere.pub.sys
     !file output=tohere.net.sys
     !run myprog.maui.hawaii;info="map, 26, verbose";lib=p
     TESTTOOL
     !run testtool.net.sys

To run MYPROG.MAUI.HAWAII from the NETTOOL root, a user would enter the
command NEATPROG2.  To run TESTTOOL.NET.SYS, the user would enter
TESTTOOL.

Any first character in a line other than !, a..z, or A..Z is an error and
will cause all subsequent entries to be ignored.  Also, if you specify
more than five MPE commands for a tool, all subsequent entries in the
file will be ignored.  Blank lines have no effect.  Lines with only a !
will be sent to MPE as a carriage return.

A sample USERINFO file is included as part of the NETTOOL package.

To Add User Provided Help 

To provide help on user tools, you must create the file USERHELP.NET.SYS.
This file should contain help text for all user tools defined in
USERINFO.net.sys.

Use the following format for help text:

   1.  There must be an \ENTRY=ROOT block which gives a one word list of
       the user-defined NETTOOL commands.  These commands are the same as
       those defined in USERINFO.NET.SYS. This is the text that will be
       displayed when the user types help with no parameters at the root
       level.

   2.  Within the \ENTRY=ROOT block, there must be an \item=commands
       block that contains a one line description of the user-defined
       commands that run the tools.  This is the text that will be
       displayed when the user types help commands at the root level.

   3.  Within the \ENTRY=ROOT block, there must be an \ITEM=command_name
       block for each of the tools.  These blocks contain the text that
       is displayed when the user types help command_name at the root
       level where command_name is a user command defined in
       USERINFO.NET.SYS.

   4.  There must be an \ALL directive at the end of the help text.

A sample USERhelp file is included as part of the NETTOOL package.  See
the example on the next page.

For a user-defined tool defined as follows:

     mytool
     !file input=parms.net.sys
     !run myprog.net.sys

The user help might look like this:

     \ENTRY=ROOT
       MYTOOL
     \ITEM=COMMANDS
       MYTOOLExamines the path cache and purges all entries
     \ITEM=MYTOOL
       If you suspect that the path cache is out of unused
       entries or that duplicate IP addresses have been
       defined, use MYTOOL to clear the entire cache.
     \ALL

   1.  You must format the help file into a help catalog using
       MAKECAT.PUB.SYS, as follows:

            file input=sourcefilename
            run makecat.pub.sys,help
            rename helpcat,userhelp.net.sys
            reset input

       Here, sourcefilename is your unformatted help file and helpcat is
       the file name reserved by MAKECAT for its output.



MPE/iX 5.0 Documentation