UNKNOWN
Project description
Dump/restore a whole CouchDB server contents to/from a single tar.gz file.
Useful for making backups, or replicating your database to a secondary test environment.
How it works?
coucharchive spawns a local CouchDB instance locally, using a temporary directory for storing data and configuration.
When dumping, it replicates your source CouchDB server (i.e. replicates all dbs, including _users) to the fresh local one, then saves and compresses its data to a tar.gz archive.
When loading, it uncompresses the archive, has the local CouchDB instance use it as its data, then replicated to your remote CouchDB server.
Examples
Set-up the database server info in config.ini:
[database] url = http://my-server.com:5984 username = root password = p4ss
Dumping database to a file:
./coucharchive.py -c config.ini dump -o /tmp/coucharchive.tar.gz
Restoring database from an archive:
./coucharchive.py -c config.ini load -i /tmp/coucharchive.tar.gz
Go further
For instance, save a backup to S3 and notify somebody via email:
aws s3 cp /tmp/archive.tar.gz s3://my-backups/archive.tar.gz cat >/tmp/email.txt <<EOM Subject: New backup saved on S3
A CouchDB backup called archive.tar.gz was successfully created and pushed on Amazon S3. EOM sendmail user@example.com </tmp/email.txt
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.