XF 1.2 Very slow search index rebuild

Nnirvi

Member
Hi!

After a successful import, I've tried to rebuild the search index. Yesterday I started it pretty late and forum had around 60 active users at that moment. It started nicely but came to a crawl couple of hours later after indexing 1,5M messages.

This morning I cancelled it (it had made no significant improvement from 1,5M overnight) and started again, this time with a delay of 1 second. Again, it started nicely (this time forum was almost empty) and now it's taking 20 seconds per 500 messages.

Any ideas?
 
Alternatively, if you really do want to continue with MySQL in this case (not really recommended), you will want to run:

ALTER TABLE xf_search_index DISABLE KEYS;

Rebuild the index and when it's complete run:

ALTER TABLE xf_search_index ENABLE KEYS;

This will cause MySQL to build the full text index in bulk so the insert will be much faster, though note that it could take some time to enable keys there.
 
Top Bottom