How to allocate a node to a zone?

139 views
Skip to first unread message

Dan

unread,
Nov 12, 2014, 6:09:04 AM11/12/14
to bigcou...@googlegroups.com
Hi Guys,

I have a 6 node BigCouch cluster that I am experimenting with that I have split into 2 zones. I'm confused by this line from the docs here http://bigcouch.cloudant.com/api

and then editing the node entries for each node in a zone to add a zone field, .eg.:
{"_id": "de...@127.0.0.1", zone": "parts_unknown"}

I'm confused by "parts_unknown" here? Do I need to set a zone by number or is parts_unknown some kind of magic value that the cluster will handle? Sorry if I'm being dumb and this seems obvious. I've been searching and searching on-line and not managed to find anything specific about this anywhere,

any help greatly appreciated,

Dan.

Dan

unread,
Nov 12, 2014, 6:28:00 AM11/12/14
to bigcou...@googlegroups.com
What I have tried in the end is:

curl -X PUT 127.0.0.1:5986/nodes/bigcouch@db1 -d '{"_rev":"1-967a00dff5e02add41819138abb3284d", "zone":"1"}'
curl -X PUT 127.0.0.1:5986/nodes/bigcouch@db2 -d '{"_rev":"1-967a00dff5e02add41819138abb3284d", "zone":"1"}'
curl -X PUT 127.0.0.1:5986/nodes/bigcouch@db3 -d '{"_rev":"1-967a00dff5e02add41819138abb3284d", "zone":"1"}'
curl -X PUT 127.0.0.1:5986/nodes/bigcouch@db4 -d '{"_rev":"1-967a00dff5e02add41819138abb3284d", "zone":"2"}'
curl -X PUT 127.0.0.1:5986/nodes/bigcouch@db5 -d '{"_rev":"1-967a00dff5e02add41819138abb3284d", "zone":"2"}'
curl -X PUT 127.0.0.1:5986/nodes/bigcouch@db6 -d '{"_rev":"1-967a00dff5e02add41819138abb3284d", "zone":"2"}'

They now return this on a GET:

# curl -X GET 127.0.0.1:5986/nodes/bigcouch@db6
{"_id":"bigcouch@db6","_rev":"2-39c3fb42aed34ea2260c8a7352498895","zone":"2"}

However I have no idea if this is correct or not?

My cluster configuration that I am experimenting with is:

[cluster]
q=6
r=3
w=3
n=5
z=2

Dan

unread,
Nov 17, 2014, 10:36:20 AM11/17/14
to bigcou...@googlegroups.com
Hi, sorry to bump this one, but did anyone have 5 minutes just to confirm the correct technique for adding a node into a zone?

Gart Nilis

unread,
Jun 13, 2017, 12:48:51 PM6/13/17
to BigCouch Users, tzewan...@gmail.com
I know this is ancient but can anyone confirm this?
Reply all
Reply to author
Forward
0 new messages