You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Salman Akram <sa...@northbaysolutions.net> on 2014/01/21 06:37:15 UTC
Optimizing index on Slave
All,
I know normally index should be optimized on master and it will be
replicated to slave but we have an issue with the network bandwidth.
We optimize indexes weekly (total size is around 1.5TB). We have few slaves
set up on local network so replication the whole indexes is not a big
issue.
However, we have one slave in another city too (on a backup network) which
of course gets replicated over internet which is quite slow and expensive.
We want to avoid copying the complete indexes every week after optimization
and were thinking if its possible to optimize it independently on slave so
that there is no delta between master and slave? We tried to do it but
still the slave replicated from master.
--
Regards,
Salman Akram
Re: Optimizing index on Slave
Posted by Michael Della Bitta <mi...@appinions.com>.
I'm not really aware enough of the Solr/Lucene internals to tell you
whether that's possible or not.
One thing occurred to me: What happens if you take optimize out of the
replication triggers in the replication handler?
<str name="replicateAfter">optimize</str>
Michael Della Bitta
Applications Developer
o: +1 646 532 3062
appinions inc.
“The Science of Influence Marketing”
18 East 41st Street
New York, NY 10017
t: @appinions <https://twitter.com/Appinions> | g+:
plus.google.com/appinions<https://plus.google.com/u/0/b/112002776285509593336/112002776285509593336/posts>
w: appinions.com <http://www.appinions.com/>
On Thu, Jan 23, 2014 at 12:36 AM, Salman Akram <
salman.akram@northbaysolutions.net> wrote:
> Unfortunately we can't do sharding right now.
>
> If we optimize on master and slave separately the file names and sizes are
> same. I think it's just the version no that is different. Maybe if there
> was a to copy master version to slave that would resolve this issue?
>
Re: Optimizing index on Slave
Posted by Salman Akram <sa...@northbaysolutions.net>.
Unfortunately we can't do sharding right now.
If we optimize on master and slave separately the file names and sizes are
same. I think it's just the version no that is different. Maybe if there
was a to copy master version to slave that would resolve this issue?
Re: Optimizing index on Slave
Posted by Michael Della Bitta <mi...@appinions.com>.
Salman,
To my knowledge, there's not a great way of doing this.
Perhaps if your dataset were based on a time series, you could shard by
date, and then only a smaller segment of your data would be updated and
therefore need to be sent each week?
Michael Della Bitta
Applications Developer
o: +1 646 532 3062
appinions inc.
“The Science of Influence Marketing”
18 East 41st Street
New York, NY 10017
t: @appinions <https://twitter.com/Appinions> | g+:
plus.google.com/appinions<https://plus.google.com/u/0/b/112002776285509593336/112002776285509593336/posts>
w: appinions.com <http://www.appinions.com/>
On Wed, Jan 22, 2014 at 4:48 AM, Salman Akram <
salman.akram@northbaysolutions.net> wrote:
> We do. We have a lot of updates/deletes every day and a weekly optimization
> definitely gives a considerable improvement so don't see a downside to it
> except the complete replication part which is not an issue on local
> network.
>
Re: Optimizing index on Slave
Posted by Salman Akram <sa...@northbaysolutions.net>.
We do. We have a lot of updates/deletes every day and a weekly optimization
definitely gives a considerable improvement so don't see a downside to it
except the complete replication part which is not an issue on local
network.
Re: Optimizing index on Slave
Posted by Michael Della Bitta <mi...@appinions.com>.
Taking a step back: Are you sure you need to optimize? It might be hurting
you more than it helps.
Michael Della Bitta
Applications Developer
o: +1 646 532 3062
appinions inc.
“The Science of Influence Marketing”
18 East 41st Street
New York, NY 10017
t: @appinions <https://twitter.com/Appinions> | g+:
plus.google.com/appinions<https://plus.google.com/u/0/b/112002776285509593336/112002776285509593336/posts>
w: appinions.com <http://www.appinions.com/>
On Tue, Jan 21, 2014 at 12:37 AM, Salman Akram <
salman.akram@northbaysolutions.net> wrote:
> All,
>
> I know normally index should be optimized on master and it will be
> replicated to slave but we have an issue with the network bandwidth.
>
> We optimize indexes weekly (total size is around 1.5TB). We have few slaves
> set up on local network so replication the whole indexes is not a big
> issue.
>
> However, we have one slave in another city too (on a backup network) which
> of course gets replicated over internet which is quite slow and expensive.
> We want to avoid copying the complete indexes every week after optimization
> and were thinking if its possible to optimize it independently on slave so
> that there is no delta between master and slave? We tried to do it but
> still the slave replicated from master.
>
>
> --
> Regards,
>
> Salman Akram
>