Zeppelin0.8 安装,连接Hive1.2.1

  • 环境:

CentOS6.5
Hadoop2.7.2
Hive1.2.1

  • 安装
    下载,解压
tar -zxvf zeppelin-0.8.0-bin-all.tgz -C /opt/module/
ln -s zeppelin-0.8.0-bin-all  zeppelin
  • 环境变量配置
    cd zeppelin/conf/

1.zeppelin-env.sh

cp zeppelin-env.sh.template zeppelin-env.sh
vim zeppelin-env.sh


 #添加下列配置

#JAVA_HOME
#export JAVA_HOME=/opt/module/jdk1.8.0_144

export JAVA_HOME=/opt/module/jdk
export PATH=$PATH:$JAVA_HOME/bin

#HADOOP_HOME
export HADOOP_HOME=/opt/module/hadoop
export PATH=$PATH:$HADOOP_HOME/bin
export PATH=$PATH:$HADOOP_HOME/sbin
export HADOOP_CONF_DIR=/opt/module/hadoop/etc/hadoop

2.zeppelin-site.xml

cp zeppelin-site.xml.template zeppelin-site.xml
vim zeppelin-site.xml



 
 
 
   zeppelin.server.addr
   hadoop01
   Server address
 
 
 
   zeppelin.server.port
   18080
   Server port.
 
 
 
   zeppelin.server.ssl.port
   8443
   Server ssl port. (used when ssl property is set to true)
 
 
 
   zeppelin.server.context.path
   /
   Context Path of the Web Application
 
 
 
   zeppelin.war.tempdir
   webapps
   Location of jetty temporary directory
 
 
 
   zeppelin.notebook.dir
   notebook
   path or URI for notebook persist
 
 
 
   zeppelin.notebook.homescreen
   
   id of notebook to be displayed in homescreen. ex) 2A94M5J1Z Empty value displays default home screen
 
 
 
   zeppelin.notebook.homescreen.hide
   false
   hide homescreen notebook from list when this value set to true
 

3.shiro.ini

vim shiro.ini
(在这行附近,添加下面一行)
#admin = password1, admin
#user1 = admin, admin, admin (在这行附近,添加下面一行)
admin = admin, admin

4.Hive的相关配置

cd $HIVE_HOME/conf
vim hive-site.xml
添加如下配置,看注释了解详情.

    
        hive.metastore.local
        false
    
    

    
    
       hive.server2.thrift.port
       10000
    
    
      hive.server2.thrift.bind.host
      hadoop01
    


    
    
            hive.metastore.uris
            thrift://hadoop01:9083
            
    
  • 连接Hive配置
    启动zeppelin:
 zeppelin-daemon.sh start

浏览器打开 hadoop01:18080,输入账密登录 : admin admin

image.png

点击 admin的下三角,interpreter,右上角create

image.png

输入名字,现在jdbc,

输入名字,点edit

配置如下:

如图1:


image.png

如图2:


image.png
  • 建议:

$HIVE_HOME/lib下面所有的jar包拷贝到$ZEPPELIN_HOME/ lib里面.
然后在找一些需要的jar包. 复制其绝对路径到zeppelin配置页面的edit页面最下面的依赖中去.

artifact
/opt/module/zeppelin/ib/guava-14.0.1jar
/opt/module/zeppeln/lib/nive-serde-1.2.1.jar
/opt/module/zeppelin/lib/hive-common-1.2.1.jar
/opt/module/zeppelin/ib/hive-cli-1.2.1.jar
/opt/module/zeppelin/lib/hive-service-rpc-2.1.0jar
/opt/module/zeppelin/ib/hive-service-1.2.1jar
/opt/module/zeppeln/lib/nive-jdbc-1.2.1jar
/opt/module/apache-hive- 1.2.1-bin/ib/mysql-connectorjava-5.1.27-bin.jar
/optmodule/apache-hive-1.2. 1-bin/ib/hive-metastore-1.2.1.jar

你可能感兴趣的:(Zeppelin0.8 安装,连接Hive1.2.1)