You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-user@hadoop.apache.org by Aaron Kimball <aa...@cloudera.com> on 2008/11/22 03:17:49 UTC

Re: Conf Object witout hadoop-default.xml and hadoop-site.xml

You'll want to set "fs.default.name" which identifies the filesystem to use.
Based on the protocol-prefix of the URI (e.g., "hdfs://", "file://", etc),
it will choose a different filesystem implementation.

So you'll also need to set the relevant "fs.*.impl" keys. See
hadoop-default.xml for the correct values.

I don't think you really want to do this without hadoop-default and
hadoop-site though; if you just create a "new Configuration()", it'll read
both of the above files.

So "FileSystem fs = FileSystem.get(new Configuration())" will return the
right thing..
- Aaron

On Thu, Nov 20, 2008 at 1:02 PM, Wasim Bari <wa...@msn.com> wrote:

> Hi,
>     Is it possible: I create Configuration object without
> hadoop-default.xml and hadoop-site.xml  files and after creation set the
> values in Configuration Object?
>
> If yes which are the values that I need to set in configuration Object to
> get FileSystem Object.
>
> Thanks,
>
> Wasim