Recovering data
Hi,
I'm trying to recover the Couchbase data from the database files of a 2.0 dev preview 3 Couchbase instance (on an OpenVZ VPS server running Debian 6) that can no longer be started.
I've tried using cbbackup, but that fails, saying that it cannot recognize the database files. This may not be indicative of anything, though, as from tests on newly-created databases on clean installations, cbbackup still fails with the same error on all the OpenVZ instances I've tried.
I've tried copying the database and install files to a different server, running the executables / installing the software on top of the existing files, and that never resulted in success.
Are there other ways to extract the data?
Thanks.
@finger is correct, cbbackup hadn't been updated up through DP4, but IS updated in Couchbase 2.0 "recent builds" (which are newer than DP4), (www.couchbase.com/downloads-all and scroll down a little past the DP4 block). If you upgrade to recent build you can use cbbackup.
As you know everything is still in development and in pre-beta, so you could run into issues, and if you do please tell us! We will be moving to nightly builds fairly soon.
As you know everything is still in development and in pre-beta, so you could run into issues, and if you do please tell us! We will be moving to nightly builds fairly soon.
Hello,
at first thanks for your response!
So I've just downloaded and installed 1482 for OSX ... the option to have the binaries linked into ~/bin (and other locations) is quite nice, but unfortunately the files refer to ../lib/ which cannot work.
$ cbbackup
/Users/finger/bin/cbbackup: line 20: /Users/finger/bin/../lib/python/cbbackup: No such file or directory
/Users/finger/bin/cbbackup: line 20: exec: /Users/finger/bin/../lib/python/cbbackup: cannot execute: No such file or directory
I would suggest something like this:
export PATH=$PATH:/Applications/Couchbase\ Server.app/Contents/Resources/couchbase-core/bin
but... after that I've got a new error:
Traceback (most recent call last):
File "/Applications/Couchbase Server.app/Contents/Resources/couchbase-core/bin/../lib/python/cbbackup", line 8, in
import pump_transfer
File "/Applications/Couchbase Server.app/Contents/Resources/couchbase-core/lib/python/pump_transfer.py", line 12, in
import pump_csv
ImportError: No module named pump_csv
So I switched to Linux...
... installed couchbase-server-community_x86_64_2.0.0-1482-rel.deb
$ /opt/couchbase/bin/cbbackup
Traceback (most recent call last):
File "/opt/couchbase/lib/python/cbbackup", line 8, in
import pump_transfer
File "/opt/couchbase/lib/python/pump_transfer.py", line 12, in
import pump_csv
ImportError: No module named pump_csv
same error.
Hope this helps.
I too got:
Traceback (most recent call last):
File "/opt/couchbase/lib/python/cbbackup", line 8, in <module>
import pump_transfer
File "/opt/couchbase/lib/python/pump_transfer.py", line 12, in <module>
import pump_csv
ImportError: No module named pump_csv(Ubuntu 12 on Xen)
we wrote our own script.
https://github.com/Crowdpark/crwd-tools/tree/master/scripts/backup-couch...
but maybe they fixed it.
I wasn't able to use cbbackup on Linux and OSX. Always under the same user which is running the couchbase process(es).
Because all questions I found regarding cbbackup were never answered I assume there is no working backup tool at the moment, is this right?
The output of cbbackup looks also as if the tool was not rewritten for 2.0 dp x at all.
So I am thinking about shutting down the couchbase service, creating an archive of var/lib content... any other suggestions?