On 3/20/2021 1:04 AM, jay harkhani wrote:
Hello,

We are using Solr 6.1.0. We have 2 shards and each has one replica with 7 
zookeepers in our live environment.

So you've got it running SolrCloud mode (with ZooKeeper)?

Our Solr URL is
http://solr2.xyz.com:8983/solr/actionscomments/select?q=+resource_id:(123)+and+entity_type:(4)++action_status:(0)++is_active:(true)+and+recipient_id:(5941841)&sort=action_date+desc,id+desc&start=0&rows=1000&fq=&fl=action_id&indent=off&shards.tolerant=true&shards=s3.xyz.com:8983/solr/actionscomments|s3r1.xyz.com:8983/solr/actionscomments,s4.xyz.com:8983/solr/actionscomments|s4r1.xyz.com:8983/solr/actionscomments

I would like to understand correct configuration for use of LB and shards 
parameters in URL. Above URL we use for search in collection.

1) In current configuration base URL (https://solr2.xyz.com) is of LB which point to 
IPs of shards (Shard1 & Shard2) and replicas (replica1 & replica2). Is it 
correct? or instead provide IP of shard be more effective?

2) What is importance of shards parameters? What should we use LB URL or direct 
IP of shards and replicas?

If you want Solr to do load balancing automatically across all servers containing parts of that collection, you should completely remove the shards parameter. It is not necessary and probably prevents load balancing from working.

If you're talking about using your own load balancer, I would still remove the shards parameter. Solr will automatically figure out where every shard replica is when you query the collection.

Thanks,
Shawn

Reply via email to