couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Damien Katz <>
Subject Re: Recovering from failed compaction due to lack of disk space.
Date Wed, 23 Jun 2010 17:23:17 GMT
This is bug, please report it to jira. It should be pretty easy to fix, if there is no valid
header, delete the file.

In the meantime, just manually delete the db.compact file.


On Jun 23, 2010, at 9:23 AM, Robert Newson wrote:

> Couchdb can make a .compact file when the volume is almost out of disk
> space and then crash before writing the header.
> If you then clean some space and try to compact again, it won't ever work.
> [Wed, 23 Jun 2010 16:11:59 GMT] [error] [emulator] Error in process
> <0.1976.0> with exit value:
> {{badmatch,no_valid_header},[{couch_db_updater,start_copy_compact,1}]}
> The presence of the invalid .compact file prevents it, and needs to be
> manually removed.
> I think couchdb should handle this but it's clearly a dangerous area
> to play with. My suggestion is to change the bit of code that tests
> for the .compact file's presence to also verify that it's not 0 bytes
> in length (and delete the file if it is). Is that dangerous? Should it
> cover other similar cases?
> B.

View raw message