number of replicas per data center?

2015-01-18 Thread Kevin Burton
How do people normally setup multiple data center replication in terms of number of *local* replicas? So say you have two data centers, do you have 2 local replicas, for a total of 4 replicas? Or do you have 2 in one datacenter, and 1 in another? If you only have one in a local datacenter then

Re: number of replicas per data center?

2015-01-18 Thread Kevin Burton
Ah.. six replicas. At least its super inexpensive that way (sarcasm!) On Sun, Jan 18, 2015 at 8:14 PM, Jonathan Haddad j...@jonhaddad.com wrote: Sorry, I left out RF. Yes, I prefer 3 replicas in each datacenter, and that's pretty common. On Sun Jan 18 2015 at 8:02:12 PM Kevin Burton

Re: keyspace not exists?

2015-01-18 Thread Jason Wee
log does not show anything fishy, because it is just for fun cluster, we can actually wipe our 3 nodes cluster casandra dir, data,saved_caches,commitlog and start it all over, we encounter the same problem. two nodes running cassandra 2.1.2 and one running cassandra 2.1.1 I look a look at the

Re: Many really small SSTables

2015-01-18 Thread Roland Etzenhammer
Hi, just as a short follow up, it worked - all nodes now have 20-30 sstables instead of thousands. Cheers, Roland

Re: Compaction failing to trigger

2015-01-18 Thread Flavien Charlon
It's set on all the tables, as I'm using the default for all the tables. But for that particular table there are 41 SSTables between 60MB and 85MB, it should only take 4 for the compaction to kick in. As this is probably a bug and going back in the mailing list archive, it seems it's already been

Re: number of replicas per data center?

2015-01-18 Thread Kevin Burton
3 what? :-P replicas per datacenter or 3 data centers? So if you have 2 data centers you would have 6 total replicas with 3 local replicas per datacenter? On Sun, Jan 18, 2015 at 7:53 PM, Jonathan Haddad j...@jonhaddad.com wrote: Personally I wouldn't go 3 unless you have a good reason.

Re: keyspace not exists?

2015-01-18 Thread Jason Wee
Hi, Immediately after a repair, I execute cqlsh, still the schema mismatch? [2015-01-19 13:50:49,979] Repair session 19c67350-9f9f-11e4-8b56-a322c40b8b81 for range (-725731847063341791,-718486959589605925] finished [2015-01-19 13:50:49,980] Repair session 1a612cb0-9f9f-11e4-8b56-a322c40b8b81 for

Re: Compaction failing to trigger

2015-01-18 Thread Roland Etzenhammer
Hi Flavien, I hit some problem with minor compations recently (just some days ago) - but with many more tables. In my case compactions got not triggered, you can check this with nodetool compactionstats. Reason for me was that those minor compactions did not get triggered since there were

Re: number of replicas per data center?

2015-01-18 Thread Jonathan Haddad
Sorry, I left out RF. Yes, I prefer 3 replicas in each datacenter, and that's pretty common. On Sun Jan 18 2015 at 8:02:12 PM Kevin Burton bur...@spinn3r.com wrote: 3 what? :-P replicas per datacenter or 3 data centers? So if you have 2 data centers you would have 6 total replicas with 3

Re: number of replicas per data center?

2015-01-18 Thread Jonathan Haddad
Personally I wouldn't go 3 unless you have a good reason. On Sun Jan 18 2015 at 7:52:10 PM Kevin Burton bur...@spinn3r.com wrote: How do people normally setup multiple data center replication in terms of number of *local* replicas? So say you have two data centers, do you have 2 local

Re: number of replicas per data center?

2015-01-18 Thread Colin
I like to have 3 replicas across 3 racks in each datacenter as a rue of thumb. You can vary that, but it depends upon the use case, and the SLA's for latency. This can get a little complicated if you're using the cloud and automated deployment strategies as I like to use the same abstractions

Re: Which files should I backup for data restoring/data migration?

2015-01-18 Thread 严超
Check out this doc, I think it may help you: http://www.datastax.com/documentation/cassandra/2.0/cassandra/operations/ops_backup_restore_c.html *Best Regards!* *Chao Yan--**My twitter:Andy Yan @yanchao727 https://twitter.com/yanchao727* *My Weibo:http://weibo.com/herewearenow

Re: Compaction failing to trigger

2015-01-18 Thread 严超
Seems like Size Tier Compaction is based on table, which table did you set the compaction strategy? A minor compaction does not involve all the tables in a keyspace. Ref: http://datastax.com/documentation/cassandra/2.0/cassandra/operations/ops_configure_compaction_t.html

Re: Not enough replica available” when consistency is ONE?

2015-01-18 Thread Kevin Burton
OK.. so if I’m running with 2 replicas, then BOTH of them need to be online for this to work. Correct? Because with two replicas I need 2 to form a quorum. This is somewhat confusing them. Because if you have two replicas, and you’re depending on these types of transactions, then this is a

Not enough replica available” when consistency is ONE?

2015-01-18 Thread Kevin Burton
I’m really confused here. I”m calling: acquireInsert.setConsistencyLevel( ConsistencyLevel.ONE ); but I”m still getting the exception: com.datastax.driver.core.exceptions.UnavailableException: Not enough replica available for query at consistency SERIAL (2 required but only 1 alive)

Re: Not enough replica available” when consistency is ONE?

2015-01-18 Thread Eric Stevens
Check out http://www.datastax.com/documentation/cassandra/2.0/cassandra/dml/dml_tunable_consistency_c.html Cassandra 2.0 uses the Paxos consensus protocol, which resembles 2-phase commit, to support linearizable consistency. All operations are quorum-based ... This kicks in whenever you do CAS

Which files should I backup for data restoring/data migration?

2015-01-18 Thread 孔嘉林
Hi, I want to backup the files needed for data restoring/data migration. There are several directories: /var/lib/cassandra/ - commitlog/ - data/ - mytable/ - system/ - system_traces/

Compaction failing to trigger

2015-01-18 Thread Flavien Charlon
Hi, I am using Size Tier Compaction (Cassandra 2.1.2). Minor compaction is not triggering even though it should. See the SSTables on disk: http://pastebin.com/PSwZ5mrT You can see that we have 41 SSTable between 60MB and 85MB, which should trigger compaction unless I am missing something. Is