unable to delete certain keys in a bucket

Sargun Dhillon sargun at sargun.me
Mon Sep 29 15:58:25 EDT 2014

So, if I'm interpreting your message correctly, you're executing the
following steps, with the following steps, in order?
1. Key delete, X -> success
2. Key list -> yields a set, which contains X
3. Key fetch, X -> 404 / missing

I'd first ask why you're doing key listing. That's an anti-pattern.
You're going to get stale data that way. Alternatively, you could
probably set your delete_mode to immediate, and assuming the entire
preflist is available, it should result in key cleanup immediately.

If you want to simply reset your cluster, turn off all your Riak
nodes, and delete the bitcask directory, and the AAE directory. That
should "clean up" the cluster appropriately.

As far as your question if it's okay to delete an old backend - the
answer is yes. You should be able to delete /var/lib/riak/leveldb/* if
it's no longer in use.

On Mon, Sep 29, 2014 at 12:12 PM, Hristo Asenov
<hristo.s.asenov at gmail.com> wrote:
> I am using riak version 1.4.10 and it is in a cluster with two hosts. I am
> unable to get rid of keys left over from previous operations using simple
> delete operations on keys. When I list the keys for a bucket, it shows me
> the old keys, however if I try to retrieve the data associated with a key,
> no data is found. When I try to delete the key, it still persists.
> Is there a way to wipe the keys in the bucket so it starts from a clean
> slate? I don't care about any of the data in riak, but I would rather not
> have to reinstall everything again. What would happen If I just delete
> everything from /var/lib in both hosts?
> I also noticed that recently I did an update, and one of my clusters was
> using leveldb as a backend and another was using bitcask. I updated the
> configs so that both are using bitcask, but I am wondering if there is some
> stale data left over. In one of the clusters in /var/lib there is still a
> leveldb folder. Is it safe to delete it?
> _______________________________________________
> riak-users mailing list
> riak-users at lists.basho.com
> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

More information about the riak-users mailing list