lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shawn Heisey <>
Subject Re: Access Solr via Apache's mod_proxy_balancer or mod_jk (AJP)
Date Wed, 06 Jul 2016 13:39:26 GMT
On 7/4/2016 9:53 AM, Shawn Heisey wrote:
> On 7/4/2016 3:54 AM, Andreas Kahl wrote:
>> Hello everyone, we've setup two Solr servers (not SolrCloud) which
>> shall be accessed via Apache webserver's load balancing (either
>> mod_proxy_balancer or mod_jk). 1. Is it possible to configure Solr >5
>> to enable an AJP port as this was the case in earlier versions when
>> running in Tomcat? 2. If AJP/mod_jk is not possible, how should I set
>> up mod_proxy_balancer? At the moment I run into the error "All
>> workers are in error state". This is my current Apache config: <Proxy
>> balancer://solrCluster> BalancerMember http://server1:8888
>> BalancerMember http://server2:8888 </Proxy> ProxyPass /solrCluster
>> balancer://solrCluster/solr ProxyPassReverse /solrCluster
>> balancer://solrCluster/solr Accessing a single server with a non
>> balanced ReverseProxy works perfectly, but somehow
>> mod_proxy_balancer's health checks do get negative responses from
>> Solr. Any ideas what's going wrong? (I already tried putting /solr
>> into the BalancerMembers to avoid the redirect from / to /solr) 
> The eclipse wiki is down, but in the Google search results that link
> to the wiki I can see the text "Using Apache mod_jk and the /Jetty
> AJP/ connector. We recommend using the HTTP connectors for the
> following reasons: Jetty performs ..." So for some reason I can't see
> at the moment, the Jetty authors don't recommend AJP, even though it
> apparently can do it. You can likely get the AJP module working in the
> Jetty that Solr includes, but doing so is outside the scope of this
> mailing list.


They recommend not doing it because performance with http is better, and
because support for AJP has been dropped from Jetty 9.  Solr 5.0 and
later uses Jetty 9.  So I was incorrect when I said that you can
probably get it working with Solr.

I personally would recommend using haproxy as a load balancer for Solr. 
I am doing this, and it works very well.  If you need encryption between
Solr and its clients for some reason, setting up TLS on haproxy is also
a lot easier than with Java.


View raw message