2

We use Drupal 6 for http://www.boekwijs.nl. But when you search for something (which hasn't been searched for before, in other words; not in cache) it's very slow. At the moment there are 60.000 nodes with CCK fields and taxonomy terms.

What is the best way to optimize this? Are there any modules available? Do we need to use another search engine (SOLR?) or maybe another database structure?

4
  • Wow, I don't know what's happening but a search for 'bruna' even crashes my browser (Opera 11.51 on Linux). It looks like a client-side problem to me; when visiting the search page using Lynx, it's really fast. The search also works fine in Opera when I disable javascript. Sep 16, 2011 at 8:16
  • I'd suggest fixing whatever crashes browsers (Chrome Stable OSX here) first. I'd start looking at any custom javascript added to the page.
    – digital
    Sep 19, 2011 at 15:59
  • 1
    Doesn't feel slow nor does it crash my browser, so it does look to be a client-side browser-specific issue. Using Chrome "18.0.976.0 (Developer Build 115086 Linux) Built on Ubuntu 11.10, running on Ubuntu 12.04". (Yeah, I like using development versions... ). Edit: Oh wow, didn't notice this was that old, question somehow managed to bubble up to the active questions..
    – Berdir
    Dec 21, 2011 at 20:23
  • @Berdir Edited questions, or questions for which an old answer is edited (as well as questions for which a new answer is added) are bumped to the front page. This is why this question was bumped on the front page. :)
    – apaderno
    Jul 11, 2012 at 12:39

2 Answers 2

2

60,000 nodes in the search index is definitely a lot. Not only is it slow and suboptimal to use Drupal's default search with such a large number of nodes, but it is going to progressively put more pressure on your infrastructure as you continue adding nodes.

The solution would definitely be to offload your search to another tool. Two options:

  1. Solr: 60,000 is child's play for Solr. It could suffice you for a lot more even on a commodity machine.
  2. Elastic search: Another tool built on top of Apache Lucene. This one's newer and does not have as many supporting modules for it as Solr does (for Drupal). But it is faster than Solr and can handle concurrent commits much better.

In both these cases, I'd recommend installing the search tool on another server.

1
  • We ended up using Solr.
    – rroose
    Aug 2, 2012 at 12:12
-1

It is not not required to go for the other module.

I have developed site IDSA, there are 20,000+ nodes and taxonomy terms etc. Using database indexing for particular row will also affect the searching functionality.

Have you customize search module or apply any hook_query_alter ? This will also affect the result.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.