Protection exception (S0C4)



IBM's cross-platform compiler PL/I for MVS, VM & VSE, OS/390 and Enterprise PL/I for z/OS

Protection exception (S0C4)

Postby shik.trip » Tue Sep 22, 2009 7:50 pm

In our production system,we encountered below error for a job :

CEE3204S The system detected a protection exception (System Completion Code=0C4).

We ran this JCL multiple times to see what exactly went wrong as the code hasn't been changed from past many years.
Although the number of records, that the program processed successfully, were written in output file and rest were rejected.So we tried running the input file in parts as Part 1 and part 2 where we took half of the records in both.
This time the job ran successfully without any abends.

Could anybody please let me know,what exactly would be the possible cause of such abend.

Thanks a lot.
shik.trip
 
Posts: 5
Joined: Tue Sep 22, 2009 7:41 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Protection exception (System Completion Code=0C4).

Postby enrico-sorichetti » Tue Sep 22, 2009 7:54 pm

maybe the program has an internal table...
whose size depends on the number of records being processed
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2966
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 160 times

Re: Protection exception (System Completion Code=0C4).

Postby shik.trip » Tue Sep 22, 2009 8:16 pm

Thanks for your suggestion,but we noticed that the program doesn't insert/update/delete any record in tables,it just reads data from the table,uses the input file and produces the output for it.
shik.trip
 
Posts: 5
Joined: Tue Sep 22, 2009 7:41 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Protection exception (System Completion Code=0C4).

Postby Anuj Dhawan » Tue Sep 22, 2009 8:49 pm

Enrico meant "COBOL arrays (table)". S0C4 is Protection Exception, by definition.

There can be many reasons behind S0C4, such as --
  • An uncontrolled loop moved data on top of instructions.
  • Referencing a field in a record of a closed file .
  • Referencing an item in Linkage-Section when there was no PARM= in the JCL.
  • Calling/called programs have different length for items passed in Linkage Section.
  • With COBOL Sort, doing a STOP RUN or GOBACK while an input or output procedure is still running.
Check what is happening at your end. Without looking at program and abend-diagnosis information, it's hard to tell what happened there.
Anuj
Anuj Dhawan
 
Posts: 273
Joined: Mon Feb 25, 2008 3:53 am
Location: Mumbai, India
Has thanked: 6 times
Been thanked: 4 times

Re: Protection exception (System Completion Code=0C4).

Postby Anuj Dhawan » Tue Sep 22, 2009 9:00 pm

  • Just being nit picky -- What language are you using?
  • What is the precise error message -- copy using BBCode from the job?
  • Post the messages around the error message as well.
  • S0C4 is accompanied with a reason code. What is it?
Anuj
Anuj Dhawan
 
Posts: 273
Joined: Mon Feb 25, 2008 3:53 am
Location: Mumbai, India
Has thanked: 6 times
Been thanked: 4 times

Re: Protection exception (System Completion Code=0C4).

Postby shik.trip » Thu Sep 24, 2009 8:21 pm

Thanks for suggestion.
We are using PL1 as the programming language.
There is a strange error I noticed in the job spool as below:
$HASP375 $10MDM23 ESTIMATED LINES EXCEEDED
-$10MDMXX MDP123 S0020 1000 26019 7198 .01 .00 .1 22291
*TRACWARN - JOB $10MDMXX STEP# 15 S0020 COND CODE=1000 VERS=0921.0001

The error of protection exception was thrown during the step of the program,wherein the error is as below:

Condition Information for Active Routines
Condition Information for Library(PLI) (DSA address 0008E290)
CIB Address: 26A7F250
Current Condition:
CEE3204S The system detected a protection exception (System Completion Code = 0C4)
Location:
Program Unit: Library(PLI)
Entry: Library(PLI)
Statement: Offset: -269E88A6
Machine State:
ILC..... 0000 Interruption Code..... 0004

Thanks
shik.trip
 
Posts: 5
Joined: Tue Sep 22, 2009 7:41 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Protection exception (System Completion Code=0C4).

Postby dick scherrer » Fri Sep 25, 2009 12:54 am

Hello,

Did you look at the large output and see if the program is in a loop? Is this process supposed to generate a large number of printed lines?

It may be that the code has gone beyond some data area (an array perhaps) while generating this large amount of printout in the spool. Exceeding estimated lines does not cause an 0c4. . .
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6269
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Protection exception (System Completion Code=0C4).

Postby shik.trip » Mon Sep 28, 2009 4:33 pm

Thanks D,

This program handles a data not more than 30k or 40k lines of records which can be easily manageable.
The program just takes the input from a file,reads through the DB and generates the output.
nothing is to be printed in spool.
shik.trip
 
Posts: 5
Joined: Tue Sep 22, 2009 7:41 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Protection exception (System Completion Code=0C4).

Postby dick scherrer » Tue Sep 29, 2009 2:13 am

Hello,

nothing is to be printed in spool.
Possibly a terminology mis-cue - something is printed to the spool or there could not be "$HASP375 $10MDM23 ESTIMATED LINES EXCEEDED". It is possible that the "excessive" output is the dump.

Suggest you look at whatever is in the output queue and see what there is to be learned.

If may help if you post the first file for this job in the output queue - JESMSGLG.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6269
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Protection exception (System Completion Code=0C4).

Postby shik.trip » Wed Oct 07, 2009 8:41 pm

I have the below piece of code in my program
DCL INPTR                      POINTER;   
DCL 1 OVER BASED(INPTR),                               
       3 SEQ_NO                       PIC'(6)9',         
       3 RECORD_TYPE             CHAR(03),         
       3 FILLER                       CHAR(375);         

 DCL 1 MDI2432  UNALIGNED BASED (INPTR),
       %INCLUDE MDI2432;       


It seems to me that this line of code is generating the problem as when I use the code as
DCL 1 MDI2432 UNALIGNED,
it works correctly but give me strange record output as ...............................
Also,the same line DCL 1 MDIXXXX UNALIGNED BASED (INPTR), is being used for other copybooks which works correctly but only this copybook ,it creates problem for protection exception.

Does anybody have a clue?
Thanks for the help.
shik.trip
 
Posts: 5
Joined: Tue Sep 22, 2009 7:41 pm
Has thanked: 0 time
Been thanked: 0 time

Next

Return to PL/I

 


  • Related topics
    Replies
    Views
    Last post