IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

How to allocate more storage to EXECIO


IBM Mainframe Forums -> CLIST & REXX
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Ayyappan

New User


Joined: 05 Jul 2005
Posts: 31
Location: India

PostPosted: Thu Jul 28, 2005 4:59 pm
Reply with quote

Hi,
I have written a tool to find the number of records in a file using the following coding in rexx.

"EXECIO * DISKR DDIN (FINIS STEM A.";
SAY "NUMBER OF RECORDS IN THE INPUT FILE IS:" A.0

My input file is having more than 1 million records. So when i execute this tool I am getting the EXECIO error. "Unable to obtain storage."

How can i alocate more storage?

Thanks.
Ayyappan
Back to top
View user's profile Send private message
Prandip

New User


Joined: 04 Mar 2005
Posts: 84
Location: In my tiny cubicle ...

PostPosted: Thu Jul 28, 2005 6:10 pm
Reply with quote

Ayyappan wrote:

How can i alocate more storage?

You can't. Talk to your MVS/JES Systems Programmers. They have apparently set a storage limit that you have exceeded. I would recommend that you find another solution, as there are storage limits to how many stem variables you can create within an address space.
Back to top
View user's profile Send private message
Ayyappan

New User


Joined: 05 Jul 2005
Posts: 31
Location: India

PostPosted: Fri Jul 29, 2005 7:38 pm
Reply with quote

Is there any other way by which i can read and get the number of records in a file? If i open and see the file, it is taking more time. So I wanted to create a rexx tool which i can run in backround. But it is giving me this problem.
Back to top
View user's profile Send private message
Prandip

New User


Joined: 04 Mar 2005
Posts: 84
Location: In my tiny cubicle ...

PostPosted: Fri Jul 29, 2005 9:37 pm
Reply with quote

Normally, if you are using EXECIO to read a file of an unknown size, you read it one record at a time into the stack:
Code:

RECCNT = 0
DO FOREVER
  "EXECIO 1 DISKR DDIN"
  IF RC <> 0 THEN LEAVE
  RECCNT = RECCNT + 1
END
"EXECIO 0 DISKR DDIN (FINIS"
SAY "NUMBER OF RECORDS IN THE INPUT FILE IS:" RECCNT


Optionally, you could, if you wish to use a stem variable, read the records in limited chunks (say a 1000 at a time), keeping the number of records read in an accumulator.

That being said, I'm sure that you're aware that I/O processsing using EXECIO is rather slow, and that EXECIO is not well suited for processing large amounts of data in a reasonable amount of time. For simply counting records, a utility such as DFSORT or ICETOOL does a much better job with much less overhead.
Back to top
View user's profile Send private message
MGIndaco

Active User


Joined: 10 Mar 2005
Posts: 432
Location: Milan, Italy

PostPosted: Sat Aug 13, 2005 1:09 am
Reply with quote

I think, but I can be wrong(and for this I'm sorry but I need an explanation), that using the ExecIO you will use a large quantity of storage machine because all the data that you process is loaded in a Stack.
To avoid this problem you can delete the Stack(DELSTACK) when you finish to use the data.
In practise I used Rexx to scan my entire application(300 disks) and I spent very amount of time but I succeed!
In a second time I compiled my rexx and the time was reduced to a six part of original.
To conclude my theory, if you use correctly the storage and if you compile your rexx you will able to do anything...

All comment to this are really wellcome.
Back to top
View user's profile Send private message
Ayyappan

New User


Joined: 05 Jul 2005
Posts: 31
Location: India

PostPosted: Sat Aug 13, 2005 3:38 pm
Reply with quote

Hi,
Could you please tell me how to compile a rexx program. I never compile it. Pklease explain me more on this.

Thanks.
Back to top
View user's profile Send private message
MGIndaco

Active User


Joined: 10 Mar 2005
Posts: 432
Location: Milan, Italy

PostPosted: Mon Aug 22, 2005 9:17 pm
Reply with quote

There are two mainly reason to compile a Rexx program:
1) the security of your source;
2) the high performance.

And to compile it there are several methods that depends on the address you are currently working.

In my experience I used mainly one compiler that's REXXCOMP available in your installation.
This module is executed from a proc that usually is REXXCL that's in your SYS1.PROCLIB or SYS1.USER.PROCLIB(do not modify)

When you open it you will find a member like this:
Code:
//****************************************************************** 
//*                                                                   
//* REXXCL  Compile and link edit a REXX program of OBJ type.         
//*                                                                   
//* Copyright:                                                       
//*                                                                   
//*         Licensed Materials - Property of IBM                     
//*         5695-013 IBM Compiler for SAA REXX/370, Release 3         
//*         (C) Copyright IBM Corp. 1991, 1994                       
//*         All rights reserved.                                     
//*                                                                   
//* Change Activity:                                                 
//*   94-10-27     Release 3.0                                       
//*                                                                   
//****************************************************************** 
//*                                                                   
//* Parameters:                                                       
//*                                                                   
//*   STUB        Stub type: MVS, CPPL, CALLCMD, EFPL, CPPLEFPL.     
//*               Default: EFPL.                                     
//*                                                                   
//*   OPTIONS     Compilation options.                               
//*               Default: XREF OBJECT NOCEXEC                       
//*                                                                   
//*   COMPDSN     DSN of IBM Compiler for SAA REXX/370 load library. 
//*                                                                   
//*   LIBDSN      DSN of IBM Library for SAA REXX/370 load library.   
//*                                                                   
//*   LIBXDSN     DSN of IBM Library for SAA REXX/370 exec library.   
//*                                                                   
//* Required:                                                         
//*                                                                   
//*   REXX.SYSIN  DDNAME, REXX program to be compiled and link       
//*               edited.                                             
//*                                                                   
//* Example:                                                         
//*                                                                   
//*   To compile MYREXX.EXEC(MYPROG) and to link edit the resulting   
//*   OBJECT output together with a stub suitable for invocation     
//*   of the program from a REXX EXEC with the CALL instruction or   
//*   via function invocation, and to keep the resulting load module 
//*   in MYREXX.LOAD(MYPROG), use the following invocation:           
//*                                                                   
//*   //S1 EXEC REXXCL                                               
//*   //REXX.SYSIN   DD DSN=MYREXX.EXEC(MYPROG),DISP=SHR             
//*   //LKED.SYSLMOD DD DSN=MYREXX.LOAD(MYPROG),DISP=SHR             
//*                                                                   
//****************************************************************** 
//*                                                                   
//REXXCL  PROC STUB=EFPL,                     Type of stub           
//             OPTIONS='XREF OBJECT NOCEXEC',   REXX Compiler options
//             COMPDSN='REXX.VxRxxx.SFANLMD',   REXX Compiler loadlib
//             LIBDSN='REXX.VxRxxx.SEAGLMD',    REXX Library loadlib 
//             LIBXDSN='REXX.VxRxxx.SEAGCMD'    REXX Library execlib 
//*                                                                   
//*----------------------------------------------------------------- 
//* Compile REXX program.                                             
//*----------------------------------------------------------------- 
//*                                                                   
//REXX    EXEC PGM=REXXCOMP,PARM='&OPTIONS'                         
//STEPLIB   DD DSN=&COMPDSN,DISP=SHR                                 
//SYSPRINT  DD SYSOUT=*                                             
//SYSTERM   DD SYSOUT=*                                             
//*SYSIEXEC DD DUMMY                                                 
//*SYSDUMP  DD DUMMY                                                 
//*SYSCEXEC DD DUMMY                                                 
//SYSPUNCH  DD DSN=&&OBJECT,DISP=(MOD,PASS),UNIT=SYSDA,             
//             SPACE=(800,(800,100))                                 
//*                                                                 
//*-----------------------------------------------------------------
//* Prepare SYSLIN data set for subsequent link step.               
//*-----------------------------------------------------------------
//*                                                                 
//PLKED   EXEC PGM=IRXJCL,PARM='REXXL &STUB',                       
//             COND=(9,LT,REXX)                                     
//*                                                                 
//SYSEXEC   DD DSN=&LIBXDSN,DISP=SHR                                 
//SYSIN     DD DSN=&&OBJECT,DISP=(OLD,DELETE)                       
//SYSTSPRT  DD SYSOUT=*                                             
//SYSOUT    DD DSN=&&SYSOUT,DISP=(MOD,PASS),UNIT=SYSDA,             
//             DCB=(RECFM=FB,LRECL=80,BLKSIZE=800),                 
//             SPACE=(800,(800,100))                                 
//*                                                                 
//*-----------------------------------------------------------------
//* Link together stub and program.                                 
//*-----------------------------------------------------------------
//*                                                                 
//LKED    EXEC PGM=HEWL,PARM='LIST,AMODE=31,RMODE=ANY,RENT,MAP',     
//             COND=((9,LT,REXX),(0,NE,PLKED))                       
//*                                                                 
//SYSLIN    DD DSN=&&SYSOUT,DISP=(OLD,DELETE)                       
//SYSLIB    DD DSN=&LIBDSN,DISP=SHR                                 
//SYSUT1    DD UNIT=SYSDA,SPACE=(1024,(200,20))                     
//SYSPRINT  DD SYSOUT=*                                             
//SYSLMOD   DD DSN=&&GOSET(GO),DISP=(MOD,PASS),UNIT=SYSDA,           
//             SPACE=(1024,(50,20,1))                               


If you find this you have a compiler(is a default except for the name of the library).
I don't want to specify every statements so I assume that you have the right knowledge.

After this you must specify, as explained, in the comment of the proc the correct STUB you want to use, the source and the final loadlib.

I want to specify that there are some restriction for the different stub you want to use, and to have an idea of this I suggest you to read the Rexx manual.

A little piece of available function is on this link:
http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/handheld/Connected/BOOKS/ikj4a350/8.6?DT=20040623084642
Where, if you try to compile your source with STUB=MVS you will able to do only the instruction/Function/Commands and service of TSO environment and Non-TSO/E specified.
To avoid this restriction you can use the correct STUB

I hope in this help and if you need further information I'm available for that.
Back to top
View user's profile Send private message
puneet478

New User


Joined: 03 Jan 2006
Posts: 13
Location: Bangalore india

PostPosted: Sat Sep 09, 2006 3:29 am
Reply with quote

Hi MGIndaco,

I do have the above JCL but when i run it, it says REXXCOMP not found. I tried to find this program in various libraries but not able to. Does it reside in some particular library?

Also, I dont have any STEPLIB defined in REXXCC jcl under step 'compile REXX program'. Is this system defined or user defined?

Regards,
Puneet[/quote]
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CLIST & REXX

 


Similar Topics
Topic Forum Replies
No new posts CLIST - Virtual storage allocation error CLIST & REXX 5
No new posts CICS vs LE: STORAGE option CICS 0
No new posts Insufficient Storage ABENDS & Debugging 7
No new posts Interviewers are surprised with my an... Mainframe Interview Questions 6
No new posts is there an API to use cloud storage ... All Other Mainframe Topics 2
Search our Forums:

Back to Top