Hive2.3版本

Hadoop2.7版本

执行hive命令报错:

报错内容:

CONSOLE#21/03/24 17:32:54 ERROR ql.Driver: FAILED: Hive Internal Error: java.lang.NoSuchMethodError(com.facebook.fb303.FacebookService$Client.sendBaseOneway(Ljava/lang/String;Lorg/apache/thrift/TBase;)V)

CONSOLE#java.lang.NoSuchMethodError: com.facebook.fb303.FacebookService$Client.sendBaseOneway(Ljava/lang/String;Lorg/apache/thrift/TBase;)V

CONSOLE#Caused by: java.lang.NoSuchMethodError: com.facebook.fb303.FacebookService$Client.sendBaseOneway(Ljava/lang/String;Lorg/apache/thrift/TBase;)V

CONSOLE# 21/03/24 17:32:54 WARN session.SessionState: METASTORE_FILTER_HOOK will be ignored, since hive.security.authorization.manager is set to instance of HiveAuthorizerFactory.

CONSOLE# 21/03/24 17:32:54 INFO hive.metastore: Mestastore configuration hive.metastore.filter.hook changed from org.apache.hadoop.hive.metastore.DefaultMetaStoreFilterHookImpl to org.apache.hadoop.hive.ql.security.authorization.plugin.AuthorizationMetaStoreFilterHook

CONSOLE# FAILED: Hive Internal Error: java.lang.NoSuchMethodError(com.facebook.fb303.FacebookService$Client.sendBaseOneway(Ljava/lang/String;Lorg/apache/thrift/TBase;)V)

CONSOLE# java.lang.NoSuchMethodError: com.facebook.fb303.FacebookService$Client.sendBaseOneway(Ljava/lang/String;Lorg/apache/thrift/TBase;)V

CONSOLE# at com.facebook.fb303.FacebookService$Client.send_shutdown(FacebookService.java:436)

CONSOLE# at com.facebook.fb303.FacebookService$Client.shutdown(FacebookService.java:430)

CONSOLE# at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.close(HiveMetaStoreClient.java:555)

CONSOLE# at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

CONSOLE# at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

CONSOLE# at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

CONSOLE# at java.lang.reflect.Method.invoke(Method.java:498)

CONSOLE# at org.apache.hadoop.hive.metastore.RetryingMetaStoreClient.invoke(RetryingMetaStoreClient.java:173)

CONSOLE# at com.sun.proxy.$Proxy40.close(Unknown Source)

CONSOLE# at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

CONSOLE# at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

CONSOLE# at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

CONSOLE# at java.lang.reflect.Method.invoke(Method.java:498)

CONSOLE# at org.apache.hadoop.hive.metastore.HiveMetaStoreClient$SynchronizedHandler.invoke(HiveMetaStoreClient.java:2336)

CONSOLE# at com.sun.proxy.$Proxy40.close(Unknown Source)

CONSOLE# at org.apache.hadoop.hive.ql.metadata.Hive.close(Hive.java:409)

CONSOLE# at org.apache.hadoop.hive.ql.metadata.Hive.create(Hive.java:325)

CONSOLE# at org.apache.hadoop.hive.ql.metadata.Hive.getInternal(Hive.java:312)

CONSOLE# at org.apache.hadoop.hive.ql.metadata.Hive.get(Hive.java:288)

CONSOLE# at org.apache.hadoop.hive.ql.session.SessionState.setAuthorizerV2Config(SessionState.java:917)

CONSOLE# at org.apache.hadoop.hive.ql.session.SessionState.setupAuth(SessionState.java:881)

CONSOLE# at org.apache.hadoop.hive.ql.session.SessionState.getAuthenticator(SessionState.java:1483)

CONSOLE# at org.apache.hadoop.hive.ql.session.SessionState.getUserFromAuthenticator(SessionState.java:1154)

CONSOLE# at org.apache.hadoop.hive.ql.Driver.execute(Driver.java:1751)

CONSOLE# at org.apache.hadoop.hive.ql.Driver.runInternal(Driver.java:1526)

CONSOLE# at org.apache.hadoop.hive.ql.Driver.run(Driver.java:1237)

CONSOLE# at org.apache.hadoop.hive.ql.Driver.run(Driver.java:1227)

CONSOLE# at org.apache.hadoop.hive.cli.CliDriver.processLocalCmd(CliDriver.java:233)

CONSOLE# at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:184)

CONSOLE# at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:403)

CONSOLE# at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:336)

CONSOLE# at org.apache.hadoop.hive.cli.CliDriver.processReader(CliDriver.java:474)

CONSOLE# at org.apache.hadoop.hive.cli.CliDriver.processFile(CliDriver.java:490)

CONSOLE# at org.apache.hadoop.hive.cli.CliDriver.executeDriver(CliDriver.java:793)

CONSOLE# at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:759)

CONSOLE# at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:686)

CONSOLE# at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

CONSOLE# at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

CONSOLE# at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

CONSOLE# at java.lang.reflect.Method.invoke(Method.java:498)

CONSOLE# at org.apache.sqoop.hive.HiveImport.executeScript(HiveImport.java:331)

CONSOLE# at org.apache.sqoop.hive.HiveImport.importTable(HiveImport.java:241)

CONSOLE# at org.apache.sqoop.tool.ImportTool.importTable(ImportTool.java:537)

CONSOLE# at org.apache.sqoop.tool.ImportTool.run(ImportTool.java:628)

CONSOLE# at org.apache.sqoop.Sqoop.run(Sqoop.java:147)

CONSOLE# at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70)

CONSOLE# at org.apache.sqoop.Sqoop.runSqoop(Sqoop.java:183)

CONSOLE# at org.apache.sqoop.Sqoop.runTool(Sqoop.java:234)

CONSOLE# at org.apache.sqoop.Sqoop.runTool(Sqoop.java:243)

CONSOLE# at org.apache.sqoop.Sqoop.main(Sqoop.java:252)

CONSOLE# 21/03/24 17:32:54 ERROR ql.Driver: FAILED: Hive Internal Error: java.lang.NoSuchMethodError(com.facebook.fb303.FacebookService$Client.sendBaseOneway(Ljava/lang/String;Lorg/apache/thrift/TBase;)V)

CONSOLE# java.lang.NoSuchMethodError: com.facebook.fb303.FacebookService$Client.sendBaseOneway(Ljava/lang/String;Lorg/apache/thrift/TBase;)V

CONSOLE# at com.facebook.fb303.FacebookService$Client.send_shutdown(FacebookService.java:436)
。。。 CONSOLE# 21/03/24 17:32:54 INFO ql.Driver: Completed executing command(queryId=hdfs_20210324173252_4b4f6011-7ab8-494c-8128-be519ac0868b); Time taken: 0.044 seconds CONSOLE# 21/03/24 17:32:54 INFO conf.HiveConf: Using the default value passed in for log id: 3786c09f-2d67-410c-b1ba-d5264d3e3eea CONSOLE# 21/03/24 17:32:54 INFO session.SessionState: Resetting thread name to main CONSOLE# 21/03/24 17:32:54 INFO conf.HiveConf: Using the default value passed in for log id: 3786c09f-2d67-410c-b1ba-d5264d3e3eea CONSOLE# 21/03/24 17:32:54 INFO session.SessionState: Deleted directory: /tmp/hive23/hdfs/3786c09f-2d67-410c-b1ba-d5264d3e3eea on fs with scheme hdfs CONSOLE# 21/03/24 17:32:54 INFO session.SessionState: Deleted directory: /usr/local/hive23/scratchdir/3786c09f-2d67-410c-b1ba-d5264d3e3eea on fs with scheme file CONSOLE# 21/03/24 17:32:54 ERROR tool.ImportTool: Import failed: java.io.IOException: Exception thrown in Hive CONSOLE# at org.apache.sqoop.hive.HiveImport.executeScript(HiveImport.java:358) CONSOLE# at org.apache.sqoop.hive.HiveImport.importTable(HiveImport.java:241) CONSOLE# at org.apache.sqoop.tool.ImportTool.importTable(ImportTool.java:537) CONSOLE# at org.apache.sqoop.tool.ImportTool.run(ImportTool.java:628) CONSOLE# at org.apache.sqoop.Sqoop.run(Sqoop.java:147) CONSOLE# at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70) CONSOLE# at org.apache.sqoop.Sqoop.runSqoop(Sqoop.java:183) CONSOLE# at org.apache.sqoop.Sqoop.runTool(Sqoop.java:234) CONSOLE# at org.apache.sqoop.Sqoop.runTool(Sqoop.java:243) CONSOLE# at org.apache.sqoop.Sqoop.main(Sqoop.java:252) CONSOLE# Caused by: java.lang.reflect.InvocationTargetException CONSOLE# at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) CONSOLE# at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) CONSOLE# at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) CONSOLE# at java.lang.reflect.Method.invoke(Method.java:498) CONSOLE# at org.apache.sqoop.hive.HiveImport.executeScript(HiveImport.java:331) CONSOLE# ... 9 more CONSOLE# Caused by: java.lang.NoSuchMethodError: com.facebook.fb303.FacebookService$Client.sendBaseOneway(Ljava/lang/String;Lorg/apache/thrift/TBase;)V

  

报错原因:没有找到hive的libfb303的jar包。

但是从hive的lib目录有找到对应的jar包。最后怀疑是环境变量有问题,导致没有找到对应jar包的正确路径。

[hdfs@centos lib]$ pwd
/usr/local/hive23/lib
[hdfs@centos lib]$ ll | grep libfb
-rw-r--r-- 1 hdfs hdfs 313702 Mar 24 17:35 libfb303-0.9.3.jar

查看环境变量配置,果然是环境变量配置有问题,后面多了*符号。

把export HADOOP_CLASSPATH=$HIVE_HOME/lib/*改成export HADOOP_CLASSPATH=$HIVE_HOME/lib就可以了。

[hdfs@centos lib]$ cat /etc/profile

### hive
export HIVE_HOME=/usr/local/hive23
export HADOOP_CLASSPATH=$HIVE_HOME/lib/*
export PATH=$PATH:$HIVE_HOME/bin:$HADOOP_CLASSPATH

  

## 修改配置
[hdfs@centos lib]$ cat /etc/profile ### hive
export HIVE_HOME=/usr/local/hive23
export HADOOP_CLASSPATH=$HIVE_HOME/lib
export PATH=$PATH:$HIVE_HOME/bin:$HADOOP_CLASSPATH [hdfs@centos lib]$ source /etc/profile

  

【Hive报错】java.lang.NoSuchMethodError(com.facebook.fb303.FacebookService$Client.sendBaseOneway的更多相关文章

  1. Spring boot Unable to start embedded Tomcat报错 java.lang.NoSuchMethodError: javax.servlet.ServletContext.getVirtualServerName()

    Spring boot Unable to start embedded Tomcat 报错 java.lang.NoSuchMethodError: javax.servlet.ServletCon ...

  2. resin下发布项目报错java.lang.NoSuchMethodError: javax.persistence.Table.indexes()[Ljavax/persistence/Index

    我的resin版本为4.0.56; 项目在tomcat下启动正常,打包在resin下发布时报错:java.lang.NoSuchMethodError: javax.persistence.Table ...

  3. hive 使用where条件报错 java.lang.NoSuchMethodError: org.apache.hadoop.hive.ql.ppd.ExprWalkerInfo.getConvertedNode

    hadoop 版本 2.6.0 hive版本 1.1.1 错误: java.lang.NoSuchMethodError: org.apache.hadoop.hive.ql.ppd.ExprWalk ...

  4. tomcat7 启动项目报错 java.lang.NoSuchMethodError: javax.servlet.ServletContext.getSessionCookieConfig()

    JDK版本:jdk1.8.0_77 Tomcat 版本:apache-tomcat-7.0.47 异常重现步骤: 1.完成项目部署 2.启动Tomcat 异常头部信息:java.lang.NoSuch ...

  5. pagehelper调用mybatis报错java.lang.NoSuchMethodError:org.apache.ibatis.reflection.MetaObject.forObject

    最近在升新的基础框架到spring cloud,启动时pagehelper报错,如下: java.lang.NoSuchMethodError:org.apache.ibatis.reflection ...

  6. springboot与springcloud版本不对应导致报错java.lang.NoSuchMethodError: org.springframework.boot.builder.SpringApplicationBuilder.<init>([Ljava/lang/Object;)V

    springboot启动报错: 10:31:50.221 [main] ERROR org.springframework.boot.SpringApplication - Application r ...

  7. new AppiumDriver<>(new URL(url), capabilities) 报错 java.lang.NoSuchMethodError: com.google.common.base.Throwables.throwIfUnchecked(Ljava/lang/Throwable;)V

    2017-10-11 17:37:02.102 INFO c.u.a.r.PrepareDriver:41 - appium server url : http://127.0.0.1:4723/wd ...

  8. selenium 打开浏览器报错java.lang.NoSuchMethodError: org.openqa.selenium.chrome.ChromeOptions.addArguments([Ljava/lang/String;)

    java.lang.NoSuchMethodError: org.openqa.selenium.chrome.ChromeOptions.addArguments([Ljava/lang/Strin ...

  9. 使用POI操作Excel时new XSSFWorkbook ()报错java.lang.NoSuchMethodError解决方式

    使用最新的POI3.11时,在执行 Workbook  workBook = new XSSFWorkbook ();这段代码时出现错误: java.lang.NoSuchMethodError: j ...

  10. hive 报错 java.lang.RuntimeException: Unable to instantiate org.apache.hadoop.hive.metastore.HiveMetaStoreClient

    Exception in thread "main" java.lang.RuntimeException: java.lang.RuntimeException: Unable ...

随机推荐

  1. Threading Programming Guide:Thread Management

    Thread Cost 创建线程是有开销的,这些开销主要包括空间上的开销以及时间上的开销:在kernel里面分配存储空间,用来存储线程相关的数据和属性:线程的栈空间:线程创建的时间.总结如下: Ite ...

  2. css样式相关的惊艳的属性

    CSS gap 简写属性用于设置行与列之间的间隙(网格间距). 规范的早期版本将该属性命名为 grid-gap,且为了保持与旧网站的兼容性,浏览器仍然会接受 grid-gap 作为 gap 的别名. ...

  3. Calcite sql2rel 过程

    sql2rel的过程是将SqlNode 转化成RelNode的过程 在 SqlToRelConverterTest中添加样例测试 @Test void testScan() { String sql ...

  4. 2023最新nacos的windows 10安装(保姆级)

    目录 前景提要 一.环境整合 构建工具(参考工具部署方式) 二.找到下载位置 1.在百度中找到下载地址.搜索nacos中文官网. 2.双击进入这个网站,看到首页找到下载位置. 3.进入git地址找到如 ...

  5. pageoffice6提取word指定位置(数据区域)的值

    在实际的开发过程中,经常会遇到提取Word文档中指定位置的数据保存到数据库中的需求,PageOffice客户端控件即支持在线保存Word文件,也支持Word文档中的指定位置的数据或所有的数据提交到服务 ...

  6. 虚拟机上k8s部署好的第二天用时总是出现的各种问题

    open /run/flannel/subnet.env: no such file or directory open /run/flannel/subnet.env: no such file o ...

  7. vulnhub --> Web Machine: (N7)

    靶场下载地址 Web Machine: (N7) << 点我 开始打靶 ip发现: nmap扫描网段发现靶机ip:192.168.56.101 端口发现: 对靶机进行常规端口扫描 访问网站 ...

  8. 从需求角度介绍PasteSpider(K8S平替部署工具适合于任何开发语言)

    你是否被K8S的强大而吸引,我相信一部分人是被那复杂的配置和各种专业知识而劝退,应该还有一部分人是因为K8S太吃资源而放手! 这里介绍一款平替工具PasteSpider,PasteSpider是一款使 ...

  9. 关于MySQL数据库大字符串存取 类型选择

    摘自:https://blog.csdn.net/weixin_40485506/article/details/83588169 关于MySQL数据库存储大字符串类型长度 根据所要存取字符长度及My ...

  10. 改造 Kubernetes 自定义调度器

    原文出处:改造 Kubernetes 自定义调度器 | Jayden's Blog (jaydenchang.top) Overview Kubernetes 默认调度器在调度 Pod 时并不关心特殊 ...