The Solr Service

You can install the Solr service through the Cloudera Manager installation wizard, using either parcels or packages. See Installing Search.

You can elect to have the service created and started as part of the first run installation wizard. If you elect not to create the service using the installation wizard, you can use the Add Service wizard to perform the installation. The wizard will automatically configure and start the dependent services and the Solr service. See Adding a Service for instructions.

For further information on the Solr service, see Cloudera Search Guide.

The following sections describe how to configure other CDH components to work with the Solr service.

Configuring the Flume Morphline Solr Sink for Use with the Solr Service

Minimum Required Role: Configurator (also provided by Cluster Administrator, Full Administrator)

To use a Flume Morphline Solr sink, the Flume service must be running on your cluster. See the Flume Near Real-Time Indexing Reference (CDH 5) for information about the Flume Morphline Solr Sink and The Flume Service.

  1. Go to the Flume service.
  2. Click the Configuration tab.
  3. Expand the Agent default role group and click the Flume-NG Solr Sink category.
  4. Edit the following settings, which are templates that you must modify for your deployment:
    • Morphlines File (morphlines.conf) - Configures Morphlines for Flume agents. You must use $ZK_HOST in this field instead of specifying a ZooKeeper quorum. Cloudera Manager automatically replaces the $ZK_HOST variable with the correct value during the Flume configuration deployment.
    • Custom MIME-types File (custom-mimetypes.xml) - Configuration for the detectMimeTypes command. See the Cloudera Morphlines Reference Guide for details on this command.
    • Grok Dictionary File (grok-dictionary.conf) - Configuration for the grok command. See the Cloudera Morphlines Reference Guide for details on this command.

Once configuration is complete, Cloudera Manager automatically deploys the required files to the Flume agent process directory when it starts the Flume agent. Therefore, you can reference the files in the Flume agent configuration using their relative path names. For example, you can use the name morphlines.conf to refer to the location of the Morphlines configuration file.

Deploying Solr with Hue

Minimum Required Role: Configurator (also provided by Cluster Administrator, Full Administrator)

In CDH 4.3 and earlier, in order to use Solr with Hue, you must update the URL for the Solr Server in the Hue Server advanced configuration snippet.
  1. Go to the Hue service.
  2. Click the Configuration tab.
  3. Search for the word "snippet". This will display a set of Hue advanced configuration snippet properties.
  4. Add information about your Solr host to the Hue Server Configuration Advanced Configuration Snippet for hue_safety_valve_server.ini found under the Hue Server Default Group > Advanced category. For example, if your hostname is SOLR_HOST, you might add the following:
    [search]
    ## URL of the Solr Server
    solr_url=http://SOLR_HOST:8983/solr
  5. Click Save Changes to save your advanced configuration snippet changes.
  6. Restart the Hue Service.