I'm experimenting with a 4-node Cassandra (1.2) cluster which I've just setup on CentOS 6.4 across 4 VMs. First, I created a keyspace with a replication factor of 3 and within it created a couple of tables and populated each one with a small number of rows - all using Cqlsh. Simple INSERTs, SELECTs and UPDATEs appeared to be working fine.
Then I started disconnecting some of the nodes randomly to see the capabilities of the cluster in action. While two of the nodes were offline, I ran a few SELECTs which returned the correct results. Subsequently, I attempted to update an existing row, which according to "nodetool getendpoints" was hosted on the offline nodes as well as on the local node on which Cqlsh was running. After bringing the two nodes back online, running a SELECT against the updated row did not return the updated data values. I waited a little and tried SELECTing again but that still kept returning the original data. I also tried the following, none of which returned the updated data:
- Re-running the UPDATE a few times
- UPDATEing a different column in the same row - the field wasn't updated
- Restarting all four nodes in the cluster
An UPDATE for the same column in a different row works fine, which along with #2 above leads me to think this is an issue with the row data.
The following snippet shows a SELECT returning the original data before and after a seemingly successful UPDATE:
cqlsh:demo> select email, active from users where email = 'john.doe@bti360.com';
email | active
--------------------+--------
john.doe@bti360.com | True
cqlsh:demo> update users set active = false where email = 'john.doe@bti360.com';
cqlsh:demo> select email, active from users where email = 'john.doe@bti360.com';
email | active
--------------------+--------
john.doe@bti360.com | True
I am new to Cassandra so I could very well be missing something. Any suggestions or troubleshooting tips (files to check or commands to run) to help uncover what is going on here would be much appreciated.