× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Thank you Scott,

        I have scrupulously examined all my file and directory open/close sets 
but
until now I had not really considered sockets as a potential player here.  I
shall examine all my socket (I should actually say my use of Your sockets
since I am using your excellent apis) code to see if I might have a logic
hole letting open sockets pile up.  Thanks for the idea!

        I am still on V5R2 as of yet but I will remember the QP0LRRO api.

Regards,

Rick DuVall
Systems Manager
Dealer's Auto Auction of Okc
405 947-2886 Ext:143
rick@xxxxxxxxxx


-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx]On Behalf Of Scott Klement
Sent: Wednesday, November 23, 2005 11:25 AM
To: RPG programming on the AS400 / iSeries
Subject: Re: Too Many Files Open Error


>       Obviously I must be failing to close files somewhere, but I have
> not been able to locate the fault.  It would surely help if I could, at
> failure time, list all the open files giving me a place to look but I
> haven't found anything that would let me do that.

They added an API in V5R3 called Retrieve Referenced Objects (QP0LRRO)
that lists the open files for a given job.

In V5R2 and later, there's an API called QP0LROR that does the opposite,
lists the jobs that have a given file open. That's not what you're looking
for, exactly, but if your software works with a limited set of files, it's
possible that you could use it in a pinch.


> It is barely possible the problem is not in the module I am examining
> (it's a fairly complex process overall).  I would appreciate any
> pointers or suggestions - api's whatever that could help me nail this
> down.  Can you get a list of open ifs files?

Keep in mind that what's really happening is that you're running out of
descriptors.  In spite of the error text that says "too many files open"
descriptors don't HAVE to be files, they can be sockets, pipes, directory
handles, etc.

Aside from the APIs I've already mentioned, the only other thing I can
think of is using journalling to see when things are being opened and
closed. Unfortunately, this'll only track IFS objects. It won't track
sockets or pipes.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.