(hive on Tez)Caused by: org.apache.tez.dag.api.SessionNotRunning: TezSession has already shutdown.

hive on Tez :TezSession has already shutdown.

在hive里面配置Tez,配置完启动hive的时候hive启动不起来了,报了这样的错:

Exception in thread "main" java.lang.RuntimeException: 
org.apache.tez.dag.api.SessionNotRunning: TezSession 
has already shutdown. Application 
application_1549816948269_0009 failed 2 times due to AM 
Container for appattempt_1549816948269_0009_000002 
exited with  exitCode: -103
.
.
.
Container killed on request. Exit code is 143
Container exited with a non-zero exit code 143
Failing this attempt. Failing the application.
        at org.apache.hadoop.hive.ql.session.SessionState.start(SessionState.java:535)
        at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:677)
        at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:621)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.apache.hadoop.util.RunJar.run(RunJar.java:221)
        at org.apache.hadoop.util.RunJar.main(RunJar.java:136)
Caused by: org.apache.tez.dag.api.SessionNotRunning: 
TezSession has already shutdown. Application 
application_1549816948269_0009 failed 2 times due to AM 
Container for appattempt_1549816948269_0009_000002 
exited with  exitCode: -103

经过一番度娘的帮助,终于找到了相关博客!!自己也记录一下,免得下次一样找半天!

这种问题是从机上运行的Container试图使用过多的内存,而被NodeManager kill掉了。

关掉虚拟内存检查,修改yarn-site.xml文件(添加相关代码)!!

cd /opt/module/hadoop/etc/hadoop
vim yarn-site.xml

关掉虚拟机内存检查!!


        yarn.nodemanager.vmem-check-enabled
        false

发给其他所有节点,重启yarn服务!

其实改掉这个再重启hive就可以成功了的,但我犯了一个愚蠢的错误,那就是我的主机是hadoop101,但我的资源分配由Hadoop102负责,我只修改了Hadoop101里面的配置文件,没修改102里面的,所以还是报了一样的错,最终我把这个修改过的yarn-site.xml文件发给了其他所有的节点重启了yarn 服务,可以了!!

(hive on Tez)Caused by: org.apache.tez.dag.api.SessionNotRunning: TezSession has already shutdown._第1张图片

这是我找到的另外一篇博客,里面还有一种方法!

你可能感兴趣的:(Hive,学习,hive启动不起来)