Hive Structure
![](https://img.haomeiwen.com/i4133161/ed2510c7a6fb2b62.jpg)
Metastore 服务和存储的方式
1.内嵌模式
![](https://img.haomeiwen.com/i4133161/9b3a05377d9c5820.jpg)
2.本地模式
![](https://img.haomeiwen.com/i4133161/640d335b6ec3ddeb.jpg)
3.远程模式
![](https://img.haomeiwen.com/i4133161/9303858f1aebffb6.jpg)
建议采取远程模式,这样的模式可以将数据库层完全置于防火墙后,客户就不再需要用户名和密码登录数据库,避免了认证信息的泄漏。
配置信息 hive 1.1.0
![](https://img.haomeiwen.com/i4133161/9ef23ba4dee2243f.png)
![](https://img.haomeiwen.com/i4133161/6e9c8d5bf7b2f35d.png)
1.10 测试的过程中发现hive.metastore.local 不设置也没关系, 主要根据uris 来进行判断。
注意:在测试的过程中发现设置uris 的port 为其他值没有效果(hive.metastore.portHive 1.3.0and later 加入)
对于hivemetastore 服务 可以将配置放到hivemetastore-site.xml 中,加载顺序 hive-site.xml --> hive-metastore.xml --> -hiveconf ,后面加载的生效。
参考资料:https://cwiki.apache.org/confluence/display/Hive/AdminManual+MetastoreAdmin
https://cwiki.apache.org/confluence/display/Hive/AdminManual+Configuration
网友评论