On Wed, Dec 19, 2012 at 2:50 AM, David Montgomery
<davidmontgom...@gmail.com> wrote:
> I am writing to riak and i get no errors.  Then again....given a key...,I
> also get no data.  Where did it go?  How does one debug riak when you write
> to riak..it looks like a success, get no data when get by key and get no
> errors.

Hi, David. I interpolated around your description, and saw this behavior:

>>> from riak import RiakClient
>>> client = RiakClient()
>>> impression_bucket = client.bucket('impressions')
>>> impression_bucket.set_n_val(2)
>>> impression_bucket.set_dw(1)
<riak.bucket.RiakBucket object at 0x1013fa850>
>>> id = "foo"
>>> qs = "bar=baz"
>>> worker_bucket = impression_bucket.new(id, data=qs)
>>> print worker_bucket.store()
<riak.riak_object.RiakObject object at 0x1004acb50>
>>> impression_bucket.get(id)
<riak.riak_object.RiakObject object at 0x1004acd50>

That answer looked like something was cheating to me, so I also
restarted the node, and tried again:

>>> impression_bucket.get(id)
<riak.riak_object.RiakObject object at 0x1013fa8d0>
>>> o1 = impression_bucket.get(id)
>>> o1.get_data()
u'bar=baz'

That looks like things are working on my setup. Could you let me know
whether this is exactly what you did, or at which step we diverged, so
I can check with your exact process?

> I have data stored on an external device.  Data is stored in /data/riak and
> riak is total permissions.  In that dir I see these folders.  kv_vnode
> lost+found  mr_queue.
>
> Only option I changed was {platform_data_dir, "/data/riak"}, in app.config.

I agree that this does look suspicious, but it's actually normal. The
`platform_data_dir` setting controls where generic vnode operational
data is stored. The setting controlling where your application's data
is stored is controlled by the `data_root` setting in the `bitcask` or
`eleveldb` section of app.config, depending on which backend you're
using.

Hope that helps,
Bryan

_______________________________________________
riak-users mailing list
riak-users@lists.basho.com
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

Reply via email to