网站(Tomcat)超线程宕机

 

网站大中午的又挂了·····

拷了日志如下:

2014-4-12 13:22:30 org.apache.tomcat.util.net.JIoEndpoint createWorkerThread
信息: Maximum number of threads (1000) created for connector with address null a
nd port 80

超线程了?都1000多了,网站很牛叉的感觉,有这么多人中午不睡觉刷网站玩?!

网上查了查,是在tomcat的一个server.xml配置文件里对线程数有配置:

<Connector port="80" protocol="HTTP/1.1" connectionTimeout="20000" redirectPort="8443" maxThreads="1000" acceptCount="800"/>

connectionTimeout网络连接超时限制(毫秒,1000毫秒=1秒),0为无限制;redirectPort服务器的重定向端口;maxThreads最大线程数,目前为1000,于是我改为1200;

acceptCount最大排队数。这一段有待完善······

参考:

http://www.cnblogs.com/baibaluo/archive/2011/08/23/2150305.html

 

 

 

posted @ 2014-04-12 16:39  凤凰骑士  阅读(405)  评论(0编辑  收藏  举报