XF 1.5 Search not working, but only on main search


I'm having an issue with search, in that the main search function (i.e. when I click 'Search Forums) isn't working.

I have two XenForo installs, but it only affects one of them. The one that is affected is considerably larger - almost 6 million posts.

Various users have reported the issue, so don't think it's anything relating to a specific user. Searching for posts by someone, or searching for a keyword, produces the same result. Narrowing the search doesn't help. The 'loading icons' appear, then nothing happens.

Looking at the PHP look, it indicates that it's executing too slow. script .../index.php' (request: "POST /index.php") executing too slow (31.529413 sec), logging.

So as you can see, it's going for at least 30 seconds without returning results.

What confuses me is that the search box in the top right does work without incident... so I'm not sure why one would work and one wouldn't. Any thoughts?

Thank you


XenForo moderator
Staff member
With that many posts, MySQL standard search is going to struggle.

The typical cutoff point is around 1 million posts, after which time you would need to consider an alternative option such as the Enhanced Search add-on.
1 million seems very low to me and my other forum of 1.2m is going just fine on XenForo.

I never had any issue at all with that number if posts on vBulletin and that was on 3.6.8, so ancient... and I must admit not keen on spending another $100 on two sites to fix this.

And do you know why one search would work and the other wouldn't?


XenForo moderator
Staff member
The search at the top right is context dependent, so will be running against a limited set of data, whereas the main search is run against the whole index.
And any thoughts on why seven year old software can run a search on 6m posts but not a super-duper XenForo? I don't recall reading any warnings before purchasing that XenForo was designed for sub-1m post forums. No warning on import either that it was a bad idea.

Chris D

XenForo developer
Staff member
I can't comment on the other software, but to be clear, XenForo is not designed only for sub-1m post forums. Some of the largest forums are now running XenForo. XenForo works well on big boards and we wouldn't design it any other way.

The built in search system, however, relies on MySQL full text search which is notoriously poor hence most people prefer to use something more robust which we provide in the form of XenForo Enhanced Search which uses Elastic Search as its back end.

I have a 3 million post forum that doesn't have Enhanced Search and that does something similar. A short term solution is to raise the maximum execution time in PHP, but realistically, you don't want to be having searches running for beyond a few seconds. Forums with Enhanced Search can search millions of posts within a very short amount of time.

It all depends what you search for, too. A common word will take longer to search for than a less common word. You can see that even your smaller forum if you search for a common term such as "miami" it takes considerably longer than something which may appear less often.

You may well get away with it on the smaller forum for another million posts or so, yet, but the larger one will likely instantly benefit from Enhanced Search.
Well if XenForo is saying that beyond 1m posts you need to spend extra money on something, then XenForo has been designed for sub-1m posts. To me that's quite evident.

I don't quite buy it... because if seven year old software from vBulletin can cope with 6m with ease on mySQL, then mySQL is not really to blame. Even if it may not be the best thing in the world.

And everything else in XenForo is so modern and so slick that to me it doesn't really ad up.

Also the search in the top works fine. Case in point, if I search for all posts by me it's instant in the top right. It doesn't work in the main search. There is some oddity between these two mechanisms.

I should probably open a support ticket.