View previous topic :: View next topic |
Author |
Message |
ace Beginner
Joined: 24 Feb 2004 Posts: 58 Topics: 23
|
Posted: Fri Sep 15, 2006 7:26 pm Post subject: Rexx- Machine storage exhausted |
|
|
Hi,
I'm getting the following error when I try to process huge files.
Machine storage exhausted
Is there anyway to overcome this issue. Please help. _________________ Thank You
-Ace |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12372 Topics: 75 Location: San Jose
|
|
Back to top |
|
|
ace Beginner
Joined: 24 Feb 2004 Posts: 58 Topics: 23
|
Posted: Sat Sep 16, 2006 7:22 am Post subject: |
|
|
Thanks Kolusu.
I did search in google before posting the issue here but didn't get any work around from the search results. _________________ Thank You
-Ace |
|
Back to top |
|
|
ace Beginner
Joined: 24 Feb 2004 Posts: 58 Topics: 23
|
Posted: Wed Sep 20, 2006 2:30 pm Post subject: |
|
|
Can somebody please help me out ?
I'm not using any ISPF panels. It's just reading a file (character by character) and based on some condition create a report file. But the job is abending while processing huge files. _________________ Thank You
-Ace |
|
Back to top |
|
|
superk Advanced
Joined: 19 Dec 2002 Posts: 684 Topics: 5
|
Posted: Wed Sep 20, 2006 2:43 pm Post subject: |
|
|
When you use EXECIO, you are typically reading one record at a time into the stack:
EXECIO 1 DISKR ddname
processing the record:
PARSE PULL the_record
and then either pushing it out for a write:
PUSH the_record
EXECIO 1 DISKW ddname
or just moving on to the next record.
I could definitely see a problem running out of storage if you're trying to read too many records at one time.
This can also occur by using too many CALL's and/or SIGNAL's. |
|
Back to top |
|
|
ace Beginner
Joined: 24 Feb 2004 Posts: 58 Topics: 23
|
Posted: Wed Sep 20, 2006 3:11 pm Post subject: |
|
|
superk,
Actually this is related to a previous post of mine http://www.mvsforums.com/helpboards/viewtopic.php?t=7132
that has been answered ny Semigeezer. I'm trying to read each character and mathing for a pattern. It's working fine if the file is of limited size or the LRECL of limited length. But when Itried to process a huge file with 26600 length and of millions of record (I'm running this in batch), I'm getting the Machine storage exhausted error. The Rexx is running thru fine when I split the file into halves. Please help. _________________ Thank You
-Ace |
|
Back to top |
|
|
acevedo Beginner
Joined: 03 Dec 2002 Posts: 127 Topics: 0 Location: Europe
|
Posted: Thu Sep 21, 2006 1:24 am Post subject: |
|
|
1-But the job is abending while processing huge files
2-The Rexx is running thru fine when I split the file into halves
I'm agree with superk... are you doing a "execio * diskr" ? |
|
Back to top |
|
|
ace Beginner
Joined: 24 Feb 2004 Posts: 58 Topics: 23
|
Posted: Thu Sep 21, 2006 8:56 am Post subject: |
|
|
acevedo,
Yes, I 'm using 'execio * diskr'. Is there any work around for it. _________________ Thank You
-Ace |
|
Back to top |
|
|
danm Intermediate
Joined: 29 Jun 2004 Posts: 170 Topics: 73
|
Posted: Thu Sep 21, 2006 9:43 am Post subject: |
|
|
Read n number of lines (e.g. 100) at a time.
Code: |
StartRec = 1
Nrecs = 100 /* Choose any # of record to be read */
Do until Nomore = 2
"EXECIO" Nrecs "DISKR INPFILE" StartRec "(STEM REC."
Nomore = rc
If 0 = wordpos(Nomore,'0 2') then do
say 'Unable to read dataset', rc=' Nomore
leave
End /* If 0 = wordpos(Nomore,'0 2') then do */
Do I = 1 to Rec.0
/* Process record */
.........
End /* Do I = 1 to Rec.0 */
StartRec = StartRec + Rec.0
End /* Do until Nomore = 2 */
|
|
|
Back to top |
|
|
ace Beginner
Joined: 24 Feb 2004 Posts: 58 Topics: 23
|
Posted: Thu Sep 21, 2006 8:14 pm Post subject: |
|
|
Thank you danm. It worked.
I'm a newbie in Rexx. _________________ Thank You
-Ace |
|
Back to top |
|
|
|
|