stackuser
stackuser

Reputation: 4191

Error in starting hadoop Job Tracker

I tried to run a simple program in hadoop using Windows-Cygwin.

I am able to start the namenode .

The jobtracker start however fails with exception :

FATAL mapred.JobTracker: java.lang.IllegalArgumentException: Does not contain a valid host:port authority: local
        at org.apache.hadoop.net.NetUtils.createSocketAddr(NetUtils.java:162)
        at org.apache.hadoop.net.NetUtils.createSocketAddr(NetUtils.java:128)
        at org.apache.hadoop.mapred.JobTracker.getAddress(JobTracker.java:2560)
        at org.apache.hadoop.mapred.JobTracker.<init>(JobTracker.java:2200)
        at org.apache.hadoop.mapred.JobTracker.<init>(JobTracker.java:2192)
        at org.apache.hadoop.mapred.JobTracker.<init>(JobTracker.java:2186)
        at org.apache.hadoop.mapred.JobTracker.startTracker(JobTracker.java:300)
        at org.apache.hadoop.mapred.JobTracker.startTracker(JobTracker.java:291)
        at org.apache.hadoop.mapred.JobTracker.main(JobTracker.java:4978)

I tried all possible methods to resolve this ,but in vain. Any pointers will greatly help me.

Hdfs-site.xml configurations :

 <configuration><br>
   <property>
     <name>fs.default.name< /name>
     <value>hdfs://localhost:9100</value>
   </property>
   <property>
     <name>mapred.job.tracker< /name>
     <value>localhost:9101< /value>
   </property>
   <property>
     <name>dfs.replication< /name>
     <value>1</value>
   </property> 
 </configuration>

Upvotes: 9

Views: 24530

Answers (2)

fahrradler
fahrradler

Reputation: 151

I faced the same issue when working on the "Pseudo Distributed" examples as at this page: http://hadoop.apache.org/docs/r1.1.2/single_node_setup.html#PseudoDistributed

It turned out that hadoop simply wasn't picking up my conf files. The examples at the link above assume you are running in your install of hadoop (i.e. /Usr/jane/hadoop-1.1.2). I was trying to run the examples in another directory. I'm sure you could configure hadoop to recognize other 'conf' directories, but I took the easy route and just started running in my hadoop directory.

This thread helped me figure it out: https://issues.apache.org/jira/browse/HDFS-2515

Upvotes: 0

SSaikia_JtheRocker
SSaikia_JtheRocker

Reputation: 5063

The problem is the following lines should on into mapred-site.xml and NOT hdfs-site.xml,

<property> 
<name>mapred.job.tracker</name> 
<value>localhost:9101</value> 
</property>

By the way why are you trying to run Hadoop in Windows? For development? You don't have a linux machine or reluctant to install one?

One more thing, you usually put this property in core-site.xml not hdfs-site.xml,

<property>
<name>fs.default.name</name>
<value>hdfs://localhost:9100</value>
</property>

Upvotes: 13

Related Questions