conf.set("fs.default.name", "hdfs://host:port");
where conf is the JobConf object of your job, before you submit it.


On Mon, May 25, 2009 at 10:16 AM, Stas Oskin <stas.os...@gmail.com> wrote:

> Hi.
>
> Thanks for the tip, but is it possible to set this in dynamic way via code?
>
> Thanks.
>
> 2009/5/25 jason hadoop <jason.had...@gmail.com>
>
> > if you launch your jobs via bin/hadoop jar jar_file [main class]
>  [options]
> >
> > you can simply specify -fs hdfs://host:port before the jar_file
> >
> > On Sun, May 24, 2009 at 3:02 PM, Stas Oskin <stas.os...@gmail.com>
> wrote:
> >
> > > Hi.
> > >
> > > I'm looking to move the Hadoop NameNode URL outside the hadoop-site.xml
> > > file, so I could set it at the run-time.
> > >
> > > Any idea how to do it?
> > >
> > > Or perhaps there is another configuration that can be applied to the
> > > FileSystem object?
> > >
> > > Regards.
> > >
> >
> >
> >
> > --
> > Alpha Chapters of my book on Hadoop are available
> > http://www.apress.com/book/view/9781430219422
> > www.prohadoopbook.com a community for Hadoop Professionals
> >
>



-- 
Alpha Chapters of my book on Hadoop are available
http://www.apress.com/book/view/9781430219422
www.prohadoopbook.com a community for Hadoop Professionals

Reply via email to