hadoop-mapreduce-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Mawata <chris.maw...@gmail.com>
Subject Re: Wrong FS hdfs:/localhost:9000 ;expected file///
Date Tue, 25 Feb 2014 14:37:49 GMT
The hadoop command gives you a configuration object with the configurations
that are in your XML files.  In your Java code you are probably getting
your FileSystem object from a blank Configuration when you don't use the
hadoop command.
Chris
On Feb 24, 2014 7:37 AM, "Chirag Dewan" <chirag.dewan@ericsson.com> wrote:

>  Hi All,
>
>
>
> I am new to hadoop. I am using hadoop 2.2.0. I have a simple client code
> which reads a file from HDFS on a single node cluster. Now when I run my
> code using java -jar mytest.jar it throws the error Wrong FS
> hdfs://localhost.
>
>
>
> When I run the same code with hadoop jar test.jar it works just fine.
>
>  I have my core-site.xml with fs.default.name as hdfs://localhost
>
>
>
> Am I missing some classpath dependency here?
>
>
>
> Thanks in advance.
>
>
>
> Chirag Dewan
>
>
>
>
>

Mime
View raw message