Compaction crashes without even starting

Hello community,

I’ve been lurking and looking for answers for a long time on this but I’ve had no luck. I finally created an account on the forums so maybe you can give me a hand with this problem.

I have a Couchbase cluster that consists in only 1 node. 128GB RAM, 8 cores, running Couchbase version 2.1.0-718-rel. I have 4 buckets, the biggest and most important one (in size) has 5.5M documents, has 18GB of data and the data occupies 350GB on disk (a lot, this is a consequence of compaction not working).

The problem arises when the compaction triggers by itself or when I trigger it manually. It doesn’t matter, it always aborts and I see this trace in the log file, always:

[error_logger:error,2014-02-25T13:47:54.326,ns_1@127.0.0.1:error_logger<0.6.0>:ale_error_logger_handler:log_msg:76]Error in process <0.16836.295> on node 'ns_1@127.0.0.1' with exit value: {{badmatch,5440},[{couch_db_updater,copy_compact,3},{couch_db_updater,start_copy_compact,2}]}

[error_logger:error,2014-02-25T13:47:54.327,ns_1@127.0.0.1:error_logger<0.6.0>:ale_error_logger_handler:log_report:72]
=========================CRASH REPORT=========================
crasher:
initial call: compaction_daemon:-spawn_vbucket_compactor/5-fun-0-/0
pid: <0.16835.295>
registered_name: []
exception exit: {{badmatch,5440},
[{couch_db_updater,copy_compact,3},
{couch_db_updater,start_copy_compact,2}]}
in function compaction_daemon:’-spawn_vbucket_compactor/5-fun-0-’/7
ancestors: [<0.16823.295>,<0.16821.295>,<0.16820.295>,compaction_daemon,
ns_server_sup,ns_server_cluster_sup,<0.58.0>]
messages: []
links: [<0.16823.295>]
dictionary: []
trap_exit: true
status: running
heap_size: 1597
stack_size: 24
reductions: 1400
neighbours:

Any idea why this is happening? I’m used to trace errors but this is giving me zero information about the reason or what can I do to fix it.

As of right now, the compaction is not working on my cluster because of this problem.

I would appreciate any kind of help or light in the issue.

Thank you very much!
Jose

How big is your hard drive? I’m going to guess that is your problem. If you see in the documentation that compaction copies your current data set to perform compaction. See here http://docs.couchbase.com/couchbase-manual-2.2/#database-and-view-compaction

So you are going to need at least a 1tb to perform compaction now if that is the case.