Search API Solr Configured, Content Indexed, No Search Results

I’m running a Drupal 8.6.13 site with Search API 8.x-1.12 and Search API Solr Search 8.x-2.7. Everything seems to be properly installed and configured – my Solr admin panel shows a configured core and everything looks fine on my Drupal admin interface. I have the index set to process the body fields of my content and custom blocks using the fulltext type; I have 198 items indexed:

{ “response”:{“numFound”:198,”start”:0,”maxScore”:1.0,”docs”:[] }}

The problem is that a search for a word that definitely appears in my content isn’t producing any results. I’m using the config files from the Search API Solr Search module.

Solr Search Devel shows the request being sent to the server and an HTTP “200 OK” response being received. The logged response was:

{ “response”:{“numFound”:0,”start”:0,”maxScore”:0.0,”docs”:[] }}

What else could I be missing?

Some more detail:

I can retrieve documents from the index using a command line query, like this:

$ curl “http://localhost:8983/solr/mycore/select?indent=on&q=:

Here’s an example of one of the returned documents:

  {      "id":"6a1a2p-content-entity:node/100:und",     "sm_context_tags":["search_api_X2f_index_X3a_content",       "search_api_solr_X2f_site_hash_X3a_6a1a2p",       "drupal_X2f_langcode_X3a_und"],     "tm_body_1":["Ignition Timing (Vacuum advance disconnected, lines plugged) 6° BTDC Dwell Angle 30-33° Point Gap .020" Spark Plug Gap .035" Idle RPM * (Manual Transmission, no A/C) 725 Idle RPM * (Manual Transmission, with A/C) 725/500 ** Idle RPM * (Automatic Transmission, no A/C) 675 Idle RPM * (Automatic Transmission, with A/C) 675/500 ** Firing Order 1-5-4-2-6-3-7-8 * Set idle speed with headlights on high beam, air conditioning off. ** Higher RPM, solenoid energized. Lower RPM, solenoid de-energized.  "],     "spell":["Ignition Timing (Vacuum advance disconnected, lines plugged) 6° BTDC Dwell Angle 30-33° Point Gap .020" Spark Plug Gap .035" Idle RPM * (Manual Transmission, no A/C) 725 Idle RPM * (Manual Transmission, with A/C) 725/500 ** Idle RPM * (Automatic Transmission, no A/C) 675 Idle RPM * (Automatic Transmission, with A/C) 675/500 ** Firing Order 1-5-4-2-6-3-7-8 * Set idle speed with headlights on high beam, air conditioning off. ** Higher RPM, solenoid energized. Lower RPM, solenoid de-energized.  "],     "site":"http://example.com/",     "sort_title":"PRD2u0005u000eRHu0004NH2.:4:.*P:FDNu0000",     "_version_":1630197909793275904,     "ss_search_api_datasource":"entity:node",     "sort_body_1":":6D:P:FDu0004P:B:D6u0004t<8e>T*.RRBu0004*0T*D.2u00040:N.FDD2.P20u0006u0004@:D2Nu0004H@R6620t<90>u0004u001ffSu0004,P0.u00040V2@@u0004*D6@2u0004u0019u0013u0005u000eu0019u0019fSu0004HF:DPu00046*Hu0004bu0013u0017u0013txu0004NH*L>u0004H@R6u00046*Hu0004bu0013u0019u001dtxu0004:0@u0000",     "index_id":"content",     "ss_title":"Tune-Up Specifications",     "hash":"6a1a2p",     "ss_search_api_id":"entity:node/100:und",     "timestamp":"2019-04-07T22:57:56Z",     "ss_search_api_language":"und"} 

So then I tried a query using a term found in the content above:

$ curl “http://localhost:8983/solr/mycore/select?q=solenoid” { “response”:{“numFound”:0,”start”:0,”docs”:[] }} $

Why might the second query fail to produce results if the search term is included in the document as shown in the full list of results?

This article was republished from its original source.
Call Us: 1(800)730-2416

Pixeldust is a 20-year-old web development agency specializing in Drupal and WordPress and working with clients all over the country. With our best in class capabilities, we work with small businesses and fortune 500 companies alike. Give us a call at 1(800)730-2416 and let’s talk about your project.

FREE Drupal SEO Audit

Test your site below to see which issues need to be fixed. We will fix them and optimize your Drupal site 100% for Google and Bing. (Allow 30-60 seconds to gather data.)

Powered by

Search API Solr Configured, Content Indexed, No Search Results

On-Site Drupal SEO Master Setup

We make sure your site is 100% optimized (and stays that way) for the best SEO results.

With Pixeldust On-site (or On-page) SEO we make changes to your site’s structure and performance to make it easier for search engines to see and understand your site’s content. Search engines use algorithms to rank sites by degrees of relevance. Our on-site optimization ensures your site is configured to provide information in a way that meets Google and Bing standards for optimal indexing.

This service includes:

  • Pathauto install and configuration for SEO-friendly URLs.
  • Meta Tags install and configuration with dynamic tokens for meta titles and descriptions for all content types.
  • Install and fix all issues on the SEO checklist module.
  • Install and configure XML sitemap module and submit sitemaps.
  • Install and configure Google Analytics Module.
  • Install and configure Yoast.
  • Install and configure the Advanced Aggregation module to improve performance by minifying and merging CSS and JS.
  • Install and configure Schema.org Metatag.
  • Configure robots.txt.
  • Google Search Console setup snd configuration.
  • Find & Fix H1 tags.
  • Find and fix duplicate/missing meta descriptions.
  • Find and fix duplicate title tags.
  • Improve title, meta tags, and site descriptions.
  • Optimize images for better search engine optimization. Automate where possible.
  • Find and fix the missing alt and title tag for all images. Automate where possible.
  • The project takes 1 week to complete.