You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@couchdb.apache.org by Cory Zue <cz...@dimagi.com> on 2011/04/03 16:18:10 UTC

couch restart triggers view rebuild

We have deployed couch in an environment that requires daily shutdowns of
the machine, which means couch is also restarting frequently. What we are
observing is that couch seems to need to reindex our views every time it
restarts itself. This is not the case for all design docs, but is for some
of them (and frequently, it seems, the larger ones). Looking at the log
file, couch seems to be reindexing/checkpointing these design docs from the
very beginning. As our databases grow, this has become a larger and larger
issue as the reindexing can churn for almost 30 minutes before the system
becomes usable. Once the indices are built everything is fine until couch
shuts down again.

How can we prevent this from happening?

We are running couch 1.0.0 with delayed_commits=false on Ubuntu 10.04. Our
hardware is a fit-PC2.

thanks,
Cory

Re: couch restart triggers view rebuild

Posted by Cory Zue <cz...@dimagi.com>.
Update on this issue of view rebuilds.

I was able to reliably reproduce this issue on 1.0.1 and 1.0.2.
Ultimately, the answer here seemed to be to write a view that reduces
more quickly. I understand that this is appropriate with couch
best-practices, but it still strikes me as a bug that a poorly
reducing view would not be able to have it's indices stored across
couchdb restarts.

On Sun, Apr 3, 2011 at 4:18 PM, Cory Zue <cz...@dimagi.com> wrote:
> We have deployed couch in an environment that requires daily shutdowns of
> the machine, which means couch is also restarting frequently. What we are
> observing is that couch seems to need to reindex our views every time it
> restarts itself. This is not the case for all design docs, but is for some
> of them (and frequently, it seems, the larger ones). Looking at the log
> file, couch seems to be reindexing/checkpointing these design docs from the
> very beginning. As our databases grow, this has become a larger and larger
> issue as the reindexing can churn for almost 30 minutes before the system
> becomes usable. Once the indices are built everything is fine until couch
> shuts down again.
> How can we prevent this from happening?
> We are running couch 1.0.0 with delayed_commits=false on Ubuntu 10.04. Our
> hardware is a fit-PC2.
>
> thanks,
> Cory
>