On 5/23/2014 8:09 AM, pradeepgm wrote:
Attached all files here.  Just masked the customer domain.
conf-files.zip
<http://tomcat.10.x6.nabble.com/file/n5017851/conf-files.zip>

Please note that we have multiple tomcat instances supported by one
common apache httpd server. I just added the one (Tomcat 7) which is
having this issue (server hung). All remaining tomcat's are running
on Tomcat 6 version.

Pradeep GM

Pradeep,

In general, it's not a good idea to reference a zip file. Post information inline without comments, and with sensitive information obscured (not removed - since that can alter the configuration meaning).

I'm posting the relevant portions of the configuration inline, since I don't think it's fair for future readers to have to find zip files and unzip them.

#
# workers.properties - in toto
#
worker.list=jkstatus,externalLB

worker.externalstg1.port=9011
worker.externalstg1.host=10.181.42.51
worker.externalstg1.type=ajp13
worker.externalstg1.connect_timeout=15000
worker.externalstg1.prepost_timeout=5000
worker.externalstg1.socket_timeout=60
worker.externalstg1.connection_pool_timeout=0

worker.externalstg2.port=9011
worker.externalstg2.host=10.181.42.52
worker.externalstg2.type=ajp13
worker.externalstg2.connect_timeout=15000
worker.externalstg2.prepost_timeout=5000
worker.externalstg2.socket_timeout=60
worker.externalstg2.connection_pool_timeout=0

worker.externalLB.type=lb
worker.externalLB.balance_workers=externalstg1,externalstg2
worker.externalLB.sticky_session=1
worker.externalLB.session_cookie=JSESSIONID
worker.externalLB.session_path=;xyz

worker.jkstatus.type=status

<!-- most of server.xml - didn't post the listeners -->
    <Connector port="9001"
               protocol="org.apache.coyote.http11.Http11NioProtocol"
               address="10.181.42.52"
               redirectPort="443"
               URIEncoding="UTF-8"
               connectionTimeout="20000"
               maxHttpHeaderSize="12392"
               maxThreads="40"
               scheme="http"
               proxyName=""
               proxyPort=""
               secure="false" />

    <Connector port="9011"
               address="10.181.42.52"
               redirectPort="443"
               enableLookups="false"
               protocol="AJP/1.3"
               URIEncoding="UTF-8"
               tomcatAuthentication="false"
               maxPostSize="0"
               bufferSize="4096"
               maxThreads="250"
               scheme="https"
               proxyPort="443"
               proxyName="test.community.xxxx.com"
               secure="true"
               maxConnections="245"/>

    <Connector port="9002"
               protocol="org.apache.coyote.http11.Http11NioProtocol"
               address="10.181.42.52"
               redirectPort="443"
               URIEncoding="UTF-8"
               connectionTimeout="20000"
               maxThreads="40"
               scheme="http"
               proxyName=""
               proxyPort="9002"
               secure="false" />

    <Engine name="Catalina" jvmRoute="externalstg2"
            defaultHost="localhost">
      <Host name="localhost"  appBase="" createDirs="false"
            unpackWARs="false" autoDeploy="false"
            deployOnStartup="false">
        <Context path="/"
            antiJARLocking="false" antiResourceLocking="false"
            docBase="/usr/local/jive/applications/external/application"
            workDir="/usr/local/jive/var/work/hexternal "
            reloadable="false" unpackWAR="false"
            swallowOutput="false">
            <Environment name="jive.instance.home"
                value="/usr/local/jive/applications/external/home"
                type="java.lang.String"/>
             <Valve
                className="org.apache.catalina.valves.RemoteIpValve"
                internalProxies="127\.0\.0\.1" />
        </Context>
      </Host>
    </Engine>
#
# mod-jk.conf
#
LoadModule jk_module modules/mod_jk.so
JkWorkersFile conf/workers.properties
JkLogLevel error
JkLogStampFormat  "[%a %b %d %H:%M:%S %Y]"
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
JkRequestLogFormat "%U %w %V %q %T"

#
# portions of httpd.conf
#
<IfModule prefork.c>
StartServers            8
MinSpareServers         5
MaxSpareServers        20
ServerLimit          1536
MaxClients           1536
MaxRequestsPerChild  4000
</IfModule>


#
# external-test.conf - hopefully it's in /etc/httpd/conf.d
#
<VirtualHost 10.181.30.46:80>
    ServerName test.community.xxxx.com

    Options -Indexes
    RewriteEngine on
    RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
    RewriteRule .* - [F]
    RewriteCond %{REQUEST_URI} /etc/passwd$
    RewriteRule .* - [F]


UseCanonicalName on
ProxyRequests off
ProxyPreserveHost On

ProxyPass /server-status !
ProxyPass /server-info !
ProxyPass /jkmanager/ !
JKMount / ricohexternalLB
JKMount /* ricohexternalLB


KeepAliveTimeout 2

Include conf/jive-cache.conf

Header append Vary User-Agent
<Location />
AddOutputFilterByType INCLUDES;DEFLATE text/html text/plain text/css text/javascript application/x-javascript application/xml
        SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png)$ no-gzip dont-vary
        SetEnvIfNoCase Request_URI \.pdf$ no-gzip dont-vary
SetEnvIfNoCase Request_URI \.(?:exe|t?gz|zip|bz2|sit|rar)$ no-gzip dont-vary

        BrowserMatch ^Mozilla/4 gzip-only-text/html
        BrowserMatch ^Mozilla/4\.0[678] no-gzip
        BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
        BrowserMatch "MSIE 6"  no-gzip dont-vary
</Location>

</VirtualHost>

If I've left out salient portions of httpd.conf, I apologize. mod_proxy, mod_proxy_httpd, mod_proxy_ftp, and mod_dav are all in use. mod_proxy_ajp is not (since mod_ajp is).

I suggest that you read very carefully the following:

http://tomcat.apache.org/connectors-doc/generic_howto/timeouts.html
http://tomcat.apache.org/connectors-doc/reference/workers.html
http://tomcat.apache.org/tomcat-7.0-doc/config/ajp.html

Also, read the example workers.properties file found in the conf directory of the source distribution for the Tomcat connectors.

In particular, start with the documentation concerning connection_pool_timeout.

There are other settings here that are either not used (because you haven't set the directive the settings alter), or don't exist.

In httpd.conf, you have:

ServerLimit      1536
MaxClients       1536

This seems to be a bit excessive.

There is a lot more, however this should give you enough to get started.

. . . . just my two cents
/mde/

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to