问题描述
tail-fhadoop-hadoop-jobtracker-h1.log日志内容STARTUP_MSG:StartingJobTrackerSTARTUP_MSG:host=h1/192.168.253.128STARTUP_MSG:args=[]STARTUP_MSG:version=0.20.2-cdh3u3STARTUP_MSG:build=git://ubuntu-slave01/var/lib/jenkins/workspace/CDH3-Selective/build/cdh3/hadoop20/0.20.2-cdh3u3/source-r318bc781117fa276ae81a3d111f5eeba0020634f;compiledby'jenkins'onTueMar2013:26:06PDT2012************************************************************/===========================2015-03-0601:39:34,639FATALorg.apache.hadoop.mapred.JobTracker:java.lang.RuntimeException:Notahost:portpair:localatorg.apache.hadoop.net.NetUtils.createSocketAddr(NetUtils.java:140)atorg.apache.hadoop.net.NetUtils.createSocketAddr(NetUtils.java:124)atorg.apache.hadoop.mapred.JobTracker.getAddress(JobTracker.java:2434)atorg.apache.hadoop.mapred.JobTracker.<init>(JobTracker.java:2057)atorg.apache.hadoop.mapred.JobTracker.<init>(JobTracker.java:2050)atorg.apache.hadoop.mapred.JobTracker.startTracker(JobTracker.java:296)atorg.apache.hadoop.mapred.JobTracker.startTracker(JobTracker.java:288)atorg.apache.hadoop.mapred.JobTracker.main(JobTracker.java:4792)2015-03-0601:39:34,643INFOorg.apache.hadoop.mapred.JobTracker:SHUTDOWN_MSG:/************************************************************SHUTDOWN_MSG:ShuttingdownJobTrackerath1/192.168.253.128************************************************************/hadoop-hadoop-tasktracker-h1.log日志内容STARTUP_MSG:StartingTaskTrackerSTARTUP_MSG:host=h1/192.168.253.128STARTUP_MSG:args=[]STARTUP_MSG:version=0.20.2-cdh3u3STARTUP_MSG:build=git://ubuntu-slave01/var/lib/jenkins/workspace/CDH3-Selective/build/cdh3/hadoop20/0.20.2-cdh3u3/source-r318bc781117fa276ae81a3d111f5eeba0020634f;compiledby'jenkins'onTueMar2013:26:06PDT2012************************************************************/2015-03-0601:39:38,094ERRORorg.apache.hadoop.mapred.TaskTracker:Cannotstarttasktrackerbecausejava.lang.RuntimeException:Notahost:portpair:localatorg.apache.hadoop.net.NetUtils.createSocketAddr(NetUtils.java:140)atorg.apache.hadoop.net.NetUtils.createSocketAddr(NetUtils.java:124)atorg.apache.hadoop.mapred.JobTracker.getAddress(JobTracker.java:2434)atorg.apache.hadoop.mapred.TaskTracker.<init>(TaskTracker.java:1576)atorg.apache.hadoop.mapred.TaskTracker.main(TaskTracker.java:3879)2015-03-0601:39:38,097INFOorg.apache.hadoop.mapred.TaskTracker:SHUTDOWN_MSG:/************************************************************SHUTDOWN_MSG:ShuttingdownTaskTrackerath1/192.168.253.128************************************************************/以下是配置文件信息[hadoop@h1conf]$catcore-site.xml<?xmlversion="1.0"?><?xml-stylesheettype="text/xsl"href="configuration.xsl"?><!--Putsite-specificpropertyoverridesinthisfile.--><configuration><property><name>fs.default.name</name><value>hdfs://h1:9000</value></property></configuration>[hadoop@h1conf]$cathdfs-site.xml<?xmlversion="1.0"?><?xml-stylesheettype="text/xsl"href="configuration.xsl"?><!--Putsite-specificpropertyoverridesinthisfile.--><configuration><property><name>dfs.data.dir</name><value>/home/hadoop/hadoop-data</value></property><property><name>dfs.replication</name><value>1</value></property></configuration>[hadoop@h1conf]$catmapred-site.xml<?xmlversion="1.0"?><?xml-stylesheettype="text/xsl"href="configuration.xsl"?><!--Putsite-specificpropertyoverridesinthisfile.--><configuration><property><name>mapred.job.tracker></name><value>h1:9001</value></property></configuration>我刚开始学习hadoop,发现伪分布模谢式下的jobtracker和tasktracker两个进程在启动大约30移钟后消失,看日志发现以上问题,但做测试包括文件考被,wordcount测试时,均正常输出job日志,查过很多贴子都没有找出问题所在,请专家或或者是遇到和我一样的问题的前辈帮助指点一下,谢谢!
解决方案
解决方案二:
我上网查了下“java.lang.RuntimeException:Notahost:portpair:local”,说是mapred.job.tracker没配置。但是你配置了。唯一不同的是我当时的伪分布式是<value>http://h1:9001</value>写了http,不知道是这个问题不?
解决方案三:
还有这个问题应该放在hadoop,你在spark里问,回答人少。