Cassandra datacenter outage failover problem

43 views
Skip to first unread message

Chen

unread,
Dec 1, 2016, 10:47:11 AM12/1/16
to DataStax C++ Driver for Apache Cassandra User Mailing List
I have a setup with two datacenters with three nodes per datacenter. I'm running into an issue where I turn off cassandra for all three nodes for the first datacenter but all my queries fail because it doesn't failover to the second datacenter. I looked through my logs and it seems like cassandra is constantly trying to connect to the nodes in the first datacenter and it doesn't even try to connect to the nodes in the second datacenter. I'm running the latest version of the cassandra cpp driver (2.5.0) if that matters.

Can anyone help?

Thanks,
Chen

Greg Fast

unread,
Dec 1, 2016, 3:06:09 PM12/1/16
to DataStax C++ Driver for Apache Cassandra User Mailing List

Hi Chen,

What is the consistency level of your requests?

I'm pretty sure the cpp driver is defaulted to LOCAL_ONE, so if your client is in the "failed" datacenter that's a problem. Also because you have a total of 6 replicas, a simple QUORUM consistency would fail because a QUORUM in your case is 4, but you can only get a maximum of 3 nodes to respond.

Ganesh M

unread,
Dec 2, 2016, 7:03:59 AM12/2/16
to DataStax C++ Driver for Apache Cassandra User Mailing List

Hi Chen,

I have posted the same question but didn't get any answer. Later I got the answer from datastax enterprise support that cpp driver doesn't have a failover retry policy. We need to do an application retry for these scenarios.

Reply all
Reply to author
Forward
0 new messages