0

我似乎无法在互联网上的任何地方找到此信息。所以也许有人可以帮忙。

这是我的配置:

<solr persistent="false">

  <!--
  adminPath: RequestHandler path to manage cores.  
    If 'null' (or absent), cores will not be manageable via request handler
  -->
  <cores adminPath="/admin/cores" defaultCoreName="collection1">
     <core name="collection1" instanceDir="." />
  </cores>

solr 安装到 /opt/solr/ 也是 solr.xml 文件所在的位置。它部署在 tomcat7 上,我可以直接在 localhost:8080/solr 访问主页,但是,我看不到如何添加核心,当我浏览到 localhost:8080/solr/admin 时,它显示以下错误,即一个我真的无法超越:

HTTP Status 404 - missing core name in path
type Status report
message missing core name in path
description The requested resource is not available.
Apache Tomcat/7.0.42

它不够冗长,我无法真正知道到底出了什么问题,作为第一次使用的用户,这很令人困惑。想法?

4

1 回答 1

0

这是我沙箱中的 solr.xml 示例。希望有帮助:

<?xml version="1.0" encoding="UTF-8" ?>
<solr persistent="true" sharedLib="lib">
  <cores hostPort="8080"
         hostContext="solr"
         adminPath="/admin/cores">
    <core name="yourcorenamehere"
          instanceDir="coredirectoryhere"
          dataDir="data"
          schema="schema.xml"
          config="solrconfig.xml"
          loadOnStartup="true"
          transient="false" />
  </cores>
</solr>
于 2013-10-24T23:14:45.623 回答