TAA Tools
CHKASPSTG       CHECK ASP STORAGE                      TAASYTP

The Check  ASP  Storage command  allows you  to check  a percentage  of
available storage  in an ASP  against the size  of objects you  need to
create.    An  escape  message  (TAA9896)  is  sent  if  the  amount of
requested storage  exceeds a  specified percent  of available  storage.
This  can be  useful when  an application  needs to  duplicate  a large
object in QTEMP.

A typical command would be:

             CHKASPSTG     RQSSTG(nnnnnn)

The default is to use ASP 1.

If  the PCT parameter default of *DFT  is taken, the default percentage
is defined  in  the CHKASPSTG  Application  Value  in TAASECURE.    The
shipped default is 50%.  See later discussion.

ASP 1 is always used for objects created in QTEMP.

If you  had requested  that 200,000,000 bytes  be available,  the value
is converted to MB and checked against ASP 1.

  **   If the  ASP 1 available storage was 600 MB,  50% would be 300 MB
       and the command would complete normally.

  **   If the ASP 1 available storage was  250 MB, 50% would be 125  MB
       and the TAA9896 escape message would be sent.

Note that  CHKASPSTG does  not reserve the  space.   It only  checks to
ensure that the request is reasonable.

Sample usage
------------

Assume you are  going to duplicate a file in QTEMP  and the file may be
large.    If you  want  a 'reasonableness  check'  that there  would be
sufficient room  in QTEMP (as  well as  a buffer  for other jobs),  you
would have code such as:

             DCL        &SIZE *DEC LEN(15 0)
              .
             RTVOBJD    OBJ(xxx) OBJTYPE(*yyy) SIZE(&SIZE)
             CHKASPSTG  RQSSTG(&SIZE)

CHKASPSTG Application Value in TAASECURE
----------------------------------------

If  CHKASPSTG is  used with  PCT(*DFT),  a prompt  override program  is
used  that  will  extract the  default  percentage  from  the CHKASPSTG
Application  Value  (*USRSPC  object)   in  TAASECURE.    This   allows
internal TAA tools  such as SORTDBF to  check for your definition  of a
reasonable value when creating objects in QTEMP.

The  Security Officer  can change  the  default percentage  by entering
the command:

            EDTAPPVAL    APPVAL(TAASECURE/CHKASPSTG)

The prompt override  program is  only used if  PCT(*DFT) is  specified.
All ASPs use the same default value.

CHKASPSTG escape messages you can monitor for
---------------------------------------------

      TAA9896    Requested amount is not available with % requested

Escape messages from based on functions will be re-sent.

Command parameters                                    *CMD
------------------

   RQSSTG        The requested  storage in  bytes.   The value must  be
                 between  1  and  999,999,999,999,999.   The  value  is
                 converted  to  MB  (each MB  is  1,048,576  bytes) and
                 compared  against the  unused  storage  multiplied  by
                 the  percent  indicated  for  a  specific  ASP.    The
                 maximum value in MB is 953,674,316.

   ASP           The  ASP number  if it  is known.   The default  is 1.
                 Either an ASP  number or  an ASP device  name must  be
                 entered.     If  an   ASP  device  name   is  entered,
                 ASP(*NONE) must be specified.

   ASPDEV        The ASP  device name.  Either an  ASP number or an ASP
                 device name must be entered.

   PCT           The percentage of  the available  storage required  in
                 the specified  ASP.  The  default is *DFT  which means
                 to  use the value  found in the  CHKASPSTG Application
                 Value  in library  TAASECURE.  The  shipped default is
                 50%.    See  the  previous  discussion  about  how  to
                 change the value.

Restrictions
------------

None.

Prerequisites
-------------

The following TAA Tools must be on your system:

     EDTVAR          Edit variable
     RTVASPSTS       Retrieve ASP status
     SNDESCINF       Send escape information
     SNDESCMSG       Send escape message

Implementation
--------------

None, the tool is ready to use.

Objects used by the tool
------------------------

   Object        Type    Attribute      Src member    Src file
   ------        ----    ---------      ----------    ----------

   CHKASPSTG     *CMD                   TAASYTP       QATTCMD
   TAASYTPC      *PGM       CLP         TAASYTPC      QATTCL
   TAASYTPC2     *PGM       CLP         TAASYTPC2     QATTCL
   TAASYTPC3     *PGM       CLP         TAASYTPC3     QATTCL

The CHKASPSTG Application Value exists in TAASECURE.

Both the  TAASYTPC2 (prompt override  program) and TAASYTPC3  adopt the
QSECOFR profile to access the Application Value in TAASECURE.
					

Added to TAA Productivity tools June 15, 2004


Home Page Up to Top