If you open many HTTP connections during the same time in your service in Tomcat, you will probably get such exception: Socket accept failed java.io.IOException: Too many open files.
How to fix:
add this line:
ulimit -n 8192
ulimit -n //this will set unlimit
then restart tomcat and start with 'catalina start', Java will run with the given limit above.