微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

如何禁用 shardsWhitelist,我收到以下错误

如何解决如何禁用 shardsWhitelist,我收到以下错误

因此,当我在 Solr Admin 的 RawQueryParameter 中添加分片时,出现以下错误

**error":{
    "Metadata":[
      "error-class","org.apache.solr.common.solrException","root-error-class","org.apache.solr.common.solrException"],"msg":"HttpShardHandlerFactory shardsWhitelist not configured but required (in lieu of ZkController 
       and ClusterState) when using the 'shards' parameter. set -Dsolr.disable.shardsWhitelist=true to 
       disable shards whitelist checks","code":403}}**

我想禁用它但没有发现任何有用的东西 请告诉我如何禁用它

我不想指定像

这样的分片
<str name="shardsWhitelist">${solr.shardsWhitelist:localhost:8080/solr/test,localhost:8080/solr/test2}</str>

只想禁用它

解决方法

您可以在启动 solr 时将其添加为参数,如下所示。

-Dsolr.disable.shardsWhitelist=true

另一种选择是您可以添加为 solr.disable.shardsWhitelist=truesolr.in.sh 文件,

在路径 "...\solr-VERSION\bin"

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。