aspose file tools*
The moose likes I/O and Streams and the fly likes java.io.FileNotFoundException: Too many open files Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » I/O and Streams
Bookmark "java.io.FileNotFoundException: Too many open files" Watch "java.io.FileNotFoundException: Too many open files" New topic
Author

java.io.FileNotFoundException: Too many open files

Farakh khan
Ranch Hand

Joined: Mar 22, 2008
Posts: 732
Hello,

Here is my code to copy file

Error that am facing is:


Thanks in anticipation
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18660
    
    8

As far as I can see, the code that you posted doesn't have anything to do with your error message. Here's the relevant part of the stack trace:



Notice that the classes and mentioned in that stack trace are not in the code which you posted.
Farakh khan
Ranch Hand

Joined: Mar 22, 2008
Posts: 732
Thanks Paul Clapham for your favorable reply. Actually the referred classes are using this copy method and exist in the class from where this copyFile method called

I googled and found this problem not belongs to my code but appearing due to Linux as permission to view number of files were 1024 whereas I was trying to copy 50500 files. I used the following to fix it:


Increase open files and max user processes:


Presently it seems the problem fixed but am still waiting to be sure 100%

Thanks again
 
 
subject: java.io.FileNotFoundException: Too many open files