我是Hadoop的新手。 Hadoop 1.2.1安装在我的ubuntu 14.04中。当hadoop.tmp.dir
设置为/tmp/hadoop/
时,它运行得非常好。然后我将属性更改为/var/hadoop
。现在,Jobtracker和Tasktarcker没有运行。 Jobtracker的日志文件显示错误
FATAL org.apache.hadoop.mapred.JobTracker: java.net.BindException: Problem binding to localhost/127.0.0.1:54310 : Address already in use
如何解决此问题? Jobtracker的完整日志文件如下。
2015-08-05 22:07:03,441 INFO org.apache.hadoop.metrics2.impl.MetricsSourceAdapter: MBean for source MetricsSystem,sub=Stats registered.
2015-08-05 22:07:03,442 INFO org.apache.hadoop.metrics2.impl.MetricsSystemImpl: Scheduled snapshot period at 10 second(s).
2015-08-05 22:07:03,442 INFO org.apache.hadoop.metrics2.impl.MetricsSystemImpl: JobTracker metrics system started
2015-08-05 22:07:03,561 INFO org.apache.hadoop.metrics2.impl.MetricsSourceAdapter: MBean for source QueueMetrics,q=default registered.
2015-08-05 22:07:03,773 INFO org.apache.hadoop.metrics2.impl.MetricsSourceAdapter: MBean for source ugi registered.
2015-08-05 22:07:03,773 WARN org.apache.hadoop.metrics2.impl.MetricsSystemImpl: Source name ugi already exists!
2015-08-05 22:07:03,775 INFO org.apache.hadoop.security.token.delegation.AbstractDelegationTokenSecretManager: Updating the current master key for generating delegation tokens
2015-08-05 22:07:03,777 INFO org.apache.hadoop.security.token.delegation.AbstractDelegationTokenSecretManager: Starting expired delegation token remover thread, tokenRemoverScanInterval=60 min(s)
2015-08-05 22:07:03,777 INFO org.apache.hadoop.security.token.delegation.AbstractDelegationTokenSecretManager: Updating the current master key for generating delegation tokens
2015-08-05 22:07:03,777 INFO org.apache.hadoop.mapred.JobTracker: Scheduler configured with (memSizeForMapSlotOnJT, memSizeForReduceSlotOnJT, limitMaxMemForMapTasks, limitMaxMemForReduceTasks) (-1, -1, -1, -1)
2015-08-05 22:07:03,778 INFO org.apache.hadoop.util.HostsFileReader: Refreshing hosts (include/exclude) list
2015-08-05 22:07:03,784 INFO org.apache.hadoop.mapred.JobTracker: Starting jobtracker with owner as hduser
2015-08-05 22:07:03,798 FATAL org.apache.hadoop.mapred.JobTracker: java.net.BindException: Problem binding to localhost/127.0.0.1:54310 : Address already in use
at org.apache.hadoop.ipc.Server.bind(Server.java:267)
at org.apache.hadoop.ipc.Server$Listener.<init>(Server.java:341)
at org.apache.hadoop.ipc.Server.<init>(Server.java:1539)
at org.apache.hadoop.ipc.RPC$Server.<init>(RPC.java:569)
at org.apache.hadoop.ipc.RPC.getServer(RPC.java:530)
at org.apache.hadoop.mapred.JobTracker.<init>(JobTracker.java:1985)
at org.apache.hadoop.mapred.JobTracker.<init>(JobTracker.java:1689)
at org.apache.hadoop.mapred.JobTracker.<init>(JobTracker.java:1683)
at org.apache.hadoop.mapred.JobTracker.startTracker(JobTracker.java:320)
at org.apache.hadoop.mapred.JobTracker.startTracker(JobTracker.java:311)
at org.apache.hadoop.mapred.JobTracker.startTracker(JobTracker.java:306)
at org.apache.hadoop.mapred.JobTracker.main(JobTracker.java:4710)
Caused by: java.net.BindException: Address already in use
at sun.nio.ch.Net.bind0(Native Method)
at sun.nio.ch.Net.bind(Net.java:463)
at sun.nio.ch.Net.bind(Net.java:455)
at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:223)
at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
at org.apache.hadoop.ipc.Server.bind(Server.java:265)
... 11 more
2015-08-05 22:07:03,799 INFO org.apache.hadoop.mapred.JobTracker: SHUTDOWN_MSG:
/************************************************************
SHUTDOWN_MSG: Shutting down JobTracker at niyas-SVE15137CNW/127.0.1.1
************************************************************/
提前致谢
答案 0 :(得分:0)
通过重新配置SSH解决了该问题。
答案 1 :(得分:0)
终止在端口54310上运行的进程:
sudo netstat -nptl | grep -i \:22 | awk '{print $7}' | cut -d'/' -f1 | xargs kill $1
然后重启你的hadoop实例。