Cant import data to clusterd node

hello every one
i use docker to intialize 3 nodes to make 3 nodes clusters

docker run -d --name db -p 8091-8096:8091-8096 -p 11210-11211:11210-11211 couchbase
docker run -d --name db2 -p 9091-9096:8091-8096 -p 12210-12211:11210-11211 couchbase
docker run -d --name db3 -p 7091-7096:8091-8096 -p 13210-13211:11210-11211 couchbase

i stop local instance of Couchbase Server

after that i need to import bucket using command
cbimport csv -c http://localhost:8091 -u aya -p 123 -d “file://allergies.csv” -b “allergies” -g #UUID# --omit-empty --infer-types
but i give me
CSV import failed: 0 documents were imported, 0 documents failed to be imported
CSV import failed: i/o timeout

even it work correctly for local single instance

when i try to create node for local node which is created it give me node need provision

can any one helpme why i cant i import data to cluster

can any one help me does imprting code has problem

What is the content of the CSV ?
An example CSV with content as noted in cbimport csv | Couchbase Docs does import into a cluster:

$ couchbase-cli server-list -c 192.168.2.22 -u Administrator -p password
ns_1@192.168.2.12 192.168.2.12:8091 healthy active
ns_1@192.168.2.14 192.168.2.14:8091 healthy active
ns_1@192.168.2.22 192.168.2.22:8091 healthy active
$ cat -n test.csv
     1  fname,age
     2  alice,40
     3  barry,36
$ cbimport csv -c http://192.168.2.22:8091 -u Administrator -p password -d file://test.csv -b "default" -g "#UUID#" --omit-empty --infer-types
CSV `file://test.csv` imported to `http://192.168.2.22:8091` successfully
Documents imported: 2 Documents failed: 0
$ curl -s -u Administrator:password http://localhost:8093/query/service -d 'statement=select * FROM default'                        {      
"requestID": "73e70755-a371-40bc-acfe-a6c764adaa62",
"signature": {"*":"*"},
"results": [
{"default":{"age":"40","fname":"alice"}},
{"default":{"age":"36","fname":"barry"}}
],
"status": "success",
"metrics": {"elapsedTime": "2.695348ms","executionTime": "2.583764ms","resultCount": 2,"resultSize": 80,"serviceLoad": 3}
}

If I have only one line in the CSV then I get nothing imported - similar results to those you’ve posted - as the first line is taken as the field names leaving no data rows to import.

HTH.

1 Like

The process for setting up a multi-node clusters in Docker is a bit different than for a single node. See Install Couchbase Server Using Docker | Couchbase Docs

csv file consist of more than 10000 record

i had repeat the steps according to documentation and it give me

cbimport csv -c http://172.17.0.5:8091 -u aya -p 123 -d “file://allergies.csv” -b “allergies” -g #UUID# --omit-empty --infer-types

2021-07-28T06:30:15.909+02:00 WARN: Fail to create Couchbase sink, could not get Couchbase Server version – couchbase.CreateSink() at sink.go:46
CSV import failed: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.

the intialized nodes with docker are
couchbase-cli server-list -c 127.0.0.1:8091 --username aya --password 123
ns_1@172.17.0.3 172.17.0.3:8091 healthy inactiveAdded
ns_1@172.17.0.4 172.17.0.4:8091 healthy inactiveAdded
ns_1@172.17.0.5 172.17.0.5:8091 healthy active

i had deactive the local instance

i make the nodes according to documentation

i have another question what is the difference betwwen the node addition with docker and
https://docs.couchbase.com/server/current/manage/manage-nodes/add-node-and-rebalance.html

and why it give me node is not provisioned when i try to add node in local cluster