3

I would like to have two couchdb server running on my machine.

I have already one instance running installed via this command line

sudo apt-get install couchdb -y

I can run it and stop it via

/etc/init.d/couchdb [start|stop|restart]

how can I have another instance of couchdb running on a different port

OS : linux 16.04

Toumi
  • 2,925
  • 4
  • 37
  • 31

1 Answers1

1

You can use a different configuration file to start a second instance with. This is definitively an advanced topic, as you must take extra care that different instances of couchdb don't share any data, log or configuration files. You find some information about configuration in the CouchDB docs. You could start with duplicating the startup script (/etc/init.d/couchdb) and adapting the folders there, then copying the local.ini from the config folder and changing the data folders, http port and other configuration there.

I used this (quite old) build script to install completely separate copies and found it easier to work with.

But nowadays I would just use Docker and install several CouchDB containers, preferably with the klaemo/couchdb image which is easy to handle.

Bernhard Gschwantner
  • 1,547
  • 11
  • 12