Creating Primary Index

we are using couchbase '4.6.0-3453 Enterprise Edition ’ with 2 nodes.

When we try to create primary indexes using GUI, it hangs and fails to create index.

Please let us know how do create primary index.

@pgowda, the index build is synchronous and the control will return to the console after the build finishes. That might be the “hang” you are observing. You could check the progress of the index build on the “Index” tab in the UI.

Please use defer_build for background index building:

Also make sure the index service has sufficient memory quota allocated(UI->Settings).

after running for a 5 min i am getting timed out error

“code”: 5000,
“msg”: “GSI CreatePrimaryIndex() - cause: Request timed out. Index server may still be processing this request. Please check the status after sometime or retry.”,
“query_from_user”: “CREATE PRIMARY INDEX ON geoviewermobilesync”

please let us know how to fix this

As the message says the request is being processed at the server. You can check the status of the index build on the UI console. The timeout could be a network level timeout.

If the index build is taking longer than expected, your node may be undersized to handle the load. How many documents are there in the bucket? Are you using Standard or Memory Optimized indexes? What is the memory quota and node spec?

The index was not created it is still showing under non indexed buckets list.

there are around 50,000 docs in the bucket.
i am using Standard Global Secondary Indexes setting
Memory quota details.
Data RAM Quota: 5120 MB
Index RAM Quota: 1024 MB
Full Text RAM Quota: 512 MB

Node Spec
there are 3 nodes, 8GB . RAM each and 40 GB each node disk

The document set is very small. I suspect then it could be some configuration issue. Please make sure the ports mentioned here are open on all the nodes:

Please check the indexer.log for errors or you can share it here.