Skip to content

This repository consists of scripts which can help migrating data from your couchdb databases to mongodb collections

Notifications You must be signed in to change notification settings

jimishio/couchdb-to-mongodb

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

couchdb-to-mongodb

This repository consists of scripts which can help migrating data from your couchdb databases to mongodb collections

Dependency

These are the dependency libraries/packages which has been used for the scripts which has been used for migration scripts :

Library/Package Name Description Web Reference
Node.js 6.x Node.js framework is necessary to run node scripts install/download
Couchbackup Npm package to install install
MongoDB 3.4 Mongodb where restore will happen :p install

Pre-Requisite

As these scripts are shell scripts you will need to export variables to your linux shells, you may want to save these in your profile rc file as well :

export COUCH_URL="https://username:password@hostname:port"

export COUCH_BUFFER_SIZE=10000

export LC_ALL=C

For IBM Cloudant database

As per resolution of issue, IBM Cloudant databases can be migrated easily to mognoDB as well. All the cloudant users can use below COUCH_URL env variable :

export COUCH_URL="https://MY_USERNAME:MY_PASSWORD@[email protected]:port"

Run Script

Finally all you need is database name of couchdb, mongodb database name & credentials. Run following script with following command :

master_script.sh collection_name mongo_db_name mongo_username mongo_password mongo_host mongo_port

For users, who are having mongodb open (I mean without user authentication), they can use another script and hit this command :

./master_script_without_pwd.sh collection_name mongo_db_name mongo_host mongo_port

Happy Coding! -@jimishio

About

This repository consists of scripts which can help migrating data from your couchdb databases to mongodb collections

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages