cbflushctl does not work
I'm trying to use cbflushctl with 1.8.0
trying to stop persistence with
/opt/couchbase/bin/cbflushctl localhost:11210 stop
I get
# /opt/couchbase/bin/cbflushctl localhost:11210 start
Traceback (most recent call last):
File "/opt/couchbase/lib/python/cbflushctl", line 87, in ?
c.execute()
File "/opt/couchbase/lib/python/clitool.py", line 43, in execute
f[0](mc, *args[2:], **opts.__dict__)
File "/opt/couchbase/lib/python/cbflushctl", line 38, in start
mc.start_persistence()
File "/opt/couchbase/lib/python/mc_bin_client.py", line 210, in start_persistence
return self._doCmd(memcacheConstants.CMD_START_PERSISTENCE, '', '')
File "/opt/couchbase/lib/python/mc_bin_client.py", line 104, in _doCmd
return self._handleSingleResponse(opaque)
File "/opt/couchbase/lib/python/mc_bin_client.py", line 97, in _handleSingleResponse
cmd, opaque, cas, keylen, extralen, data = self._handleKeyedResponse(myopaque)
File "/opt/couchbase/lib/python/mc_bin_client.py", line 89, in _handleKeyedResponse
cmd, errcode, opaque, cas, keylen, extralen, rv = self._recvMsg()
File "/opt/couchbase/lib/python/mc_bin_client.py", line 71, in _recvMsg
raise exceptions.EOFError("Got empty data (remote died?).")
EOFError: Got empty data (remote died?).
#
And then I try to connect to specific bucket directly with
/opt/couchbase/bin/cbflushctl localhost:11311 stop
it send a command to the socket and then blocks on recv call.
Also do the stop/start/drain commands are cluster wide or just per node?
and are they affect all buckets or just per bucket, or both?
Thanks
Alex
Correct, sorry for the lack of error handling there. Also, keep in mind most of these tuneables must be re-applied after a server restart. We'll get that fixed. Filed http://www.couchbase.com/issues/browse/MB-5984
BTW is there way to disable persistence altogether? So that disk queue does not grow infinitely (and cause OOM eventually?). I mean use couchbase just like memcached but with all it's clustering and rebalance features?
AFAIU the "memcached" bucket which can be configured in couchcbase is just a plain memcached without the vbucket clustering features?
Sorry, I should have asked what you were trying to do.
There is not a way to do what you're looking for. The Couchbase bucket type always has persistence in addition to it's replication and rebalancing capabilities. There is no Couchbase bucket type which will LRU when you're out of space.
That said, memcached bucket types with Couchbase client libraries do give you the ability to easily add/remove nodes with ketama hashing. What this means, for example, is if you were to go from a 4 node cluster to a 5 node cluster you would only have to rematerialize about 20% of your cache and you'd still have all of the Web Console GUI features.
What I'm actually trying to do is to stop persistence temporarily on all cluster nodes , so that I could take more consistent and point in time cluster wide snapshot of the cluster, based on ec2 EBS snapshots.
Regarding non persistent bucket , i just wanted to 100% verify it's not possible with couchbase.
Thanks
ok I figured out that i need to specify the bucketname
/opt/couchbase/bin/cbflushctl 127.0.0.1:11210 command bucketname
and that stop/start commands affect only a specific node persistence and are not clusterwide