I’m doing server OS patch for production cluster. I will do one server at a time. Will do swap rebalance for data nodes. But when it comes to Query/Index nodes(I have 4 of them patching one after another), do I need to remove the node(then I have to recreate all the index again! ), Or If I just stopped the couchbase service on that node(So that I don’t need to recreate all the indexes), will it throw any error?
Production patching : rolling mode : can I just stop couchbase on my index/query node?
Your approach should be fine. If you don’t want any downtime during the process, your may want to make sure each index has a replica, patch index nodes one at a time and wait for its indexes to be online before taking down the next one.
Also note that, in versions 5.0 or higher, index service supports swap rebalance. So if you were to swap in a patched node and swap out an old node, the indexes would get automatically transferred onto the incoming node. However, it is always faster to stop the index service(or failover the node), patch it and restart the service(or recover the node).
I’m using 4.6.3, but I have made sure all the index are replicated properly. Only concern is, If I just kept the node down(without clicking on failover) will the application try to access the index on this node and thus will return an error in application side, or couchbase will route the application to use the other replica of the index which is there in the healthy node?
If index is offline prepared statements will get error (If using SDK, SDK will re prepare statements). New prepare statements will try to use any other qualified index on any other indexer nodes.