Kerberos驱动整理

  • Last update:August 04, 2022
  • 1. 概述

    Kerberos 认证时,需要将驱动和 URL 按本文进行更改。

    2. 驱动

    数据库驱动
    URL格式驱动下载注意点

    TRANSWARP INCEPTOR(星环)


    jdbc:hive2://ip:port/database;principal=hive/service@REALM;authentication=kerberos;kuser=pricipal;keytab=keytab路径

    星环

    URL 中的 principal:

    • 由三部分组成:xxx/xxx@xxx

    • service 不是 IP 名,而是机器名

    • 该 principal 需满足 hive-site.xml 文件中的规则

    Sparkjdbc:hive2://ip:port/database;principal=hive/service@REALM

    hive通用版本:hive

    hive 2.x版本:hive2.x

    hive 3.x版本:hive3.x


    hive(单节点)jdbc:hive2://ip:port/database;principal=hive/service@REALM

    Apache Impala

    jdbc:impala://ip:port/database;AuthMech=1;KrbHostFQDN=quickstart.cloudera;KrbServiceName=impalaimpala
    保证 KrbHostFQDN、KrbServiceName 两个参数拼接的 principal 能够通过认证
    FusionInsight HDjdbc:hive2://zkhost:port/,zkhost:port,zkhost:port/;serviceDiscoveryMode=zooKeeper;zooKeeperNamespace=hiveserver2;principal=hive/service@REALMzookeeper
    • 确认 zookeeper 需要 Kerberos认证,可以查看主体 jar 包版本

    • 确认使用的是数据库自带的 zookeeper jar包

    • 检查 zookeeper 的相关配置

    hive(zookeeper形式,常用于集群)
    Phoenixjdbc:phoenix:quorum:port/database:pricinpal:keytabPathphoenix
    • url中最好包含principal和keytab

    • 明确 zookeeper 是否需要进行认证,若无需认证则将 zookeeper.sasl.client 系统参数设置为 false,需要 sasl 认证,则需要注意拼接的principal

    • 如果 hbase.zookeeper.quorum参数值是主机名,则需要在 hosts 中配置映射

    HBasejdbc:phoenix:quorum:port/database:pricinpal:keytabPathhbase


    Attachment List


    Theme: 数据准备
    Already the First
    Already the Last
    • Helpful
    • Not helpful
    • Only read

    滑鼠選中內容,快速回饋問題

    滑鼠選中存在疑惑的內容,即可快速回饋問題,我們將會跟進處理。

    不再提示

    10s後關閉

    Get
    Help
    Online Support
    Professional technical support is provided to quickly help you solve problems.
    Online support is available from 9:00-12:00 and 13:30-17:30 on weekdays.
    Page Feedback
    You can provide suggestions and feedback for the current web page.
    Pre-Sales Consultation
    Business Consultation
    Business: international@fanruan.com
    Support: support@fanruan.com
    Page Feedback
    *Problem Type
    Cannot be empty
    Problem Description
    0/1000
    Cannot be empty

    Submitted successfully

    Network busy