hue报错StructuredException: timed out (code THRIFTSOCKET): None的处理
通过hue的web界面进行hive的sql查询,无法显示结果并报错timeout
报错如下:
[28/Jul/2017 11:23:29 +0800] decorators ERROR error running <function execute at 0x7fa741ddc8c0>
Traceback (most recent call last):
File "/home/hadoop/.versions/hue-3.10.0/desktop/libs/notebook/src/notebook/decorators.py", line 81, in decorator
return func(*args, **kwargs)
File "/home/hadoop/.versions/hue-3.10.0/desktop/libs/notebook/src/notebook/api.py", line 109, in execute
response['handle'] = get_api(request, snippet).execute(notebook, snippet)
File "/home/hadoop/.versions/hue-3.10.0/desktop/libs/notebook/src/notebook/connectors/hiveserver2.py", line 64, in decorator
return func(*args, **kwargs)
File "/home/hadoop/.versions/hue-3.10.0/desktop/libs/notebook/src/notebook/connectors/hiveserver2.py", line 199, in execute
db.use(query.database)
File "/home/hadoop/.versions/hue-3.10.0/apps/beeswax/src/beeswax/server/dbms.py", line 613, in use
return self.client.use(query)
File "/home/hadoop/.versions/hue-3.10.0/apps/beeswax/src/beeswax/server/hive_server2_lib.py", line 1053, in use
data = self._client.execute_query(query)
File "/home/hadoop/.versions/hue-3.10.0/apps/beeswax/src/beeswax/server/hive_server2_lib.py", line 748, in execute_query
return self.execute_query_statement(statement=query.query['query'], max_rows=max_rows, configuration=configuration)
File "/home/hadoop/.versions/hue-3.10.0/apps/beeswax/src/beeswax/server/hive_server2_lib.py", line 752, in execute_query_statement
(results, schema), operation_handle = self.execute_statement(statement=statement, max_rows=max_rows, configuration=configuration, orientation=orientation)
File "/home/hadoop/.versions/hue-3.10.0/apps/beeswax/src/beeswax/server/hive_server2_lib.py", line 780, in execute_statement
res = self.call(self._client.ExecuteStatement, req)
File "/home/hadoop/.versions/hue-3.10.0/apps/beeswax/src/beeswax/server/hive_server2_lib.py", line 625, in call
res = fn(req)
File "/home/hadoop/.versions/hue-3.10.0/desktop/core/src/desktop/lib/thrift_util.py", line 376, in wrapper
raise StructuredException('THRIFTSOCKET', str(e), data=None, error_code=502)
StructuredException: timed out (code THRIFTSOCKET): None
解决方法:
修改配置文件
/home/hadoop/.versions/hue-3.10.0/desktop/conf/hue.ini
server_conn_timeout=120
改为,重启hue服务,好像没用
server_conn_timeout=1200
搜索了下网上说,如果通过Hue的web来执行Hive查询,需要启动HiveServer2服务
查看配置conf/hue.ini,连接的是uhadoop-bwgkeu-master2的10000端口,连接这个master2通过ps -ef|grep hive发现已经启动了的,于是重启服务,问题解决
[hadoop@uhadoop-bwgkeu-master2 log]$ ps -ef|grep hive
hadoop : ? :: /usr/java/jdk1..0_60/bin/java -Xmx1024m -Dhive.log.dir=/var/log/hive -Dhive.log.file=hive-server2.log -Dhive.log.threshold=INFO -Djava.net.preferIPv4Stack=true -Dhadoop.log.dir=/home/hadoop/logs -Dhadoop.log.file=hadoop.log -Dhadoop.home.dir=/home/hadoop -Dhadoop.id.str=hadoop -Dhadoop.root.logger=INFO,console -Djava.library.path=/home/hadoop/lib/native -Dhadoop.policy.file=hadoop-policy.xml -Djava.net.preferIPv4Stack=true -Xmx1000m -Xmx4096m -Xms1024m -XX:NewRatio= -XX:MaxHeapFreeRatio= -XX:MinHeapFreeRatio= -XX:+UseParNewGC -XX:-UseGCOverheadLimit -Dhadoop.security.logger=INFO,NullAppender org.apache.hadoop.util.RunJar /home/hadoop/hive/lib/hive-service-1.2..jar org.apache.hive.service.server.HiveServer2 --hiveconf hive.aux.jars.path=file:///home/hadoop/hbase/lib/activation-1.1.jar,file:///home/hadoop/hbase/lib/antisamy-1.4.3.jar,file:///home/hadoop/hbase/lib/apacheds-i18n-2.0.0-M15.jar,file:///home/hadoop/hbase/lib/apacheds-kerberos-codec-2.0.0-M15.jar,file:///home/hadoop/hbase/lib/api-asn1-api-1.0.0-M20.jar,file:///home/hadoop/hbase/lib/api-util-1.0.0-M20.jar,file:///home/hadoop/hbase/lib/asm-3.2.jar,file:///home/hadoop/hbase/lib/avro-1.7.6-cdh5.8.0.jar,file:///home/hadoop/hbase/lib/aws-java-sdk-core-1.10.6.jar,file:///home/hadoop/hbase/lib/aws-java-sdk-kms-1.10.6.jar,file:///home/hadoop/hbase/lib/aws-java-sdk-s3-1.10.6.jar,file:///home/hadoop/hbase/lib/batik-css-1.7.jar,file:///home/hadoop/hbase/lib/batik-ext-1.7.jar,file:///home/hadoop/hbase/lib/batik-util-1.7.jar,file:///home/hadoop/hbase/lib/bsh-core-2.0b4.jar,file:///home/hadoop/hbase/lib/commons-beanutils-1.7.0.jar,file:///home/hadoop/hbase/lib/commons-beanutils-core-1.7.0.jar,file:///home/hadoop/hbase/lib/commons-cli-1.2.jar,file:///home/hadoop/hbase/lib/commons-codec-1.9.jar,file:///home/hadoop/hbase/lib/commons-collections-3.2.2.jar,file:///home/hadoop/hbase/lib/commons-compress-1.4.1.jar,file:///home/hadoop/hbase/lib/commons-configuration-1.6.jar,file:///home/hadoop/hbase/lib/commons-daemon-1.0.3.jar,file:///home/hadoop/hbase/lib/commons-digester-1.8.jar,file:///home/hadoop/hbase/lib/commons-el-1.0.jar,file:///home/hadoop/hbase/lib/commons-fileupload-1.2.jar,file:///home/hadoop/hbase/lib/commons-httpclient-3.1.jar,file:///home/hadoop/hbase/lib/commons-io-2.4.jar,file:///home/hadoop/hbase/lib/commons-lang-2.6.jar,file:///home/hadoop/hbase/lib/commons-logging-1.2.jar,file:///home/hadoop/hbase/lib/commons-math-2.1.jar,file:///home/hadoop/hbase/lib/commons-math3-3.1.1.jar,file:///home/hadoop/hbase/lib/commons-net-3.1.jar,file:///home/hadoop/hbase/lib/core-3.1.1.jar,file:///home/hadoop/hbase/lib/curator-client-2.7.1.jar,file:///home/hadoop/hbase/lib/curator-framework-2.7.1.jar,file:///home/hadoop/hbase/lib/curator-recipes-2.7.1.jar,file:///home/hadoop/hbase/lib/disruptor-3.3.0.jar,file:///home/hadoop/hbase/lib/esapi-2.1.0.jar,file:///home/hadoop/hbase/lib/findbugs-annotations-1.3.9-1.jar,file:///home/hadoop/hbase/lib/gson-2.2.4.jar,file:///home/hadoop/hbase/lib/guava-12.0.1.jar,file:///home/hadoop/hbase/lib/hadoop-annotations-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-auth-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-aws-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-client-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-common-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-hdfs-2.6.0-cdh5.4.9-tests.jar,file:///home/hadoop/hbase/lib/hadoop-hdfs-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-mapreduce-client-app-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-mapreduce-client-common-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-mapreduce-client-core-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-mapreduce-client-jobclient-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-mapreduce-client-shuffle-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-yarn-api-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-yarn-client-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-yarn-common-2.6.0-cdh5.4.9.jar,file:///home/hadoop/hbase/lib/hadoop-yarn-server-commo
hadoop Jun28 ? :: /usr/java/jdk1..0_60/bin/java -Xmx1024m -Dhive.log.dir=/var/log/hive -Dhive.log.file=hive-metastore.log -Dhive.log.threshold=INFO -Djava.net.preferIPv4Stack=true -Dhadoop.log.dir=/home/hadoop/logs -Dhadoop.log.file=hadoop.log -Dhadoop.home.dir=/home/hadoop -Dhadoop.id.str=hadoop -Dhadoop.root.logger=INFO,console -Djava.library.path=/home/hadoop/lib/native -Dhadoop.policy.file=hadoop-policy.xml -Djava.net.preferIPv4Stack=true -Xmx1000m -Xmx4096m -Xms1024m -XX:NewRatio= -XX:MaxHeapFreeRatio= -XX:MinHeapFreeRatio= -XX:+UseParNewGC -XX:-UseGCOverheadLimit -Dhadoop.security.logger=INFO,NullAppender org.apache.hadoop.util.RunJar /home/hadoop/hive/lib/hive-service-1.2..jar org.apache.hadoop.hive.metastore.HiveMetaStore
hadoop Jun28 ? :: /usr/java/jdk1..0_60/bin/java -cp /home/hadoop/lib/hadoop-lzo.jar:/home/hadoop/share/hadoop/common/*:/home/hadoop/share/hadoop/common/lib/*:/home/hadoop/share/hadoop/yarn/*:/home/hadoop/share/hadoop/yarn/lib/*:/home/hadoop/spark/lib/*:/home/hadoop/hive/lib/*:/home/hadoop/hbase/lib/*:/home/hadoop/spark/conf/:/home/hadoop/spark/jars/*:/home/hadoop/conf/ -Xmx1g -XX:MaxPermSize=256m org.apache.spark.deploy.history.HistoryServer
配置文件说明:
[beeswax]
hive_server_host=uhadoop-bwgkeu-master2 # 连接hive的服务器
hive_server_port= # hiveserver2的端口
hive_conf_dir=/home/hadoop/hive/conf # 配置文件
server_conn_timeout= # 超时实际
主机映射关系
# cat /etc/hosts 10.19.128.248 uhadoop-bwgkeu-master1
10.19.196.141 uhadoop-bwgkeu-core4
10.19.80.123 uhadoop-bwgkeu-core2
10.19.185.160 uhadoop-bwgkeu-core1
10.19.91.236 uhadoop-bwgkeu-core3
10.19.72.208 uhadoop-bwgkeu-master2
简单的hive查询验证是否能够正常查询:
SELECT s07.description, s07.salary, s08.salary,
s08.salary - s07.salary
FROM
sample_07 s07 JOIN sample_08 s08
ON ( s07.code = s08.code)
WHERE
s07.salary < s08.salary
ORDER BY s08.salary-s07.salary DESC
LIMIT 1000
简单hive查询的例子
SELECT s07.description, s07.salary
FROM
sample_07 s07
LIMIT 10
hive_shell查询:
# hive
hive> select * from tbl_push_user_req limit ;
hue报错StructuredException: timed out (code THRIFTSOCKET): None的处理的更多相关文章
- 解决hue报错:timed out (code THRIFTSOCKET): None
报错栈: [/Jun/ :: +] decorators ERROR error running <function execute at 0x7fba2804ecf8> Tracebac ...
- hue解决timed out(code THRIFTSOCKET):None
报错栈: Traceback (most recent call last): File , in decorator return func(*args, **kwargs) File , in e ...
- http报错之return error code:401 unauthorized
http报错之return error code:401 unauthorized 依据HTTP返回码所表示的意思应该是未授权,没有输入账号和password,因此解决方法就直接在HTTP包里面 ...
- nginx 报错 upstream timed out (110: Connection timed out)解决方案【转】
转自 nginx 报错 upstream timed out (110: Connection timed out)解决方案 - 为程序员服务http://outofmemory.cn/code-sn ...
- 执行npm install报错:npm ERR! code EINTEGRITY
命令行执行npm install报错如下: D:\frontend\viewsdev>npm install npm ERR! code EINTEGRITY npm ERR! sha512-8 ...
- xdebug 一直报错 upstream timed out (110: Connection timed out) while reading response header from upstream
本地主机(Windows环境192.168.66.1)访问虚拟机(192.168.66.139)里面的搭建的php环境(系统centos6.5版本,php版本是5.5.30 ,xdebug 2.4.0 ...
- 安装xcode6 beta 后调试出现Unable to boot the iOS Simulator以及编译苹果官方Swift的demo报错failed with exit code 1的解决的方法
苹果昨天公布新语言Swift(雨燕),须要安装xcode6 以及mac os 系统为10.9以上. (xcode6 beta 可在官方下载.须要登录开发人员账号:mac os 系统直接更新就可以.在此 ...
- hive报错 Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. MetaException(message:For direct MetaStore DB connections,
学习hive 使用mysql作为元数据 hive创建数据库和切换数据库都是可以的 但是创建表就是出问题 百度之后发现 是编码问题 特别记录一下~~~ 1.报错前如图: 2.在mysql数据库中执行如 ...
- hive 字符集问题 报错 Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. MetaException(message:For direct MetaStore DB connections,
学习hive 使用mysql作为元数据 hive创建数据库和切换数据库都是可以的 但是创建表就是出问题 百度之后发现 是编码问题 特别记录一下~~~ 1.报错前如图: 2.在mysql数据库中执行如 ...
随机推荐
- appcms SSRF 绕过漏洞[转载]
漏洞 <?php if(isset($_GET['url']) && trim($_GET['url']) != '' && isset($_GET['type' ...
- 【自适应波束形成】MVDR(Minimum Variance Distortionless Response )笔记
参考: https://blog.csdn.net/qq_40981790/article/details/80143524 1. MVDR简介(Minimum Variance Distortion ...
- Linux系统中用户组、文件权限浅解
用户组 在linux中的每个用户必须属于一个组,不能独立于组外.在Linux中每个文件有所有者.所在组.其它组的概念. [所有者] 一般为文件的创建者,谁创建了该文件,就天然的成为该文件的所有者,用& ...
- python模块之os sys shutil
os模块 os模块是与操作系统交互的一个接口 #当前执行这个python文件的工作目录相关的工作路径 os.getcwd() 获取当前工作目录,即当前python脚本工作的目录路径 os.chdir( ...
- system.net.webexception远程服务器返回了错误: NotFound。
Not Found类的错误主要是由于网络服务访问出错.所以需要分析是由哪个网络服务访问失败而导致的. DataAccessSilverlight.PowerDataServiceReference.G ...
- Python数据挖掘和机器学习
-----------------------------2017.8.9--------------------------------- 先占个坑 在接下来的一个半月里(即从现在到十一) 我将结合 ...
- 【一】java 虚拟机 监控示例 Eclipse Memory Analyser
1.堆内存溢出示例代码 import java.util.ArrayList; import java.util.List; public class TestHeap { public static ...
- Groovy 设计模式 -- proxy & delegate
Proxy https://en.m.wikipedia.org/wiki/Proxy 代理人 与 被代理人 是 一对一的关系. A proxy is an agent or substitute a ...
- 七、文件IO——I/O处理方式和文件锁
7.1 I/O 处理方式 7.1.1 I/O处理的五种模型 阻塞I/O模型 若所调用的 I/O 函数没有完成相关的功能就会使进程挂起,直到相关数据到达才会返回.如 终端.网络设备的访问. 非阻塞模型 ...
- Restful API学习Day5 - DRF之限制 分页 解析器和渲染器
参考文档: Django REST framework基础:认证.权限.限制 Django REST framework基础:分页 Django REST framework基础:解析器和渲染器 一. ...