hive单用户多点模式配置
简介
单用户多点模式也称远程服务模式,用户非java客户端访问元数据库,在服务端启动MetaStoreServer,客户端利用Thrift协议通过MetaStoreServer访问元数据库。
mysql安装以及配置
安装mysql
apt默认安装,占据3306端口
安装机器 : dev01
sudo apt-get install mysql-server
sudo apt-get install mysql-client
配置hive用户
登陆mysql
mysql -u root -p xxxxxx
创建hive用户
create user 'hive'@'%' identified by 'hive';
给hive用户权限
grant all privileges on *.* to 'hive'@'%' with grant option;
flush privileges;
服务端配置
修改 $HIVE_HOME/conf/hive-site.xml
<configuration>
#配置mysql
<property>
<name>javax.jdo.option.ConnectionURL</name>
<value>jdbc:mysql://localhost:3306/hive?createDatabaseIfNotExist=true</value>
<description>JDBC connect string for a JDBC metastore</description>
</property>
<property>
<name>javax.jdo.option.ConnectionDriverName</name>
<value>com.mysql.jdbc.Driver</value>
<description>Driver class name for a JDBC metastore</description>
</property>
<property>
<name>hive.metastore.warehouse.dir</name>
<value>/usr/hive/warehouse</value>
</property>
# 配置MySQL的登录名和密码
<property>
<name>javax.jdo.option.ConnectionUserName</name>
<value>hive</value>
<description>username to use against metastore database</description>
</property>
<property>
<name>javax.jdo.option.ConnectionPassword</name>
<value>hive</value>
<description>password to use against metastore database</description>
</property>
<property>
<name>hive.exec.scratchdir</name>
<value>/usr/hive/tmp</value>
</property>
<property>
<name>hive.querylog.location</name>
<value>/usr/hive/log</value>
</property>
<property>
<name>hive.metastore.uris</name>
<value>thrift://dev01:9083</value>
</property>
</configuration>
客户端配置
修改 $HIVE_HOME/conf/hive-site.xml
<configuration>
# 9083是服务端 metastore 启动以后的默认端口
<property>
<name>hive.metastore.uris</name>
<value>thrift://dev01:9083</value>
<description>IP address (or fully-qualified domain name) and port of the metastore host</description>
</property>
<property>
<name>hive.metastore.warehouse.dir</name>
<value>/usr/hive/warehouse</value>
</property>
<property>
<name>hive.metastore.local</name>
<value>false</value>
</property>
<property>
<name>hive.exec.scratchdir</name>
<value>/usr/hive/tmp</value>
</property>
<property>
<name>hive.querylog.location</name>
<value>/usr/hive/log</value>
</property>
</configuration>
启动hive
服务端
启动metastore
hive --service metastore
客户端
beeline -u jdbc:hive2://
hive单用户多点模式配置的更多相关文章
- centos 单用户登陆模式操作
在centos中因为安装java而配置 jdk环境变量的原因,对/etc/profile文件进行了编辑 错误的环境变量配置导致在第一次修改profile文件并保存后,执行source /etc/pro ...
- 烂泥:vsftpd单用户多目录配置
本文由ilanniweb提供友情赞助,首发于烂泥行天下 想要获得更多的文章,可以关注我的微信ilanniweb. 一.实际问题 在使用vsftpd过程中,我们会经常发现vsftpd在默认情况下一个用户 ...
- lesson - 2 yum /单用户/救援模式/Linux 启动
课程大纲:1. yum使用yum 是一个在线安装软件包的工具,它可以帮我们解决软件包的依赖,这个日后会详细介绍.我们介绍了以下几个用法:yum list 这个命令可以列出所有安装过和未安装的软 ...
- 【基础】centos 6.X 下修改图形界面为命令行界面(单用户救援模式)
1. Linux开机引导的时候,按键盘上的e 就可以进入进入GRUB菜单界面. 2.在出现GRUB引导画面时(CentOS(2.6.18-274**)),按字母e键,进入GRUB编辑状态: 3.把光标 ...
- Linux学习之CentOS(二十二)--单用户模式下修改Root用户的密码
在上一篇随笔里面详细讲解了Linux系统的启动过程 (Linux学习之CentOS(二十一)--Linux系统启动详解),我们知道Linux系统的启动级别一共有6种级别,通过 /etc/inittab ...
- 『学了就忘』Linux启动引导与修复 — 72、Linux系统的修复模式(单用户模式)
目录 1.单用户模式常见的错误修复 2.通过单用户模式修改系统密码 (1)进入grub启动引导程序中 (2)编辑相应的系统启动内容 (3)编辑grub配置文件内容 (4)启动系统 (5)修改root用 ...
- SpringSecurity 3.2入门(3)单用户登录
1.增加web.xml文件配置如下 <!-- 获取Spring Security session的生命周期,这个监听器会在 session 创建和销毁的时候通知 Spring Security ...
- CentOS单用户模式下修改ROOT密码和grub加密
Linux 系统处于正常状态时,服务器主机开机(或重新启动)后,能够由系统引导器程序自动引导 Linux 系统启动到多用户模式,并提供正常的网络服务.如果系统管理员需要进行系统维护或系统出现启动异常时 ...
- centos单用户模式:修改ROOT密码和grub加密
centos单用户模式:修改ROOT密码和grub加密 CentOSLinux网络应用配置管理应用服务器 Linux 系统处于正常状态时,服务器主机开机(或重新启动)后,能够由系统引导器程序自动引导 ...
随机推荐
- 列出bug的几种状态
1.New:(新的) 当某个“bug”被发现的时候(第一次),测试人员需要与项目负责人沟通以确认发现的的确是一个bug,如果被确认是一个bug,就将其记录下来,并将bug的状态设为New. 2.Ass ...
- 基于MatConvNet的CNN图像搜索引擎PicSearch
简介 Picsearch是一种基于卷积神经网络特征的图像搜索引擎. Github:https://github.com/willard-yuan/CNN-for-Image-Retrieval Web ...
- tensorflow 使用tfrecords创建自己数据集
直接采用矩阵方式建立数据集见:https://www.cnblogs.com/WSX1994/p/10128338.html 制作自己的数据集(使用tfrecords) 为什么采用这个格式? TFRe ...
- cSpring Boot整合RabbitMQ详细教程
来自:https://blog.csdn.net/qq_38455201/article/details/80308771 十分详细,几张图片不显示,看这个地址 1.首先我们简单了解一下消息中间件的应 ...
- python网络爬虫(8)多媒体文件抽取
目的 批量下载网页图片 导入库 urllib中的request中的urlretrieve方法,可以下载图片 lxml用于解析网页 requests用于获取网站信息 import urllib from ...
- VMware中centos7访问外网配置
1.配置虚拟机网络适配器,选择NAT模式 2.在编辑->虚拟机网络编辑器->更改设置 选择目前使用的网卡 3.通过ifconfig查看网卡配置 4.编辑网络配置对应上面网卡名称ens33 ...
- [Next] 三.next自定义服务器和路由
next 服务端渲染 实际上,next 一直都是执行的服务端渲染.npm start执行的是 next 自带的服务器来运行你的应用.next 是支持自定义服务器的,同时能够支持现有的路由和模式,你可以 ...
- 构造器(Constructor)--构造函数
构造器是类型的成员之一,其他成员比如,成员字段,成员函数.狭义上,构造器指的是实例构造器(instance constructor) class Student { public int ID; pu ...
- wex5 baasData规则和绑定 学习
1 在baasData新建一个计算列 2 点击编辑规则,左边选择该计算列, 右边点击计算后面的设置 3 写规则的逻辑 好像不能用if 只能用三目运算符 4 绑定样式和文本的时候 这么用:
- 21 Python之反射
1.反射 主要是用到了4个函数( 用的最多的就是getattr()和 hasattr() ): getattr() 从xxx对象中获取到xxx属性值 hasattr() 判断xxx对象中是否 ...