hadoop-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Harsh J <ha...@cloudera.com>
Subject Re: Recommended way to check if namenode already formatted
Date Thu, 09 Aug 2012 23:41:06 GMT
Stephen,

A NameNode can be considered 'formatted' if its up (it does not start
otherwise).

If you mean to check if the NameNode has been _freshly_ formatted,
then checking the count of "hadoop fs -ls /" to be non-zero may help,
cause by default the NameNode carries no files.

$ hadoop fs -ls / | wc -l
0

On Fri, Aug 10, 2012 at 4:34 AM, Stephen Boesch <javadba@gmail.com> wrote:
>
> Hi,  what's your take?   I was thinking to check if a certain always-present
> file exists  via a  hadoop dfs -ls <file> .  Other suggestions  welcome.
>
> thanks
>
> stephenb



-- 
Harsh J

Mime
View raw message