Kerberos开启后TDH远程连接hive数据库

一、TDH开启kerberos后登陆hive方式

  TDH的hive是继承到平台中的,需要使用远程的方式连接hive数据库,当kerberos开启后,需要添加kerberos协议规则;使用方式如下

  beeline -u 'jdbc:hive2://localhost:10000/demo;principal=hive/tdh-1@TDH;authentication=kerberos' -n hive -p 123456

 如果不加principal=hive/tdh-1@TDH;authentication=kerberos则使用的是LDAP方式,使用用户名和密码登陆的元数据库mysql;则会报错

posted @ 2020-07-10 10:40  虎啸千峰  阅读(1091)  评论(0编辑  收藏  举报