title: tomcat 7.0.23 cannot establish SSL connection from apache server.
body: <p>Hi i have the following server.xml settings. </p>
  
  <pre><code>Server port="7005" shutdown="SHUTDOWN-TOMCAT-C"&gt;
      &lt;Listener className="org.apache.catalina.core.AprLifecycleListener" SSLEngine="on" /&gt;
      &lt;Listener className="org.apache.catalina.core.JasperListener" /&gt;
      &lt;Listener className="org.apache.catalina.core.JreMemoryLeakPreventionListener" /&gt;
      &lt;Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener" /&gt;
     &lt;Listener className="org.apache.catalina.core.ThreadLocalLeakPreventionListener" /&gt;
  
      &lt;Service name="Catalina"&gt;
          &lt;Connector port="7070" protocol="org.apache.coyote.http11.Http11NioProtocol" 
                     connectionTimeout="20000" 
                     redirectPort="7443" /&gt;
          &lt;Connector port="7443" protocol="org.apache.coyote.http11.Http11NioProtocol" maxThreads="150" 
                     SSLEnabled="true" scheme="https" secure="true" clientAuth="want" sslProtocol="TLS" 
                     keystoreFile="${key.path}\compresskey.bin" keystorePass="${keystorePass}" 
                     compression="on" compressableMimeType="text/html,text/xml,text/plain,text/javascript,text/css"/&gt;
          &lt;Connector port="7009" protocol="org.apache.coyote.ajp.AjpProtocol" redirectPort="7443" enableLookups="false"  /&gt;
  
          &lt;Engine name="Catalina" defaultHost="localhost" jvmRoute="tomcat-c"&gt;
              &lt;Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"
                       channelSendOptions="10"&gt;
                  &lt;Manager className="org.apache.catalina.ha.session.BackupManager"
                         expireSessionsOnShutdown="false"
                         notifyListenersOnReplication="true"
                         mapSendOptions="10"/&gt;
                  &lt;Valve className="org.apache.catalina.ha.tcp.ReplicationValve"
                           filter=".*\.gif;.*\.js;.*\.jpg;.*\.png;.*\.htm;.*\.html;.*\.css;.*\.txt;"/&gt;
                  &lt;ClusterListener className="org.apache.catalina.ha.session.ClusterSessionListener"/&gt;
              &lt;/Cluster&gt;
  
  &lt;Context path="/mvc2_app1"
                        docBase="${user.home}\webapps\mvc2_app1"
                        cookies="true"
                        override="true"
                        reloadable="false"
                        swallowOutput="true"
                        distributable="true"
                        logEffectiveWebXml="true"
                        xmlNamespaceAware="false"
                        xmlValidation="false"
                        className="org.apache.catalina.core.StandardContext"&gt;
  &lt;/context&gt;
  &lt;/service&gt;
  
  &lt;/host&gt;
  </code></pre>
  
  <p>my worker.properties</p>
  
  <pre><code>worker.tomcat-c.port=7009
  worker.tomcat-c.host=localhost
  worker.tomcat-c.type=ajp13
  worker.tomcat-c.lbfactor=1
  </code></pre>
  
  <p>Here is my httpd.conf setting. </p>
  
  <pre><code>&lt;VirtualHost ${host}:443&gt; 
  SSLEngine On ServerName ${host} 
  ErrorLog "logs/error.log" 
  LogLevel warn 
  SSLCertificateFile conf/ssl/server.crt 
  SSLCertificateKeyFile conf/ssl/server.key 
  SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown 
  SSLProxyEngine On 
  ServerAdmin local@admin.com 
  RewriteEngine On 
  
  ProxyPreserveHost On #applications on 5443 
  ProxyPass /mvc2_app1 https://${host}:7443/mvc2_app1 
  
  ProxyPassReverse /mvc2_app1 https://${host}:7443/mvc2_app1 
  &lt;/virtual_host&gt;
  </code></pre>
  
  <p>When i try connecting to <a href="https://localhost/mvc2_app1" rel="nofollow">https://localhost/mvc2_app1</a>, i get an error 500 proxy error. </p>
  
  <p>Here is my error.log
      proxy: Error during SSL Handshake with remote server returned by /mvc2_app1
      proxy: pass request body failed to ${local ip}:7443 (${host}) from ${local ip}</p>
  
  <p>any advice or tips? </p>
  
  <p>Thanks. </p>
  
  <p>-- update -- 
  I can connect to apache server without problem. <a href="https://localhost" rel="nofollow">https://localhost</a> works but <a href="https://localhost/mvc2_app1" rel="nofollow">https://localhost/mvc2_app1</a> does not. </p>
  
  <p>So my tomcat log is this. </p>
  
  <pre><code>Dec 25, 2011 10:21:57 PM org.apache.coyote.AbstractProtocol init
  INFO: Initializing ProtocolHandler ["http-nio-7070"]
  Dec 25, 2011 10:21:57 PM org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
  INFO: Using a shared selector for servlet write/read
  Dec 25, 2011 10:21:57 PM org.apache.coyote.AbstractProtocol init
  INFO: Initializing ProtocolHandler ["http-nio-7443"]
  Dec 25, 2011 10:21:58 PM org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
  INFO: Using a shared selector for servlet write/read
  Dec 25, 2011 10:21:58 PM org.apache.coyote.AbstractProtocol init
  INFO: Initializing ProtocolHandler ["ajp-bio-7009"]
      Dec 25, 2011 10:21:58 PM org.apache.catalina.tribes.membership.McastServiceImpl setupSocket
      INFO: Setting cluster mcast soTimeout to 500
      Dec 25, 2011 10:21:58 PM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers
      INFO: Sleeping for 1000 milliseconds to establish cluster membership, start level:4
      Dec 25, 2011 10:21:59 PM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers
      INFO: Done sleeping, membership established, start level:4
      Dec 25, 2011 10:21:59 PM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers
      INFO: Sleeping for 1000 milliseconds to establish cluster membership, start level:8
      Dec 25, 2011 10:22:00 PM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers
      INFO: Done sleeping, membership established, start level:8
      Dec 25, 2011 10:22:00 PM org.apache.catalina.tribes.tipis.AbstractReplicatedMap init
      INFO: Initializing AbstractReplicatedMap with context name:/mvc2_app1
      Dec 25, 2011 10:22:00 PM org.apache.catalina.tribes.tipis.AbstractReplicatedMap init
      INFO: Initializing AbstractReplicatedMap with context name:/mvc2_app2
  </code></pre>