Playing with / understanding Riak configurations
vikramlalit at gmail.com
Wed Jul 27 18:07:47 EDT 2016
Hi - I have a Riak node with n_val=3, r=2, w=2 and have just one key-object
stored there-in. I'm trying to test various configurations to better
understand the system and have the following observations - some dont seem
to align with my understanding so far, so appreciate if someone can throw
some light please... Thanks!
1. n=3, r=2, w=2: Base state, 1 key-value pair.
2. Change to n=2, r=2, w=2: When I query from my client, I randomly see 1
or 2 values being fetched. In fact, the number of keys fetched is 1 or 2,
randomly changing each time the client queries the db. Ideally, I would
have expected that if we reduce the n_val, there would be data loss from
one of the vnodes. And that for this scenario, I would still expect only 1
(remaining) key-value pair to be read from the remaining two vnodes that
has the data. Note that I dont intend to make such a change in production
as cognizant of the recommendation to never decrease the value of n, but
have done so only to test out the details.
3. Then change to n=2, r=1, w=1: I get the same alternating result as
above, i.e. 1 or 2 values being fetched.
4. Then change to n=1, r=1, w=1: I get 3 key-value pairs, all identical,
from the database. Again, are these all siblings?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the riak-users