今天进行了Hive的迁移,出现了如下的异常。 Total MapReduce jobs = 1Launching Job 1 out of 1Number of reduce tasks determined at compile time: 1In order to change the average load for a reducer in bytes: set hive.exec.reducers.bytes.per.reduc
今天进行了Hive的迁移,出现了如下的异常。
Total MapReduce jobs = 1Launching Job 1 out of 1Number of reduce tasks determined at compile time: 1In order to change the average load for a reducer (in bytes): set hive.exec.reducers.bytes.per.reducer=<number>In order to limit the maximum number of reducers: set hive.exec.reducers.max=<number>In order to set a constant number of reducers: set mapred.reduce.tasks=<number>java.net.UnknownHostException: xxx.test.cn: xxx.test.cn: No address associated with hostname at java.net.InetAddress.getLocalHost(InetAddress.java:1473) at org.apache.hadoop.mapred.JobClient$2.run(JobClient.java:866) at org.apache.hadoop.mapred.JobClient$2.run(JobClient.java:842) at java.security.AccessController.doPrivileged(Native Method) at javax.security.auth.Subject.doAs(Subject.java:415) at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1059) at org.apache.hadoop.mapred.JobClient.submitJobInternal(JobClient.java:842) at org.apache.hadoop.mapred.JobClient.submitJob(JobClient.java:816) at org.apache.hadoop.hive.ql.exec.ExecDriver.execute(ExecDriver.java:452) at org.apache.hadoop.hive.ql.exec.MapRedTask.execute(MapRedTask.java:136) at org.apache.hadoop.hive.ql.exec.Task.executeTask(Task.java:133) at org.apache.hadoop.hive.ql.exec.TaskRunner.runSequential(TaskRunner.java:57) at org.apache.hadoop.hive.ql.Driver.launchTask(Driver.java:1361) at org.apache.hadoop.hive.ql.Driver.execute(Driver.java:1152) at org.apache.hadoop.hive.ql.Driver.run(Driver.java:960) at org.apache.hadoop.hive.cli.CliDriver.processLocalCmd(CliDriver.java:255) at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:212) at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:403) at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:671) at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:554) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.hadoop.util.RunJar.main(RunJar.java:156)Caused by: java.net.UnknownHostException: kooxoo90-111.kuxun.cn: No address associated with hostname at java.net.Inet6AddressImpl.lookupAllHostAddr(Native Method) at java.net.InetAddress$1.lookupAllHostAddr(InetAddress.java:901) at java.net.InetAddress.getAddressesFromNameService(InetAddress.java:1293) at java.net.InetAddress.getLocalHost(InetAddress.java:1469) ... 24 moreJob Submission failed with exception 'java.net.UnknownHostException(xxx.test.cn: xxx.test.cn: No address associated with hostname)'FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.MapRedTask </number></number></number>
后续发现,在新的服务器中,只注意了进行hostname的设置,但是并没有在/etc/hosts文件中增加
127.0.0.1 xxx.test.cn
原文地址:Hadoop Hive No address associated with hostname, 感谢原作者分享。