hive-0.13.1启动缓慢的原因

发现时间主要消耗在以下3个地方:

1. hadoopjar的时候要把相关的jar包上传到hdfs中(这里大概消耗5s,hive0.11一样,这个地方不太好优化)

2. 在每次hive cli启动的时候,初始化HiveMetaStore时,在init时,会调用以下3个方法,创建default db,role ,admin。

详细代码:

synchronized(HMSHandler.class) {

createDefaultDB();

createDefaultRoles();

addAdminUsers();

}synchronized(HMSHandler.class) {

createDefaultDB();

createDefaultRoles();

addAdminUsers();

}

生成环境这些都是有的,不须要每次都创建。这里能够直接凝视掉.

3. 还有5s是在载入.hiverc的文件时造成的。

在做Create function的analyze时。会通过FunctionSemanticAnalyzer类的addEntities方法操作元数据。在hive0.11中是没有这种方法的。

关于这种方法。看说明是和function的权限有关系的,我们眼下不须要。

Add writeentities to the semantic analyzer to restrict function creation to priviligedusers.

在測试环境直接凝视掉没有发现什么影响。

详细实现放在后面分析。

解决方式:

14/09/0116:06:12 INFO Configuration.deprecation: mapred.reduce.tasks is deprecated.Instead, use mapreduce.job.reduces

14/09/0116:06:12 INFO Configuration.deprecation: mapred.min.split.size is deprecated.Instead, use mapreduce.input.fileinputformat.split.minsize

14/09/0116:06:12 INFO Configuration.deprecation:mapred.reduce.tasks.speculative.execution is deprecated. Instead, usemapreduce.reduce.speculative

14/09/0116:06:12 INFO Configuration.deprecation: mapred.min.split.size.per.node isdeprecated. Instead, use mapreduce.input.fileinputformat.split.minsize.per.node

14/09/0116:06:12 INFO Configuration.deprecation: mapred.input.dir.recursive isdeprecated. Instead, use mapreduce.input.fileinputformat.input.dir.recursive

14/09/0116:06:12 INFO Configuration.deprecation: mapred.min.split.size.per.rack isdeprecated. Instead, use mapreduce.input.fileinputformat.split.minsize.per.rack

14/09/0116:06:12 INFO Configuration.deprecation: mapred.max.split.size is deprecated.Instead, use mapreduce.input.fileinputformat.split.maxsize

14/09/0116:06:12 INFO Configuration.deprecation:mapred.committer.job.setup.cleanup.needed is deprecated. Instead, usemapreduce.job.committer.setup.cleanup.needed

Logginginitialized using configuration infile:/usr/local/hive-0.13.0/conf/hive-log4j.properties

hive>

上面的一些启动信息就是:

Mysql的初始化信息,

须要设置mysql服务自己主动启动

hive cli 启动缓慢问题的更多相关文章

  1. Hive 学习之路(三)—— Hive CLI和Beeline命令行的基本使用

    一.Hive CLI 1.1 Help 使用hive -H或者 hive --help命令可以查看所有命令的帮助,显示如下: usage: hive -d,--define <key=value ...

  2. Hive 系列(三)—— Hive CLI 和 Beeline 命令行的基本使用

    一.Hive CLI 1.1 Help 使用 hive -H 或者 hive --help 命令可以查看所有命令的帮助,显示如下: usage: hive -d,--define <key=va ...

  3. Hive 教程(六)-Hive Cli

    hive 有两种启动方式,一种是 bin/hive,一种是 hiveserver2, bin/hive 是 hive 的 shell 模式,所有任务在 shell 中完成,shell 就相当于 hiv ...

  4. beeline vs hive cli

    近期,大数据开发环境升级为cloudera 5.3. 配套的hive版本升级为0.13.1.可以使用心仪已久的分析开窗函数了.但在使用的过程中发现一些问题,仅记于此. 1.在使用hive命令的时候,发 ...

  5. Hive cli源码阅读和梳理

    对Cli的重新认识*). hive cli有两种模式, 本地模式: 采用持有的driver对象来处理, 远程模式: 通过连接HiveServer来实现, 由此可见之前的架构图中的描述还是模糊且带有误导 ...

  6. 解决logstash启动缓慢问题

    在部署logstash时,头几次启动时长还可以,最后高达半小时以上启动启动不了,上网查资料说,系统的“熵”过低,导致jruby启动缓慢.需要安装haveged.但是我安装完后还是慢 https://h ...

  7. Hive官方使用手册——新Hive CLI(Beeline CLI)

    Hive官方使用手册——新Hive CLI(Beeline CLI) https://blog.csdn.net/maizi1045/article/details/79481686

  8. Hue中hive(hive cli)查询结果中显示列名,不带表名

    hive cli中显示列名 进入hive cli后 set hive.cli.print.header=true; 之后出现列名,但是带了表名前缀,由于网上没找到资料,于是到官网肉眼扫描所有参数,总算 ...

  9. 全网最详细的hive-site.xml配置文件里添加<name>hive.cli.print.header</name>和<name>hive.cli.print.current.db</name>前后的变化(图文详解)

    不多说,直接上干货! 比如,你是从hive-default.xml.template,复制一份,改名为hive-site.xml 一般是 <configuration> <prope ...

随机推荐

  1. debian 中的jdk

    1 openjdk 2 debian安装java的脚本 3 下载bin自己编译

  2. luogu1129 [ZJOI2007]矩阵游戏

    其实,只用考虑某一行能否放到某一行就行了 #include <iostream> #include <cstring> #include <cstdio> usin ...

  3. 最短路POJ 1062 昂贵的聘礼

    C - 昂贵的聘礼 Time Limit:1000MS     Memory Limit:10000KB     64bit IO Format:%I64d & %I64u Submit St ...

  4. SPOJ - DQUERY 主席树求区间有多少个不同的数(模板)

    D-query Time Limit: 227MS   Memory Limit: 1572864KB   64bit IO Format: %lld & %llu Submit Status ...

  5. USACO Runaround Numbers

    题目大意:问最近的比n大的循环数是多少 思路:第n遍暴力大法好 /*{ ID:a4298442 PROB:runround LANG:C++ } */ #include<iostream> ...

  6. ecplise 使用快捷键

    1. [ALT+/]    此快捷键为用户编辑的好帮手,能为用户提供内容的辅助,不要为记不全方法和属性名称犯愁,当记不全类.方法和属性的名字时,多体验一下[ALT+/]快捷键带来的好处吧.    2. ...

  7. 【leetcode dp】Dungeon Game

    https://leetcode.com/problems/dungeon-game/description/ [题意] 给定m*n的地牢,王子初始位置在左上角,公主在右下角不动,王子要去救公主,每步 ...

  8. 转载:hmm学习网站

    http://www.52nlp.cn/hmm-learn-best-practices-seven-forward-backward-algorithm-5

  9. nmon性能分析工具(生成图表)

    1. nmon性能结果生成报告工具下载地址: https://www.ibm.com/developerworks/community/wikis/home?lang=en#!/wiki/Power% ...

  10. ElasticSearch中Date

    ElasticSearch中有时会想要通过索引日期来筛选查询的数据,此时就需要用到日期数学表达式. 比如现在的时间是2024年3月22日中午12点.utc 注意,如果是中国的时间需要加上8个小时! 表 ...