Thanks for the reply. Actually, I don't want to change the IP of the replica 
but I want to create a collection on a specific shard IP.
As per my production server configuration, we consider 10.38.33.28 is shard1, 
10.38.33.30 is shard2,  10.38.33.31 is replica of shard1 and 10.38.33.29 is 
replica of shard2.
We need to create all new collections the same as above.


When I create a collection(documents) using the admin panel. It created like
shard1 10.38.33.30
       replica1 10.38.33.31
shard2 10.38.33.28
       replica2 10.38.33.29

Actually we want like this
shard1 10.38.33.28
       replica1 10.38.33.31
shard2 10.38.33.30
       replica2 10.38.33.29

Regards,
Vishal
________________________________
From: Sankar Panda <panda.san...@gmail.com>
Sent: Friday, January 3, 2020 12:36 PM
To: solr-user@lucene.apache.org <solr-user@lucene.apache.org>
Subject: Re: Solr 8.3

Hi Vishal,

You can .go to the collection in admin console.mannually changed the ip address 
as you want.Remove the replica and add it as per your requirements.This option 
provides by the solr cloud.
Thanks
Sankar panda

On Fri, Jan 3, 2020, 11:33 vishal patel 
<vishalpatel200...@outlook.com<mailto:vishalpatel200...@outlook.com>> wrote:
I do not want to change the IP of the existing replica. I want to fix the IP 
for the first time creating a collection.

I have 4 machines. my IP of each machine is below
machine1 10.38.33.28
machine2 10.38.33.29
machine3 10.38.33.30
machine4 10.38.33.31

I have created solr instance on each machine. when I am creating a first 
collection(documents) using admin panel my structure becomes like this
shard1 10.38.33.30
       replica1 10.38.33.31
shard2 10.38.33.28
       replica2 10.38.33.29

When creating a second collection(forms), my structure becomes like this
shard1 10.38.33.28
       replica1 10.38.33.30
shard2 10.38.33.29
       replica2 10.38.33.31

I have attached a screenshot. [https://ibb.co/Yb2TpVX]

Randomly IP assigned to shard or replica when creating collection but I want to 
make shard1 on 10.38.33.28, replica1 on 10.38.33.31, shard2 on 10.38.33.30 and 
replica2 on 10.38.33.31 when first time creating a collection using admin panel.

Can I Fix the IP to shard OR replica when creating a new 
[cid:4c560b03-a18d-4bc1-b592-6b2f8103f1ae] collection?

Regards,
Vishal


________________________________
From: Erick Erickson <erickerick...@gmail.com<mailto:erickerick...@gmail.com>>
Sent: Thursday, January 2, 2020 7:40 PM
To: solr-user@lucene.apache.org<mailto:solr-user@lucene.apache.org> 
<solr-user@lucene.apache.org<mailto:solr-user@lucene.apache.org>>
Subject: Re: Solr 8.3

No, you cannot change the IP of an existing replica. Either do as Sankar 
mentioned when you first create the collection or use the MOVREPLICA 
collections API command.

MOVEREPLICA has existed for quite a long time, but if it’s not available, you 
can do the same with the ADDREPLICA command to add a replica to a specific 
node, wait for the replica to become fully active, then use DELETEREPLICA on 
the one you no longer want.

Best,
Erick

> On Jan 2, 2020, at 8:10 AM, Sankar Panda 
> <panda.san...@gmail.com<mailto:panda.san...@gmail.com>> wrote:
>
> Hi Vishal,
> You can create a empty nodeset and manually configure in the collection as
> desired in the admin page
> Thanks
> Sankar Panda
>
> On Thu, Jan 2, 2020, 14:36 vishal patel 
> <vishalpatel200...@outlook.com<mailto:vishalpatel200...@outlook.com>>
> wrote:
>
>> My created collection in solr cloud below
>>
>> 10.38.33.24 is shard and its replica is 10.38.33.27.
>> 10.38.33.227 is shard and its replica is 10.38.33.219.
>>
>> I want to create a new collection on the Same. can not change the shard IP
>> for the new collection. How can I?
>>
>>
>> ------------------------------
>> *From:* sudhir kumar 
>> <gogikarsud...@gmail.com<mailto:gogikarsud...@gmail.com>>
>> *Sent:* Thursday, January 2, 2020 2:01 PM
>> *To:* solr-user@lucene.apache.org<mailto:solr-user@lucene.apache.org> 
>> <solr-user@lucene.apache.org<mailto:solr-user@lucene.apache.org>>
>> *Subject:* Re: Solr 8.3
>>
>> sample url to create collection:
>>
>>
>> http//host:8080/solr/admin/collections?action=CREATE&name=collectionname&numShards=2&replicationFactor=3&maxShardsPerNode=2&createNodeSet=
>> host:8080_solr,host:8080_solr,host:8080_solr,host:8080_solr
>> &collection.configName=collectionconfig
>>
>> On Thu, Jan 2, 2020 at 1:56 PM sudhir kumar 
>> <gogikarsud...@gmail.com<mailto:gogikarsud...@gmail.com>>
>> wrote:
>>
>>> Hey Vishal,
>>>
>>> You can use createNodeSet property while creating collection which will
>>> allows you to create shards on specified IP.
>>>
>>> /admin/collections?action=CREATE&name=*name*&numShards=*number*
>>> &replicationFactor=*number*&*maxShardsPerNode*=*number*&*createNodeSet*=
>>> *nodelist*&collection.configName=*configname*
>>>
>>>
>>> Thanks,
>>>
>>> Sudhir
>>>
>>>
>>> On Thu, Jan 2, 2020 at 1:49 PM vishal patel <
>> vishalpatel200...@outlook.com<mailto:vishalpatel200...@outlook.com>>
>>> wrote:
>>>
>>>> When I am creating 2 shards and 2 replicas using admin panel, automatic
>>>> assign a shard or replica to any IP.
>>>> I want to make the specific shard or replica to solr instance at the
>> time
>>>> of creating a collection. Can I?
>>>>
>>>> Regards,
>>>> Vishal
>>>>
>>>
>>

Reply via email to