1:解压

tar zxf hive-0.12.0-bin.tar.gz

mv hive-0.12.0-bin hadoop

移动到hadoop目录

2:配置环境变量

[jifeng@jifeng02 hive-0.12.0-bin]$ cat ../../.bash_profile
# .bash_profile# Get the aliases and functions
if [ -f ~/.bashrc ]; then. ~/.bashrc
fi# User specific environment and startup programsPATH=$PATH:$HOME/binexport PATH
export JAVA_HOME=$HOME/jdk1.7.0_45
export PATH=$JAVA_HOME/bin:$PATH
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
export HADOOP_HOME=$HOME/hadoop/hadoop-1.2.1
export ANT_HOME=$HOME/apache-ant-1.9.4export HIVE_HOME=$HOME/hadoop/hive-0.12.0-bin
export HBASE_HOME=$HOME/hbase-0.94.21
export PIG_HOME=$HOME/pig-0.12.0
export PIG_CLASSPATH=$HOME/hadoop/hadoop-1.2.1/conf/export PATH=$PATH:$ANT_HOME/bin:$HIVE_HOME/bin::$HBASE_HOME/bin:$PIG_HOME/bin:$HADOOP_HOME/bin
[jifeng@jifeng02 hive-0.12.0-bin]$ 

使用配置生效 source ../../.bash_profile

3:配置Hive

修改conf目录下的文件

[jifeng@jifeng02 hive-0.12.0-bin]$ cd conf
[jifeng@jifeng02 conf]$ mv hive-env.sh.template  hive-env.sh
[jifeng@jifeng02 conf]$ mv hive-default.xml.template  hive-site.xml

修改bin目录下的文件

[jifeng@jifeng02 conf]$ cd ..
[jifeng@jifeng02 hive-0.12.0-bin]$ cd bin
[jifeng@jifeng02 bin]$ cat hive-config.sh
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements.  See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License.  You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.#
# processes --config option from command line
#this="$0"
while [ -h "$this" ]; dols=`ls -ld "$this"`link=`expr "$ls" : '.*-> \(.*\)$'`if expr "$link" : '.*/.*' > /dev/null; thenthis="$link"elsethis=`dirname "$this"`/"$link"fi
done# convert relative path to absolute path
bin=`dirname "$this"`
script=`basename "$this"`
bin=`cd "$bin"; pwd`
this="$bin/$script"# the root of the Hive installation
if [[ -z $HIVE_HOME ]] ; thenexport HIVE_HOME=`dirname "$bin"`
fi#check to see if the conf dir is given as an optional argument
while [ $# -gt 0 ]; do    # Until you run out of parameters . . .case "$1" in--config)shiftconfdir=$1shiftHIVE_CONF_DIR=$confdir;;--auxpath)shiftHIVE_AUX_JARS_PATH=$1shift;;*)break;;;esac
done# Allow alternate conf dir location.
HIVE_CONF_DIR="${HIVE_CONF_DIR:-$HIVE_HOME/conf}"export HIVE_CONF_DIR=$HIVE_CONF_DIR
export HIVE_AUX_JARS_PATH=$HIVE_AUX_JARS_PATH# Default to use 256MB
export HADOOP_HEAPSIZE=${HADOOP_HEAPSIZE:-256}
export JAVA_HOME=$HOME/jdk1.7.0_45
export HIVE_HOME=$HOME/hadoop/hive-0.12.0-bin
export HADOOP_HOME=$HOME/hadoop/hadoop-1.2.1
[jifeng@jifeng02 bin]$ 

最后新加三行

export JAVA_HOME=$HOME/jdk1.7.0_45
export HIVE_HOME=$HOME/hadoop/hive-0.12.0-bin
export HADOOP_HOME=$HOME/hadoop/hadoop-1.2.1

4:启动Hive

先启动hadoop

[jifeng@jifeng02 bin]$ cd ..
[jifeng@jifeng02 hive-0.12.0-bin]$ cd ..
[jifeng@jifeng02 hadoop]$ hiveLogging initialized using configuration in jar:file:/home/jifeng/hadoop/hive-0.12.0-bin/lib/hive-common-0.12.0.jar!/hive-log4j.properties
hive> 

注意:报错—请修改hive-site.xml:(vi编辑下: /auth)

[Fatal Error] hive-site.xml:2002:16: 元素类型 "value" 必须由匹配的结束标记 "</value>" 终止。
14/08/19 15:32:58 FATAL conf.Configuration: error parsing conf file: org.xml.sax.SAXParseException; systemId: file:/home/jifeng/hadoop/hive-0.12.0-bin/conf/hive-site.xml; lineNumber: 2000; columnNumber: 16; 元素类型 "value" 必须由匹配的结束标记 "</value>" 终止。

在2002行第16字符那里  <value>auth</auth>

修改为: <value>auth</value>

hive>show tables;

此时还报错:

FAILED:Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask.java.lang.RuntimeException: Unable to instantiateorg.apache.hadoop.hive.metastore.HiveMetaStoreClient

最后将hive-site.xml 里面hive.metastore.schema.verification 的值改为 false后,就没出现错误了。

Hive 0.12.0安装配置相关推荐

  1. mysql8 win10启动_Windows10 mysql 8.0.12 非安装版配置启动方法

    本文为大家分享了mysql 8.0.12非安装版配置启动的具体步骤,供大家参考,具体内容如下 1.官方下载地址 选择: MySQL Community Edition -> MySQL Comm ...

  2. Pig 0.12.1安装和使用

    1 :安装 解压,配置环境变量,验证 pig安装是否成功 <pre name="code" class="plain">[jifeng@jifeng ...

  3. mysql 12安装教程下载_MySQL 8.0.12.0安装教程

    一.下载mysql-installer-community-8.0.12.0.msi 点击 :下载链接 二.安装mysql-installer-community-8.0.12.0.msi 1.点击安 ...

  4. 2020-10-16FATFS 0.12 ffconf.h配置

    FATFS 0.12 ffconf.h配置 /---------------------------------------------------------------------------/ ...

  5. mysql8.0.17压缩包安装教程_mysql 8.0.16 压缩包安装配置方法图文教程

    本文为大家分享了mysql 8.0.16 压缩包安装配置方法,供大家参考,具体内容如下 运行环境:windows 10 x64 1.下载zip安装包: mysql8.0 for windows zip ...

  6. Minigui3.0.12完美安装

    Minigui3.0.12完美安装,折腾了一天.终于看到了 转载于:https://www.cnblogs.com/liubaocheng999/p/4323414.html

  7. 新版mysql的下载教程_Mysql最新版8.0.21下载安装配置教程详解

    一.下载 1.下载安装包 mysql下载路径:https://dev.mysql.com/downloads/file/?id=496745 2.解压压缩包 解压到安装的目录: 3.在此目录下新建my ...

  8. Android 11.0 12.0在系统app安装第三方app弹出 解析安装包出现问题 的解决方案

    1.概述 在11.0 12.0的系统定制化开发中,对于系统内置app中用代码调用系统安装接口安装app时抛出Permission Denial: that is not exported from U ...

  9. android 11.0 12.0app安装黑名单(限制app安装)

    1.概述 在11.0 12.0定制化开发中,最近由项目需求要实现对某些app应用安装限制也就是app安装黑名单功能,在黑名单之中的应用会被限制安装,不能安装到系统中 功能分析 在系统中PMS就是负责管 ...

  10. WSL 2.0+LAMP+WordPress 安装配置

    长流程WSL2.0+LAMP+WordPress 安装配置 不少小网站跑的WordPress,网上共享空间或者VPS又是Linux系统,所以自己在Windows上搭个仿真的坏境当练手十分好玩.笔者大感 ...

最新文章

  1. oracle sql判断相等,获取多行相等的人员(Oracle SQL)
  2. FFmpeg数据结构:AVPacket解析
  3. 从入门到精通:卷积神经网络初学者指南
  4. go token验证_golang jwt+token验证的实现
  5. Tip3 百度网盘PC版去除广告和游戏运营位教程(百度网盘破解教程)
  6. 基于NLP的中医医案文本快速结构化方法
  7. kibana报错-Login is currently disabled.
  8. 算法练习 - 五笔编码
  9. Word文档中批量修改英文、中文或数字等的字体和格式的方法2
  10. python实现hbase增删改查
  11. 在Mac根目录下创建文件
  12. 第三方SDK编写文档 - iOS
  13. CF1475F Unusual Matrix
  14. 三色灯的点亮逻辑 | 可自定义
  15. 计算机培训教案入门,计算机二级学习基础PPT学习教案.pptx
  16. mysql中拼接字符串
  17. ChatGPT火爆出圈 人工智能赋能银行迈入新时代
  18. 不做经营,一切为0(四)
  19. Android四大组件之广播接收器BroadcastReceiver
  20. 《优秀的绵羊》威廉德雷谢维奇_epub+mobi+azw3

热门文章

  1. 8 MyBatis动态SQL
  2. java md5 密钥_java加密算法--MD5加密和哈希散列带秘钥加密算法源码
  3. mongo的php查询,如何在php中查询mongo?
  4. findbugs插件_提升编码效率的IntelliJ IDEA必备插件
  5. global mapper 制作地形图_福州大飞机模型制作厂家,产品模型,期待合作_境海模型...
  6. 关于点名的简单python编程_如何用python编写一个简易的随机点名软件
  7. 【小白学习tensorflow教程】四、使用 tfhub中的模型EfficientDet-Lite2 进行对象检测
  8. Stanford NLP
  9. 三十二、教你Python制作简单的二维码
  10. mysql存储number_DUMP函数--Oracle是如何在内部存储NUMBER类型的数据?