Information for: DEVELOPERS   PARTNERS

Installing Acquia Search with Solr 7 for Drupal 8 and 9

Use the following requirements and instructions to install Acquia Search with Solr 7 for Drupal 8 and 9.

Requirements

To use Acquia Search with Solr 7 on your website, you must meet the following requirements:

  • Prepare a local, virtual development environment for the project.
  • Install the following applications for use with your development environments:
  • Create an SSH key for your user, and provide access to that key to your Cloud Platform environment.
  • Create an index for your website.

Acquia Search Solr installation

Step 1: Install the new Acquia Search Drupal modules

Use the following procedure to install the Drupal modules to enable the use of Acquia Search with Solr 7:

Note

Acquia recommends using the Acquia Connector module with Acquia Search. Use of Acquia Connector gives users access to Acquia Insight, uptime monitoring, and simplified, automatic configuration of Search. If you don’t require Acquia Insight or uptime monitoring, or want to manually configure Acquia Search, you can continue to use the Acquia Search module without Acquia Connector.

  1. If you’re using the Acquia Connector module, run the following command:

    composer require "drupal/acquia_connector:^3.0"
    

    Enable the Acquia Connector module:

    drush en acquia_connector
    
  2. Install the Acquia Search module:

    composer require "drupal/acquia_search:^3.0.0"
    

    Enable the Acquia Search module:

    drush en acquia_search
    

Step 4: Configure the index

After connecting to the search index, you can configure the index by completing the following steps:

  1. In the Operations menu, click Edit, and then select the Acquia Search API Solr server as the Server for the index.

    Note

    From Index Options, be sure that Read only for the Acquia Search Search API Solr index is disabled, or else indexing won’t work.

  2. Click Save configuration to save the index. The website redirects you to the Search API page.

  3. From the Operations menu, click Enable to enable the index.

Step 5: Index site content

To index your site content, complete the following steps:

  1. On your website, from the Search API page, click the index name to open the index detail page.
  2. Click Queue all items for reindexing. Acquia Search will display a confirmation page that prompts you to confirm the reindexing attempt. Click Confirm and you’d be redirected to the index details page.
  3. Scroll to the end of the page, and then click Index now. The Index status displays the number of items indexed out of the total number of items in the index. When reindexing is complete, Acquia Search displays a banner message that indicates the reindexing completed as expected.

You’ve now completed the installation of Acquia Search with Solr 7 for your Drupal website.

Drush commands

Acquia Search Solr includes several Drush commands to manage search from the command line.

Note

For more information about Drush, see the Introduction to Drush.

Command Description
acquia:search-solr:cores Lists all available search indexes. Supports --format=value option. Valid options: json, var_dump or var_export, print_r. Defaults to print_r.
acquia:search-solr:cores:cache-reset Clears the Acquia Search index cache for the default Acquia subscription identifier provided by the module configuration or via --id=CORE-ID option.
acquia:search-solr:cores:possible Lists all possible Acquia Search indexes. Supports --format=value option. Valid options: json, var_dump or var_export, print_r. Defaults to print_r.

For more details, see Drupal-acquia_search_solr-Commands-AcquiaSearchSolrCommands.