【问题标题】:Sentry | java.lang.NullPointerException: Config key sentry.service.client.server.rpc-address is required哨兵 | java.lang.NullPointerException:需要配置密钥 sentry.service.client.server.rpc-address
【发布时间】:2017-02-03 14:39:56
【问题描述】:
 solrctl sentry --list-roles

我正在运行上面的命令,但它失败并出现以下错误。 我是新来的哨兵。我在 Solr 配置中仔细检查了 sentry.service.client.server.rpc-address 的值,它具有运行 Sentry 服务的主机名的正确值。这个错误是什么意思?

16/09/26 15:19:42 ERROR tools.SentryShellSolr: Config key sentry.service.client.server.rpc-address is required
java.lang.NullPointerException: Config key sentry.service.client.server.rpc-address is required
    at com.google.common.base.Preconditions.checkNotNull(Preconditions.java:208)
    at org.apache.sentry.provider.db.generic.service.thrift.SentryGenericServiceClientDefaultImpl.<init>(SentryGenericServiceClientDefaultImpl.java:123)
    at org.apache.sentry.provider.db.generic.service.thrift.SentryGenericServiceClientFactory.create(SentryGenericServiceClientFactory.java:31)
    at org.apache.sentry.provider.db.generic.tools.SentryShellSolr.run(SentryShellSolr.java:50)
    at org.apache.sentry.provider.db.tools.SentryShellCommon.executeShell(SentryShellCommon.java:241)
    at org.apache.sentry.provider.db.generic.tools.SentryShellSolr.main(SentryShellSolr.java:95)
The operation failed.  Message: Config key sentry.service.client.server.rpc-address is required

【问题讨论】:

  • 您设法解决了这个问题吗? (我在自动取款机上遇到同样的问题)

标签: sentry apache-sentry


【解决方案1】:

使用 CDH,solrctl sentry 命令在主机上查找哨兵配置文件(etc/sentry/conf.cloudera.sentry/sentry-site.xml 或 /etc/sentry/conf/sentry-site.xml)。此配置文件包含 sentry.service.client.server.rpc-address 以及其他配置选项,并且仅当主机在 Cloudera Manager 中具有角色 Sentry Server 或 Sentry Gateway 时才会自动部署到主机。

在大多数情况下,这意味着您需要将 Sentry Gateway 角色添加到要从中运行 solrctl sentry 命令的主机。

在 Cloudera Manager 中,转到 Sentry -> Instances -> Add Role Instances ->(选择主机)-> Ok。几分钟后,应该会部署配置,您应该可以使用 solrctl sentry。

我使用 CDH 5.11.1 和 kerberized Solr 对此进行了测试。

【讨论】:

    猜你喜欢
    • 2022-01-04
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2023-03-09
    • 2017-05-25
    • 1970-01-01
    • 1970-01-01
    • 2017-02-16
    相关资源
    最近更新 更多