[MB-3423] 'ejectNode' is possibly destructive to data Created: 07/Feb/11 Updated: 21/Aug/12 Resolved: 21/Aug/12 |
|
| Status: | Resolved |
| Project: | Couchbase Server |
| Component/s: | RESTful-APIs |
| Affects Version/s: | 1.6.5 |
| Fix Version/s: | None |
| Security Level: | Public |
| Type: | Bug | Priority: | Major |
| Reporter: | Perry Krug | Assignee: | Aleksey Kondratenko |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | 1.6.0-release-notes, 1.6.5.3-release-notes, 1.7.0-release-notes, 1.7.1-release-notes | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Flagged: |
Release Note
|
| Description |
|
The current implementation of 'ejectNode' can be possibly destructive to data if it is run against a node that is in the cluster and responsible for vbuckets.
We need to a) update the REST API documentation to describe specifically what it is to be used for and b) not allow ejectNode to be run on a node that is serving data If absolutely necessary, a 'force' option could be implemented to allow ejection of an active node, but I don't think it's needed at this time. |
| Comments |
| Comment by Perry Krug [ 10/May/11 ] |
| A Pivotal Tracker story has been created for this Issue: http://www.pivotaltracker.com/story/show/13245397 |
| Comment by Farshid Ghods [ 04/Jun/11 ] |
|
I am not sure why this issue is marked as a release note.
this is a side effect of using ejectNode api which is based on the design and the user need to be aware of when and how they using this rest api call. |
| Comment by Perry Krug [ 05/Jun/11 ] |
| It's a release note because I believe the user needs to be aware that this would cause bad things to happen if done improperly. Until we either update the documentation or prevent the user from doing this, I think it's non-obvious and therefore requires a release note. |
| Comment by Farshid Ghods [ 03/Jun/12 ] |
| can we close this as won't fix ? |
| Comment by Aleksey Kondratenko [ 21/Aug/12 ] |
|
already done apparently # wget -O- -d --user=Administrator --password=asdasd --post-data="otpNode=n_0@10.17.20.233" http://lh:9000/controller/ejectNode Setting --user (user) to Administrator Setting --password (password) to asdasd Setting --post-data (postdata) to otpNode=n_0@10.17.20.233 DEBUG output created by Wget 1.14 on linux-gnu. URI encoding = ‘UTF-8’ --2012-08-21 17:19:01-- http://lh:9000/controller/ejectNode Host ‘lh’ has not issued a general basic challenge. Resolving lh (lh)... 127.0.0.1 Caching lh => 127.0.0.1 Connecting to lh (lh)|127.0.0.1|:9000... connected. Created socket 3. Releasing 0x09cb2f48 (new refcount 1). ---request begin--- POST /controller/ejectNode HTTP/1.1 User-Agent: Wget/1.14 (linux-gnu) Accept: */* Host: lh:9000 Connection: Keep-Alive Content-Type: application/x-www-form-urlencoded Content-Length: 24 ---request end--- [POST data: otpNode=n_0@10.17.20.233] HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 401 Unauthorized WWW-Authenticate: Basic realm="Couchbase Server Admin / REST" Server: Couchbase Server 2.0.0r_231_gdcd71d5 Pragma: no-cache Date: Wed, 22 Aug 2012 00:19:01 GMT Content-Length: 0 Cache-Control: no-cache ---response end--- 401 Unauthorized Registered socket 3 for persistent reuse. ] done. Inserted ‘lh’ into basic_authed_hosts Disabling further reuse of socket 3. Closed fd 3 ---request begin--- POST /controller/ejectNode HTTP/1.1 User-Agent: Wget/1.14 (linux-gnu) Accept: */* Host: lh:9000 Connection: Keep-Alive Content-Type: application/x-www-form-urlencoded Content-Length: 24 Authorization: Basic QWRtaW5pc3RyYXRvcjphc2Rhc2Q= ---request end--- Failed writing HTTP request: Bad file descriptor. Closed fd 3 Retrying. --2012-08-21 17:19:02-- (try: 2) http://lh:9000/controller/ejectNode Found ‘lh’ in basic_authed_hosts. Found lh in host_name_addresses_map (0x9cb2f48) Connecting to lh (lh)|127.0.0.1|:9000... connected. Created socket 3. Releasing 0x09cb2f48 (new refcount 1). ---request begin--- POST /controller/ejectNode HTTP/1.1 User-Agent: Wget/1.14 (linux-gnu) Accept: */* Authorization: Basic QWRtaW5pc3RyYXRvcjphc2Rhc2Q= Host: lh:9000 Connection: Keep-Alive Content-Type: application/x-www-form-urlencoded Content-Length: 24 ---request end--- [POST data: otpNode=n_0@10.17.20.233] HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 400 Bad Request Server: Couchbase Server 2.0.0r_231_gdcd71d5 Pragma: no-cache Date: Wed, 22 Aug 2012 00:19:02 GMT Content-Length: 29 Cache-Control: no-cache ---response end--- 400 Bad Request Registered socket 3 for persistent reuse. Skipping 29 bytes of body: [Cannot remove active server. ] done. 2012-08-21 17:19:02 ERROR 400: Bad Request. |