Hi yogesh,
    Do as suggested by bejoy and add the hadoop.tmp.dir in your
core-site.xml file.it's value defaults to the /tmp dir which gets emptied
at each restart so all the data is lost... also add dfs.name.dir and
dfs.data.dir properties into your hdfs-site.xml file to avoid the data loss.

On Friday, July 20, 2012, Bejoy KS <bejoy.had...@gmail.com> wrote:
> Hi Yogesh
>
> Is your dfs.name.dir pointing to /tmp dir? If so try changing that to any
other dir . The contents of /tmp may get wiped out on OS restarts.
> Regards
> Bejoy KS
>
> Sent from handheld, please excuse typos.
> ________________________________
> From: <yogesh.kuma...@wipro.com>
> Date: Fri, 20 Jul 2012 06:20:02 +0000
> To: <hdfs-user@hadoop.apache.org>
> ReplyTo: hdfs-user@hadoop.apache.org
> Subject: NameNode fails
> Hello All :-),
>
> I am new to Hdfs.
>
> I have installed single node hdfs and started all nodes, every nodes gets
started and work fine.
> But when I shutdown my system or Restart it, then i try to run all nodes
but Namenode doesn't start .
>
> to Start it i need to format the namenode and all data gets wash off :-(.
>
> Please help me and suggest me regarding this and how can I recover
namenode from secondary name node on single node setup
>
>
> Thanks & Regards
> Yogesh Kumar Dhari
>
> Please do not print this email unless it is absolutely necessary.
>
> The information contained in this electronic message and any attachments
to this message are intended for the exclusive use of the addressee(s) and
may contain proprietary, confidential or privileged information. If you are
not the intended recipient, you should not disseminate, distribute or copy
this e-mail. Please notify the sender immediately and destroy all copies of
this message and any attachments.
>
> WARNING: Computer viruses can be transmitted via email. The recipient
should check this email and any attachments for the presence of viruses.
The company accepts no liability for any damage caused by any virus
transmitted by this email.
>
> www.wipro.com

-- 
Regards,
    Mohammad Tariq

Reply via email to