Skip to content

The MetaKarta engine can reuse your existing external SolrCloud. You may follow the instructions below to create and configure a new Solr collection in your SolrCloud, and use it in MetaKarta.

Solr Requirements

The supported versions are both Solr 8.x and Solr 9.x, note that:

  • Solr 8.x requires Java 8 or higher.

  • Solr 9.x requires Java 11 or higher.

The minimum Solr indexing server requirements (based on physical hardware performance, not a virtual environment) are:

  • Processor: 2 GHZ quad core (4 cores)

  • Memory: 24 GB of RAM

  • Storage: 20 GB of disk space

If you are migrating from a Lucene index to SolrCloud, you would need disk space 2 to 3 times the size of the original Lucene index. This is because MM stores much more information in the Solr index to facilitate the searching, sorting and faceting functions. 

Solr Collection Setup

A dedicated Solr collection needs to be created for MetaKarta to store search data. Take the following steps to set up the new collection.

Create a new configset

Configsets are a set of configuration files used in a Solr installation. When you create a collection in SolrCloud, you can specify a named configset. In SolrCloud, configsets are stored in ZooKeeper and not the file system. 

You may copy a predefined configset from the %MM_HOME%\data\solr\mm to $SOLR_HOME\configsets, and then upload the configset to ZooKeeper as a named configset mm using the following command:

bin\solr zk upconfig -n mm -d mm -z localhost:9983

Note: The default zooKeeper port number is 9983.

Create a new collection

You may create a new collection named mm using the Solr Admin UI. Make sure that you select the configset mm as the value of the config set parameter.

Or you may use the Solr Collections API to create a new collection named mm using the following command:

curl -X POST http://localhost:8983/api/collections 

-H "Content-Type: application/json" -d '

{

"create": {

"name": "mm", 

"config": "mm", 

"numShards":1, 

"replicationFactor":1

}

}

Note 1: The default solr port number is 8983.

Note 2: The above command uses the Solr V2 Collections API. The V2 Collections API would work if your Solr server is on Solr 9.x. If your Solr server is on Solr 8.x, you can use the Solr V1 Collections API, such as

http://localhost:8983/solr/admin/collections?action=CREATE&name=mm&collection.configName=mm&numShards=1&replicationFactor=1

MM Application Server Configuration for External Solr Indexing Server

You must first stop the MM Application Server, and then use the following options of the MetaKarta setup utility to configure the Solr server URL and collection name:

$MM_HOME/Setup.sh -?

[{ -iu | --index-url }] Solr: set the url of the solr server

[{ -ic | --index-collection }] Solr: set the name of the collection to use

For example: $MM_HOME/Setup.sh -iu solr.MyCompany.com -ic mm

Then you can restart the MM Application Server.

If you are not starting from scratch on an empty repository, and instead already have existing local index files for Lucene at $MM_HOME/data/Search or from the bundled Solr Server at $MM_HOME/data/solr, then a migration to the external Solr Server will occur as explained in the following sections.