You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2020/10/28 10:13:40 UTC

[Bug 64857] New: Too many open files on TLD and JSP

https://bz.apache.org/bugzilla/show_bug.cgi?id=64857

            Bug ID: 64857
           Summary: Too many open files on TLD and JSP
           Product: Tomcat 8
           Version: 8.5.x-trunk
          Hardware: Other
                OS: Linux
            Status: NEW
          Severity: critical
          Priority: P2
         Component: Catalina
          Assignee: dev@tomcat.apache.org
          Reporter: simone.lucidi@eng.it
  Target Milestone: ----

Created attachment 37537
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=37537&action=edit
lsof output

Hi everyone, in the production environment we're having some issues with the
error "Too many open files".
We executed the lsof command to check if there were some files that we opened
and forget to close. 

But apparently, the 80% of files open are jsp and TLD files (see the file in
attach). So I would say they have been opened by tomcat itself to deal with
normal HTTP requests. But the weird thing is that some files have been opened
several times and the user's activities were quite low at that moment (like 15
users connected).

Are you aware of some bugs or some settings that can fix this problem? In the
meanwhile, we increased the Operating System limit for allowed open file, but
this seems just to postpone the error (eventually we always reach the "too many
open files")

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 64857] Too many open files on TLD and JSP

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=64857

Simone <si...@eng.it> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|8.5.x-trunk                 |8.5.59

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 64857] Too many open files on TLD and JSP

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=64857

Simone <si...@eng.it> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW

--- Comment #3 from Simone <si...@eng.it> ---
Hi Mark,

First of all, thanks for your reply. I'll try to create a test case. In the
meanwhile, we used this tool to debug the list of open file:
https://file-leak-detector.kohsuke.org/

And indeed it confirms that some file stays open indefinitely. The weird thing
is that all the open files have been opened with this
"CachedResourceURLConnection", and that didn't happen in the older version of
tomcat (8.0.x) Does it ring any bells? thank you! 


#7265
/home/tomcat/tomcat_app2/webapps/cupwebrc##202010271245/WEB-INF/PSGTagLibraryForms.tld
by thread:ajp-nio-8010-exec-8 on Fri Nov 13 10:14:01 CET 2020
        at java.io.FileInputStream.<init>(FileInputStream.java:139)
        at java.io.FileInputStream.<init>(FileInputStream.java:93)
        at
sun.net.www.protocol.file.FileURLConnection.connect(FileURLConnection.java:90)
        at
org.apache.catalina.webresources.CachedResource$CachedResourceURLConnection.connect(CachedResource.java:451)
        at
org.apache.catalina.webresources.CachedResource$CachedResourceURLConnection.getInputStream(CachedResource.java:458)
        at org.apache.jasper.compiler.Compiler.isOutDated(Compiler.java:529)
        at org.apache.jasper.compiler.Compiler.isOutDated(Compiler.java:430)
        at
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:590)
        at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:399)

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 64857] Too many open files on TLD and JSP

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=64857

Simone <si...@eng.it> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|8.5.59                      |8.5.49

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 64857] Too many open files on TLD and JSP

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=64857

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |DUPLICATE
             Status|NEW                         |RESOLVED

--- Comment #4 from Mark Thomas <ma...@apache.org> ---


*** This bug has been marked as a duplicate of bug 63983 ***

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 64857] Too many open files on TLD and JSP

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=64857

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|critical                    |normal
             Status|NEW                         |NEEDINFO

--- Comment #1 from Mark Thomas <ma...@apache.org> ---
I don;t see this behaviour on a clean Tomcat 8.5.x install with the JSPs and
TLDs from the example web application.

Please provide the simplest possible test case (I'm expecting a single JSP or
possibly a JSP + tag + TLD) that demonstrates this issue.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 64857] Too many open files on TLD and JSP

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=64857

--- Comment #2 from Simone <si...@eng.it> ---
Created attachment 37564
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=37564&action=edit
Stack trace of open files

Output of "File Leak Detector"

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 64857] Too many open files on TLD and JSP

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=64857

--- Comment #5 from Mark Thomas <ma...@apache.org> ---
As soon as the version number was updated, it was obvious this was a duplicate.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org