由于把hadoop的以下配置项

<property>

<name>fs.defaultFS</name>

<value>hdfs://localhost:9000</value>

</property>

改为

<property>

<name>fs.defaultFS</name>

<value>hdfs://192.168.65.128:9000</value>

</property>

导致hive select的时候出现以下错误:

SemanticException Unable to determine if hdfs://localhost:9000/user/hive/warehouse/t1.db/student is encrypted: org.apache.hadoop.hive.ql.metadata.HiveException: java.net.ConnectException: Call From localhost/127.0.0.1 to localhost:9000 failed on connection exception: java.net.ConnectException: Connection refused; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused

这种情况一般是hive的数据存储路径不对,直接去mysql里修改hive的原数据就可以:

mysql执行如下命令:

use hive;

update DBS set DB_LOCATION_URI=REPLACE (DB_LOCATION_URI,'localhost','192.168.65.128')

update SDS set LOCATION=REPLACE (LOCATION,'localhost','192.168.65.128');

借鉴:

hive select 出现问题 SemanticException的更多相关文章

  1. 记hive select distinct 多列 误区一则

    当select distinct a,b,c时,只会对a.b.c都起作用,无法达到只顾虑多余的a列: 根据hive官方网站说明:当有表 a b 10 1 10  2 10 3 此时select a,b ...

  2. 【原创】大叔经验分享(33)hive select count为0

    hive建表后直接将数据文件拷贝到table目录下,select * 可以查到数据,但是select count(1) 一直返回0,这个是因为hive中有个配置 hive.stats.autogath ...

  3. [Hive - LanguageManual] Select base use

    Select Syntax WHERE Clause ALL and DISTINCT Clauses Partition Based Queries HAVING Clause LIMIT Clau ...

  4. Hive 编程之DDL、DML、UDF、Select总结

    Hive的基本理论与安装可参看作者上一篇博文<Apache Hive 基本理论与安装指南>. 一.Hive命令行 所有的hive命令都可以通过hive命令行去执行,hive命令行中仍有许多 ...

  5. hive基本的操作语句(实例简单易懂,create table XX as select XX)

    hive建表语句DML:https://cwiki.apache.org/confluence/display/Hive/LanguageManual+DDL#LanguageManualDDL-Cr ...

  6. Hive基本语法操练

    建表规则如下: CREATE [EXTERNAL] TABLE [IF NOT EXISTS] table_name [(col_name data_type [COMMENT col_comment ...

  7. Hive(六):HQL DDL

    HQL语法基于 SqlLine(http://sqlline.sourceforge.net/),DDL主要包含数据库.函数.视图的创建.修改.删除,参考资料:(https://cwiki.apach ...

  8. Hive中的排序语法

    ORDER BY hive中的ORDER BY语句和关系数据库中的sql语法相似.他会对查询结果做全局排序,这意味着所有的数据会传送到一个Reduce任务上,这样会导致在大数量的情况下,花费大量时间. ...

  9. HIVE快速入门

    (一)简单入门 1.创建一个表 create table if not exists ljh_emp( name string, salary float, gender string) commen ...

随机推荐

  1. 2019 魔域java面试笔试题 (含面试题解析)

      本人5年开发经验.18年年底开始跑路找工作,在互联网寒冬下成功拿到阿里巴巴.今日头条.魔域等公司offer,岗位是Java后端开发,因为发展原因最终选择去了魔域,入职一年时间了,也成为了面试官,之 ...

  2. pandas-12 数学计算操作df.sum()、df.min()、df.max()、df.decribe()

    pandas-12 数学计算操作df.sum().df.min().df.max().df.decribe() 常用的数学计算无非就是加减,最大值最小值,方差等等,pandas已经内置了很多方法来解决 ...

  3. 【转载】 C#中List集合使用OrderByDescending方法对集合进行倒序排序

    在C#的List集合操作中,有时候需要针对List集合进行排序操作,如果是对List集合按照元素对象或者元素对象的某个属性进行倒序排序的话,可以使用OrderByDescending方法来实现,Ord ...

  4. v-for循环列表,展开样式随手风琴

    <div class="product_box" v-for="(item,index) of kinds" :key="index" ...

  5. Tensorflow替换静态图中的OP

    import tensorflow as tf import collections from tensorflow.core.framework import tensor_shape_pb2 # ...

  6. dexlib2的源码框架

    这个是dexlib2的目录,明显看出来比baksmali和smali代码量要多很多,这里先将核心目录给大家做一下介绍 analysis 这个暂时不知道具体作用 base     这个文件夹下面全部都是 ...

  7. 解决加载WEB页面时,由于JS文件引用过多影响页面打开速度的问题

    1.一般做法 一般我们会把所有的<script>元素都应该放在页面的<head>标签里,但由于是顺序加载,因此只有当所有JavaScript代码都被依次下载.解析和执行完之后, ...

  8. 异常详细信息: System.MissingMethodException: 无法创建抽象类。

    asp.net mvc 在使用post向后端传送json数据时报异常,在路由配置中添加如下即可 public static void RegisterRoutes(RouteCollection ro ...

  9. steam相关插件

    批量激活key:https://greasyfork.org/zh-CN/scripts/32718-steamredeemkeys 批量卖卡:https://github.com/Nuklon/St ...

  10. Centos7-重建官方yum源

    删除yum源,重建官方 cd /etc/yum.repos.d/ #删除所有 rpm -Uvh --force http://mirror.centos.org/centos-7/7.7.1908/o ...