4

I'm trying to learn Solr and i'have downloaded the official documentation.

First of all, i've generated a new core with the command:

solr create -c mycore

This command have created mycore under solr/server/solr

While continue reading i would like to experiment the field configuration (schema.xml) but under solr/server/solr/mycore/conf i havent that file.

I have many files such as: solrconfig.xml, stopwords.txt and so on.

So what i have do to generate schema.xml or (if i have to create it manually), how i can tell "Solr, update documents and use the new schema.xml"

Thanks

Mistre83
  • 2,677
  • 6
  • 40
  • 77

2 Answers2

0
I have tried creating a core using "Solr Admin" on solr-5.0.0. It creates the core but does not add any other .xml files. It add everything in core.properties file which refers to default files.
And while creating solr core it does not create the schema.xml.
It refers to the default one.
If you want the new schema.xml to be refered you have to mention the path in core.properties 

The core.properties file contains :

name=new_core
config=solrconfig.xml
schema=schema.xml
dataDir=data
coreNodeName=core_node1

For more info on core refer the below link
https://wiki.apache.org/solr/CoreAdmin
Abhijit Bashetti
  • 8,518
  • 7
  • 35
  • 47
0

Here is how made it work:

Copy schema.xml from $NUTCH/conf directory to the following directory solr-5.5.3/server/solr/mycore/conf

Use the following command to submit:

bin/nutch solrindex http://127.0.0.1:8983/solr/mycore crawl/crawldb -linkdb crawl/linkdb crawl/segments/20160913225018

This worked for me.

I am using Solr 5.5.3 and Apache Nutch 1.12

slfan
  • 8,950
  • 115
  • 65
  • 78