- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- java error (Too many open files (errno:24))
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-25-2007 09:37 AM
тАО04-25-2007 09:37 AM
java.io.FileNotFoundException:/u08/networks/de01sbr2/niku/clarity/webroot/ui/evolution2/images/WdgError.gif (Too many open files (errno:24))
The above error is from the app-orion.log file. The application we use with Orion is Clarity (Niku). The current band-aid fix is to stop and restart the application daemon. After working with the vendor (Niku Clarity) and looking around on the internet we were told to increase the MAXFILES on the HP-UNIX systems. We increased it from 2048 to 4096. This has not fixed the issue. Now the vendor is telling us that we need to set MAXFILES to unlimited. The HP-UNIX admin said this can not be done. Is this true? I'm not even sure that's the problem. This all started with the DST patch. The java home has been rebuilt and still we have this error. Is it possible that the java is not тАЬreleasingтАЭ file descriptors? Has anyone else seen this error?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-25-2007 09:39 AM
тАО04-25-2007 09:39 AM
Re: java error (Too many open files (errno:24))
$ uname -a
HP-UX de01sbr1 B.11.11 U 9000/800 2917260238 unlimited-user license
$ ulimit -a
time(seconds) unlimited
file(blocks) unlimited
data(kbytes) 3802048
stack(kbytes) 392192
memory(kbytes) unlimited
coredump(blocks) 4194303
nofiles(descriptors) 4096
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-25-2007 09:50 AM
тАО04-25-2007 09:50 AM
Re: java error (Too many open files (errno:24))
ulimit -nS # soft
ulimit -nH # hard
you can't set this to unlimited but it can be increased well above your current value although nfile (the system-wide limit) will probably also need to be increased. One way to tell if files are being closed and file descriptors are being re-used is to run tusc against the executable. The open system call returns the current file descriptor. If a close is done then an open should return the lowest available file descriptor. If your file descriptors simply increase without ever reusing lower number then you have an application problem.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-25-2007 10:03 AM
тАО04-25-2007 10:03 AM
Re: java error (Too many open files (errno:24))
1. Inform the sysadmin how many files will be needed, especially when more than a few dozen files will be opened.
2. If the limit is reached (errno 24) then the program will report the current number that are open and the desired additional files that are needed.
3. If the files include network ports, these numbers will also be reported.
4. The program will call setrlimit to increase the current value of MAXFILES.
Most likely few if any of the above design features were included in your programs. Notice that I said that the program can increase MAXFILES? The setrlimit system call should always be used by such programs. Sure, you could set MAXFILES to 4096 or even 195,000 or some other ridiculous number but that parameter is system-wide. Now every user on the system can write a 20 line C program and open all the file descriptors available on your system (the NFILE kernel parameter) and dent root the ability to login.
That's why there are two paramaters: MAXFILES, which every user gets, and MAXFILES_LIM which is the hard limit for all processes. MAXFILES is usually set to 100 or 200 and MAXFILES_LIM set to a reasonably large number. Then problem programs are limited but properly written prgrams can increase their limit as required.
In case you program(s) do not use setrlimit, you can add a wrapper script around the program to use ulimit to adjust the MAXFILES value on behalf of the program. The admin is correct: there is no kernel parameter unlimited for the file descriptor count. You can raise it with ulimit -n but only to MAXFILES_LIM.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-25-2007 10:05 AM
тАО04-25-2007 10:05 AM
Re: java error (Too many open files (errno:24))
I can't find either on the box. I will have to ask the admin to install one.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-25-2007 10:09 AM
тАО04-25-2007 10:09 AM
Solutionhttp://hpux.its.tudelft.nl/hppd/cgi-bin/search?package=on&description=on&term=lsof
http://hpux.its.tudelft.nl/hppd/hpux/Sysadmin/tusc-7.8/
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-25-2007 12:55 PM
тАО04-25-2007 12:55 PM
Re: java error (Too many open files (errno:24))
http://www.hp.com/products1/unix/java/?jumpid=go/java
Definitely look at the measurement and optimization tools. Also check that the code is not in runaway mode with thousands of threads.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-02-2007 04:27 AM
тАО05-02-2007 04:27 AM
Re: java error (Too many open files (errno:24))
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-02-2007 04:45 AM
тАО05-02-2007 04:45 AM
Re: java error (Too many open files (errno:24))
I saw this behaviour some time ago at Solaris and it was the application, which did not release filehandles correctly.
mfG Peter
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-02-2007 01:48 PM
тАО05-02-2007 01:48 PM
Re: java error (Too many open files (errno:24))
http://www.hp.com/go/java
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-02-2007 08:19 PM
тАО05-02-2007 08:19 PM
Re: java error (Too many open files (errno:24))
A Java software component named something like "projmgr" is using several .properties files, probably for localization or language selection.
The trouble is, instead of reading the properties files once while the application is deployed or when the application server (Weblogic?) is started up so that each projmgr thread will use the same properties, each thread will read the .properties files independently. If the content of those .properties files does not change very often, this is wasteful and just silly.
If the developer of the projmgr component is competent with Java application servers, he/she is likely to have a major "duh" moment when seeing that attachment of yours.
If that does not happen, the developer might need to increase his/her knowledge about the handling of "properties". The Java language and the Weblogic server both have built-in means to handle cases like this in a sensible way: they just need to be used correctly by the application code. If you need to be able to make any changes the properties files take effect while the program is running, that can apparently be arranged too. So there is no need to re-invent this particular wheel.
(I'm not a Java programmer, but we had a similar problem once...)
MK
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2007 09:38 AM
тАО05-14-2007 09:38 AM
Re: java error (Too many open files (errno:24))
You guys were quick and knowledgeable!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2007 09:40 AM
тАО05-14-2007 09:40 AM
Re: java error (Too many open files (errno:24))
You guys were quick and knowledgeable!