Solved

Getting CPF7007 error code while using QjoRetrieveJournalEntries api  - AS400

Posted on 2014-01-07
4
84 Views
Last Modified: 2016-06-13
Hi,

in AS400, currently we are using  QjoRetrieveJournalEntries api to retervie the journal entries form As400 Journals.

but currently i am getting the API exception CPF7007. some the API docs

http://pic.dhe.ibm.com/infocenter/iseries/v7r1m0/index.jsp?topic=%2Fcl%2Frcvjrne.htm

Could you please let me know when will we get CPF7007 message code for the QjoRetrieveJournalEntries api?

Thanks,
Venkat
0
Comment
Question by:Vsomepalli
4 Comments
 
LVL 16

Expert Comment

by:theo kouwenhoven
ID: 39772667
Cpf7007 is te result of an journal action on a file member that can nor be allocated, Because it is inexclusively locked on that moment.
0
 
LVL 34

Accepted Solution

by:
Gary Patterson earned 500 total points
ID: 39772674
Hi Venkat,

CPF7007 = Cannot allocate member __ in file __ in __.

If you look at the documentation for the QjoRetrieveJournalEntries API (the API behind the RCVJRNE command), at

http://pic.dhe.ibm.com/infocenter/iseries/v7r1m0/index.jsp?topic=%2Fapis%2FQJORJRNE.htm

you'll see that the following lock is required:

Authorities and Locks
...
Non-Integrated File System Object Lock (if specified) *SHRRD

This seems to mean that if you are retrieving journal entries for a file, the job running the QjoRetrieveJournalEntries API needs to be able to acquire a shared read lock on the underlying file.

I guessing that when this happens in your environment, another process has an exclusive lock on the file.  Exclusive locks cause lots of problems.  Find out what job is locking the file exclusively, and why.

If the exclusive lock is short, you may want to just pause journal processing for a bit until the exclusive lock is release.  If the exclusive lock is long, you may want to journal this file to a different journal receiver and process it seperately - and schedule around the job that is holding the exclusive lock.

When the error occurs, determine the name of the file/member that is being processed, and use the WRKOBJLCK command to find the job holding the conflicting lock.

- Gary Patterson
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

This article will show, step by step, how to integrate R code into a R Sweave document
A short article about problems I had with the new location API and permissions in Marshmallow
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now