Details
-
Bug
-
Resolution: Not a Bug
-
Critical
-
Cheshire-Cat
-
Centos 7 64 bit; Couchbase Entereprise Build 3016
-
Untriaged
-
Centos 64-bit
-
-
1
-
No
Description
Summary:
Creation of collection after network split through REST API gave 500 Internal Server Error
"Unexpected server error, request logged."
Steps to Reproduce
- Create a 5 node cluster .211, .213, .215, .217, .219
- Load the sample bucket - beer-sample
- Introduce network partition on .211 and .219
(on .219 execute: and vice-versa on .211 as well)
iptables -A INPUT -s 172.23.105.211 -j DROP .
|
4. Create a collection "collection1" on .211 with REST call to .211. returns success 200 Ok
curl -X POST -v -u Administrator:password http://172.23.105.211:8091/pools/default/buckets/beer-sample/collections/_default -d name=collection1
|
5. List collections by making REST call to .219 and confirm that collection1 is listed
curl -X GET -v -u Administrator:password http://172.23.105.219:8091/pools/default/buckets/beer-sample/collections
|
{"uid":"1","scopes":[{"name":"_default","uid":"0","collections":[{"name":"collection1","uid":"8","maxTTL":0},{"name":"_default","uid":"0","maxTTL":0}]}]}
|
6. Now try creating the same collection again with REST call to .219. It gives the below error message
curl -X POST -v -u Administrator:password http://172.23.105.219:8091/pools/default/buckets/beer-sample/collections/_default -d name=collection1
|
* About to connect() to 172.23.105.219 port 8091 (#0)
|
* Trying 172.23.105.219...
|
* Connected to 172.23.105.219 (172.23.105.219) port 8091 (#0)
|
* Server auth using Basic with user 'Administrator'
|
> POST /pools/default/buckets/beer-sample/collections/_default HTTP/1.1
|
> Authorization: Basic QWRtaW5pc3RyYXRvcjpwYXNzd29yZA==
|
> User-Agent: curl/7.29.0
|
> Host: 172.23.105.219:8091
|
> Accept: */*
|
> Content-Length: 16
|
> Content-Type: application/x-www-form-urlencoded
|
>
|
* upload completely sent off: 16 out of 16 bytes
|
< HTTP/1.1 500 Internal Server Error
|
< Cache-Control: no-cache,no-store,must-revalidate
|
< Content-Length: 44
|
< Content-Type: application/json
|
< Date: Thu, 10 Sep 2020 07:51:16 GMT
|
< Expires: Thu, 01 Jan 1970 00:00:00 GMT
|
< Pragma: no-cache
|
< Server: Couchbase Server
|
< X-Content-Type-Options: nosniff
|
< X-Frame-Options: DENY
|
< X-Permitted-Cross-Domain-Policies: none
|
< X-XSS-Protection: 1; mode=block
|
<
|
* Connection #0 to host 172.23.105.219 left intact
|
["Unexpected server error, request logged."]
|
Expected Result: Collection with this name already exists
Actual Result: 500 internal server error, unexpected server error, request logged
Few observations
- In a way this issue seems to be similar to what we saw in https://issues.couchbase.com/browse/MB-37842
- If the network split is done on .211 and .213 and same steps is repeated, we observe
503 Service Unavailable, Operation is unsafe, Retry later.
https://issues.couchbase.com/browse/MB-40654