how to change bucket property when node is down

Jordan West jwest at basho.com
Wed May 28 11:12:51 EDT 2014


Gavin,

Riak stores bucket properties separately from key/values, along with other
metadata about the cluster. Where these files live depend on your platform
and configuration. By default, there will be a directory named "ring" in
the same directory that contains either the "bitcask" or "leveldb" data
directories depending on the backend you chose -- this also assumes you
haven't change the location of these directories in the config.

Jordan


On Wed, May 28, 2014 at 3:10 AM, Gavin Huang <shuminghuang at gmail.com> wrote:

> I'd like to ask another question about where do riak save bucket property
> in disk space.
> is it different from key/values?
>
> Thanks.
> Gavin
>
>
>
> On Wed, May 28, 2014 at 11:15 AM, Gavin Huang <shuminghuang at gmail.com>wrote:
>
>> Thanks Jordan, I've tried the first option and it works for me.
>> thanks again for all your help.
>>
>> Gavin
>>
>>
>> On Wed, May 28, 2014 at 2:36 AM, Jordan West <jwest at basho.com> wrote:
>>
>>> Gavin,
>>>
>>> Are you able to stop all other traffic to Riak? Testing locally, the
>>> crashes only start occurring once the first request to a key in the
>>> mis-configured bucket is issued after restarting. Using curl I am able to
>>> change the property back to 3, as an integer, as long as no keys are
>>> requested in that bucket after restarting isn't made.
>>>
>>> Otherwise, if you can keep Riak running long enough, executing the
>>> following from `riak attach` should have the same end result:
>>>
>>> riak_core_bucket:set_bucket(<<"b">>, lists:keystore(n_val, 1,
>>> riak_core_bucket:get_bucket(<<"b">>), {n_val, 3})).
>>>
>>> A third option, I haven't tried, is to temporarily disable active
>>> anti-entropy (the subsystem where the error seems to be coming from), until
>>> you've had a chance to make the fix.
>>>
>>> Jordan
>>>
>>>
>>> On Fri, May 23, 2014 at 9:47 PM, Gavin Huang <shuminghuang at gmail.com>wrote:
>>>
>>>> Hi, Alexander
>>>>
>>>> Thanks for your reply. the problem I have is riak is down and can not
>>>> server any requests.
>>>> I'd like to see if there a solution to "repair" bucket, if the bucket
>>>> properties are stored in a file in some where.
>>>>
>>>> Thanks.
>>>>  Gavin
>>>>
>>>>
>>>> On Sat, May 24, 2014 at 1:52 AM, agrytsenko <
>>>> alexander.grytsenko at dev-pro.net> wrote:
>>>>
>>>>> just use curl to set the correct value, e.g.:
>>>>>
>>>>> > curl -v -XPUT http://127.0.0.1:8098/buckets/test/props -H
>>>>> "Content-Type:
>>>>> > application/json" -d '{"props":{"n_val":3}}'
>>>>>
>>>>> more about bucket properties:
>>>>>
>>>>> http://docs.basho.com/riak/latest/dev/references/http/set-bucket-props/#Request
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> View this message in context:
>>>>> http://riak-users.197444.n3.nabble.com/how-to-change-bucket-property-when-node-is-down-tp4031160p4031161.html
>>>>> Sent from the Riak Users mailing list archive at Nabble.com.
>>>>>
>>>>> _______________________________________________
>>>>> riak-users mailing list
>>>>> riak-users at lists.basho.com
>>>>> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
>>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> riak-users mailing list
>>>> riak-users at lists.basho.com
>>>> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
>>>>
>>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.basho.com/pipermail/riak-users_lists.basho.com/attachments/20140528/8122b863/attachment.html>


More information about the riak-users mailing list