Hive从具有各种模式的客户端连接到直线.
1.嵌入式模式:
Server和Client都在同一台机器上运行.无需TCP连接.
If hive.server2.authentication is "NONE" in HIVE_HOME/conf/hive-site.xml then connect beeline with below url
Connection URL:
!connect jdbc:hive2://
2.远程模式:
它支持多个客户端在以下身份验证方案的帮助下执行查询.
认证方案:
i.)SASL Authentication:
If value of "hive.server2.authentication" property in HIVE_HOME/conf/hive-site.xml to be set as "SASL" then connect hive beeline with below url
Beeline URL:
!connect jdbc:hive2://:/
ii.)NOSASL Authentication:
If "hive.server2.authentication" is nosasl then connect the beeline like below.
Beeline URL:
!connect jdbc:hive2://:/;auth=noSasl
希望这对你有所帮助
参考文献: