Wiping data directory break vnodes with read_block_error

Brian Shumate bshumate at basho.com
Thu Feb 28 13:01:03 EST 2013


Hello Jonas,

I think the issue is that you actually wiped out too much by removing
the entire /var/lib/riak directory.

Typically when resetting the data directories on a Riak node, you'd remove
the contents of only those backend directories which correspond to the ones
defined in your app.config.

For example, if you are using the Bitcask backend, you'd want to only do
something like:

riak stop
sudo rm -rf /var/lib/riak/bitcask/*
riak start

This removes all Bitcask data but preserves the node's ring state.

If you wanted to reset _both_ the Bitcask data and the ring state you'd do:

riak stop
sudo rm -rf /var/lib/riak/bitcask/*
sudo rm -rf /var/lib/riak/ring/*
riak start

This would essentially reset the node back to a new state while retaining
any configuration changes you already specified in app.config or vm.args.

I hope this helps.

Regards,

Brian Shumate

On Feb 28, 2013, at 2:55 AM, Jonas Lindmark wrote:

> Hi,
> 
> I'm looking for a way to manually wipe the data off of a single-node riak installation. I'm using riak (1.3.0 2013-02-19) Debian x86_64 with the riak_kv_eleveldb_backend.
> 
> What I'm currently doing is:
> 
> 	• riak stop
> 	• rm -rf /var/lib/riak
> 	• mkdir riak
> 	• chown riak:riak riak
> 	• start riak
> Riak starts ok but a riak-admin vnode-status gives me:
> 
> Backend: riak_kv_eleveldb_backend
> Status: 
> [{stats,<<"                               Compactions\nLevel  Files Size(MB) Time(sec) Read(MB) Write(MB)\n--------------------------------------------------\n">>},
>  {read_block_error,<<"0">>}]
> 
> For each vnode.
> 
> It seems to me that there is something more I need to wipe for this to work but I can't find which files that would be.
> 
> /Jonas
> _______________________________________________
> 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