You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@accumulo.apache.org by Suresh Prajapati <su...@gmail.com> on 2017/04/28 07:43:49 UTC

How to remove all tables of accumulo or format hadoop files for accumulo

Hello Team

I want to clear all records in accumulo for my local machine and want to
delete unused tables created while testing. I found delete table command
which can be used from accumulo shell however that will require much of
manual works for deleting large number of tables. I also tried instructions
<https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.4.2/bk_installing_manually_book/content/format_and_start_hdfs.html>
to
format namenode of hadoop but that doesn't seems to work. My question is
how can I remove all tables and have fresh start with accumulo datastore?
Any suggestion is welcomed. Tons of thanks in advanced.

Thank You
Suresh Prajapati

Re: How to remove all tables of accumulo or format hadoop files for accumulo

Posted by Josh Elser <jo...@gmail.com>.
Suresh, you can "reinitialize" Accumulo by doing the following:

* Stop Accumulo
* Run `hdfs dfs -rm -R -skipTrash /apps/accumulo/data` (assuming you're 
using HDP as you linked the HDP documentation).
* Re-run `accumulo init`
* Start Accumulo

If you are on HDP (notably, using Ambari), you likely need to provide 
some extra arguments to ensure Accumulo is configured as Ambari expects. 
You can find a write-up at [1]

However, like Dylan points out, you don't need to use the "heavy-hammer" 
to delete all of HDFS. Just drop the Accumulo tables you don't want next 
time.

[1] 
https://community.hortonworks.com/articles/79327/re-initializing-apache-accumulo-under-hdp.html

Suresh Prajapati wrote:
> Hello Team
>
> I want to clear all records in accumulo for my local machine and want to
> delete unused tables created while testing. I found delete table command
> which can be used from accumulo shell however that will require much of
> manual works for deleting large number of tables. I also tried instructions
> <https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.4.2/bk_installing_manually_book/content/format_and_start_hdfs.html>
> to
> format namenode of hadoop but that doesn't seems to work. My question is
> how can I remove all tables and have fresh start with accumulo datastore?
> Any suggestion is welcomed. Tons of thanks in advanced.
>
> Thank You
> Suresh Prajapati
>

Re: How to remove all tables of accumulo or format hadoop files for accumulo

Posted by Dylan Hutchison <dh...@cs.washington.edu>.
For deleting test tables, you may find the flag "-p" for the deletetable
shell command useful.  For example,

deletetable -f -p Test.*


will delete all tables that begin with the prefix "Test".  You could even
call this from a script if you want to automate it into your build.
Perhaps this would solve your problem without having to re-format HDFS.

On Fri, Apr 28, 2017 at 12:43 AM, Suresh Prajapati <
sureshpraja1234@gmail.com> wrote:

> Hello Team
>
> I want to clear all records in accumulo for my local machine and want to
> delete unused tables created while testing. I found delete table command
> which can be used from accumulo shell however that will require much of
> manual works for deleting large number of tables. I also tried instructions
> <https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.4.2/
> bk_installing_manually_book/content/format_and_start_hdfs.html>
> to
> format namenode of hadoop but that doesn't seems to work. My question is
> how can I remove all tables and have fresh start with accumulo datastore?
> Any suggestion is welcomed. Tons of thanks in advanced.
>
> Thank You
> Suresh Prajapati
>