cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aaron morton <aa...@thelastpickle.com>
Subject Re: Replica data distributing between racks
Date Mon, 02 May 2011 21:59:13 GMT
My bad, I missed the way TokenMetadata.ringIterator() and firstTokenIndex() work. 

Eric, can you show the output from nodetool ring ?


Aaron

On 3 May 2011, at 07:30, Eric tamme wrote:

> On Mon, May 2, 2011 at 3:22 PM, Jonathan Ellis <jbellis@gmail.com> wrote:
>> On Mon, May 2, 2011 at 2:18 PM, aaron morton <aaron@thelastpickle.com> wrote:
>>> When the NTS selects replicas in a DC it orders the tokens available in  the
DC, then (in the first pass) iterates through them placing a replica in each unique rack.
 e.g. if the RF in each DC was 2, the replicas would be put on 2 unique racks if possible.
So the lowest token in the DC will *always* get a write.
>> 
>> It's supposed to start w/ the node closest to the token in each DC, so
>> that shouldn't be the case unless you are using BOP/OPP instead of RP.
>> 
> 
> I am using a RandomPartitioner as shown below:
> 
> Cluster Information:
>   Snitch: org.apache.cassandra.locator.PropertyFileSnitch
>   Partitioner: org.apache.cassandra.dht.RandomPartitioner
> 
> So as far as "closeness" .. how does that get factored in when using a
> PropertyFileSnitch?  Is one rack closer than the other?  In reality
> for each data center there are two nodes in the same rack on the same
> switch,  but I set the topology file up to have 2 racks per data
> center specifically so I would get distribution.
> 
> -Eric


Mime
View raw message