Python 无法在windows中使用solr、haystack和django创建索引文件

Python 无法在windows中使用solr、haystack和django创建索引文件,python,xml,django,windows,solr,Python,Xml,Django,Windows,Solr,我已经尝试了相当长的一段时间,在我的Django网站上使用haystack和solr作为后端引擎进行搜索。我已经生成了schema.xml文件,但是我不确定该放在哪里。我在窗户上。我在谷歌和stackoverflow上搜索,尝试了很多选择,但都无济于事。我还研究了其他问题,例如: 我还发现了许多其他问题,但这里没有列出。我跟着他们做了所有的事,试了试,但没有成功。我总是得到相同的以下错误: Failed to clear Solr index: [Reason: Error 404 Not Fo

我已经尝试了相当长的一段时间,在我的Django网站上使用haystack和solr作为后端引擎进行搜索。我已经生成了schema.xml文件,但是我不确定该放在哪里。我在窗户上。我在谷歌和stackoverflow上搜索,尝试了很多选择,但都无济于事。我还研究了其他问题,例如: 我还发现了许多其他问题,但这里没有列出。我跟着他们做了所有的事,试了试,但没有成功。我总是得到相同的以下错误:

Failed to clear Solr index: [Reason: Error 404 Not Found]
Indexing 24 my_models
Failed to add documents to Solr: [Reason: Error 404 Not Found]
以下是my settings.py供您参考:

HAYSTACK_CONNECTIONS = {
    'default': {
        'ENGINE': 'haystack.backends.solr_backend.SolrEngine',
        'URL': 'http://127.0.0.1:8983/solr'
        # ...or for multicore...
        # 'URL': 'http://127.0.0.1:8983/solr/mysite',
    },
}
你能帮我弄明白该怎么办吗?我已经生成了schema.xml,但它在windows中的具体位置是什么?这个错误又是什么呢?如果我问得不清楚,请告诉我,我会尽量说得更准确、更清楚。谢谢你的帮助

Edit1:示例文件夹的目录结构:

  +---example-DIH
    |   +---hsqldb
    |   \---solr
    |       +---db
    |       |   +---conf
    |       |   |   +---clustering
    |       |   |   |   \---carrot2
    |       |   |   +---lang
    |       |   |   \---xslt
    |       |   \---lib
    |       +---mail
    |       |   +---conf
    |       |   |   +---clustering
    |       |   |   |   \---carrot2
    |       |   |   +---lang
    |       |   |   \---xslt
    |       |   \---lib
    |       +---rss
    |       |   \---conf
    |       |       +---clustering
    |       |       |   \---carrot2
    |       |       +---lang
    |       |       \---xslt
    |       +---solr
    |       |   \---conf
    |       |       +---clustering
    |       |       |   \---carrot2
    |       |       +---lang
    |       |       \---xslt
    |       \---tika
    |           \---conf
    +---exampledocs
    +---films
    \---resources

感谢您的帮助。我已经坚持了一天了

我从来没有在Windows上使用过它,但我想schema.xml的路径在Windows和Linux上应该是相同的。您需要构建schema,复制生成的内容并将其粘贴到schema.xml中,可在以下位置找到:

<path-to-extracted-solr>/example/solr/collection1/conf

start.jar
可以在
/example/

找到,没有这样的文件夹。我曾尝试将schema.xml放在不同的位置,例如在示例内部、服务器内部的conf内部等等,但都没有用。。。我已编辑我的问题以显示我下载的solr 5.1.0目录结构。schema.xml可以在这里找到:
/server/solr/configsets/basic\u configs/conf/
和start.jar可以在这里找到:
/server/
可以通过浏览器访问solr吗?如果是,请选择一个核心并单击文件。检查schema.xml是否与插入的schema.xml相同。它是可访问的…solr版本5+存在一些问题。我试过4.10,一切正常
java -jar start.jar