Search Broken

This is an open forum for any mojoPortal topics that don't fall into the other categories.

This thread is closed to new posts. You must sign in to post in the forums.
5/14/2010 9:20:31 AM
Gravatar
Total Posts 154

Search Broken

I don't know what happened but when I search I get this response. 

Sorry, your search query is not formed correctly, we were unable to complete your search.

Any ideas?

5/14/2010 9:46:32 AM
Gravatar
Total Posts 18439

Re: Search Broken

What are you entering in the search box?

5/14/2010 9:50:10 AM
Gravatar
Total Posts 154

Re: Search Broken

Pretty much anything.  I've tried chicken, fish, meat.  No clue why it just stopped working.  I'll reboot the server real quick.

5/14/2010 9:57:48 AM
Gravatar
Total Posts 18439

Re: Search Broken

There should be something in the log about the error.

5/14/2010 10:19:35 AM
Gravatar
Total Posts 154

Re: Search Broken

2010-05-14 11:18:56,911 ERROR mojoPortal.Business.WebHelpers.IndexHelper - handled error for search terms fish
Lucene.Net.Search.BooleanQuery+TooManyClauses: maxClauseCount is set to 1024
at Lucene.Net.Search.BooleanQuery.Add(BooleanClause clause)
at Lucene.Net.Search.BooleanQuery.Add(Query query, Occur occur)
at Lucene.Net.Search.RangeQuery.Rewrite(IndexReader reader)
at Lucene.Net.Search.BooleanQuery.Rewrite(IndexReader reader)
at Lucene.Net.Search.IndexSearcher.Rewrite(Query original)
at Lucene.Net.Search.Query.Weight(Searcher searcher)
at Lucene.Net.Search.Hits..ctor(Searcher s, Query q, Filter f)
at Lucene.Net.Search.Searcher.Search(Query query, Filter filter)
at Lucene.Net.Search.Searcher.Search(Query query)
at mojoPortal.Business.WebHelpers.IndexHelper.Search(Int32 siteId, Boolean isAdmin, List`1 userRoles, Guid featureGuid, String queryText, Boolean highlightResults, Int32 highlightedFragmentSize, Int32 pageNumber, Int32 pageSize, Int32& totalHits, Boolean& invalidQuery

5/14/2010 10:43:21 AM
Gravatar
Total Posts 18439

Re: Search Broken

I would try rebuilding the search index.

Hope it helps,

Joe

5/14/2010 12:10:16 PM
Gravatar
Total Posts 154

Re: Search Broken

I deleted the index and it recreated.  Same results. 

 

2010-05-14 13:09:04,103 ERROR mojoPortal.Business.WebHelpers.IndexHelper - handled error for search terms fish
Lucene.Net.Search.BooleanQuery+TooManyClauses: maxClauseCount is set to 1024
at Lucene.Net.Search.BooleanQuery.Add(BooleanClause clause)
at Lucene.Net.Search.BooleanQuery.Add(Query query, Occur occur)
at Lucene.Net.Search.RangeQuery.Rewrite(IndexReader reader)
at Lucene.Net.Search.BooleanQuery.Rewrite(IndexReader reader)
at Lucene.Net.Search.IndexSearcher.Rewrite(Query original)
at Lucene.Net.Search.Query.Weight(Searcher searcher)
at Lucene.Net.Search.Hits..ctor(Searcher s, Query q, Filter f)
at Lucene.Net.Search.Searcher.Search(Query query, Filter filter)
at Lucene.Net.Search.Searcher.Search(Query query)
at mojoPortal.Business.WebHelpers.IndexHelper.Search(Int32 siteId, Boolean isAdmin, List`1 userRoles, Guid featureGuid, String queryText, Boolean highlightResults, Int32 highlightedFragmentSize, Int32 pageNumber, Int32 pageSize, Int32& totalHits, Boolean& invalidQuery)

5/14/2010 12:39:32 PM
Gravatar
Total Posts 154

Re: Search Broken

I tried using a default skin and it didn't seem to help.  Not quite sure what to do at this point. :(

5/14/2010 1:13:29 PM
Gravatar
Total Posts 18439

Re: Search Broken

Hi Dave,

Do you have settings like this in user.config?

<add key="DisableSearchFeatureFilters" value="false" />
<add key="SearchUseBackwardCompatibilityMode" value="false" />
<add key="EnableSearchResultsHighlighting" value="true" />
<add key="SearchIncludeModuleRoleFilters" value="true" />

What version of mojoPortal? You can check at Administration > System Info

Do you have a lot of roles in your site?

Do you get the same results when you are signed out of the site as when signed in?

Best,

Joe

5/14/2010 1:38:41 PM
Gravatar
Total Posts 154

Re: Search Broken

Settings are exact in user.config.  Same result signed out.  I don't think I added any roles.

System Information
mojoPortal Version 2.3.4.3 MSSQL
Server Time Zone Eastern Daylight Time
Server Local Time (GMT -4) 5/14/2010 2:37:38 PM
Greenwich Mean Time (GMT/UTC) 5/14/2010 6:37:38 PM
Feature Versions
Feature Schema Version
blog 0.0.1.6
contactform 0.0.0.3
eventcalendar 0.0.0.3
feed-manager 0.0.0.7
forums 0.0.1.4
imagegallery 0.0.0.5
linksmodule 0.0.0.5
pollfeature-byChristianFredh 0.0.0.4
sharedfiles 0.0.0.7
surveyfeature 0.0.1.5
webstore 0.0.6.6
 

5/14/2010 1:42:58 PM
Gravatar
Total Posts 18439

Re: Search Broken

That is really strange, at the moment I'm baffled and not able to reproduce the issue. I'll keep investigating on my end to see if I can think of how it could possibly happen but I'm going to be at a code camp all day tomorrow and at a family event most of the day Sunday.

Best,

Joe

5/14/2010 1:46:39 PM
Gravatar
Total Posts 154

Re: Search Broken

Ok no problem Joe.  Thanks for the help.  You can E-Mail me through the site or facebook if you want me to set up an FTP or site login for you.

5/14/2010 1:50:31 PM
Gravatar
Total Posts 154

Re: Search Broken

The search function does seem to be working on my 2nd site.  Looks like it is just related to my primary site for some reason.  I hope its not a database issue.

5/14/2010 2:02:04 PM
Gravatar
Total Posts 18439

Re: Search Broken

I'm certain that it is not a database issue, though it could be some specific factors about the content of the site trigger this somehow, but one should not have to change the content to fix a search error, I'm sure it can be solved in code once the issue that causes it is understood. Googling for the error I see a number of threads that may help figure out how it happens, but will probably be Monday before I can research it fully.

Best,

Joe

5/14/2010 2:05:53 PM
Gravatar
Total Posts 154

Re: Search Broken

In the mean time I'm going to try putting the site as back to default as possible, see if that fixes it, and then slowly migrating it back to what it is now and see if it breaks again.

5/14/2010 2:11:20 PM
Gravatar
Total Posts 18439

Re: Search Broken

Do you have a lot of keywords in your meta settings for each page?

We may need to add a config option to not index those into the site search, it could possibly be causing this.

I don't think you should try to solve it, it has to be a code issue and something about your particular content I think.

For now maybe remove the SeachInput control from your layout.master if you want to hide the search temporarily until this is resolved.

Best,

Joe

5/14/2010 2:18:32 PM
Gravatar
Total Posts 154

Re: Search Broken

Ok Joe.  Will do.

5/14/2010 2:51:02 PM
Gravatar
Total Posts 154

Re: Search Broken

No page keywords.  Just Mealsnmore.com Onion Blossom Recipe in page description.

5/14/2010 10:12:57 PM
Gravatar
Total Posts 154

Re: Search Broken

It's because we added all the fish recipes. They aren't sitting well in the database.  lol

5/17/2010 4:57:39 AM
Gravatar
Total Posts 18439

Re: Search Broken

Hi Dave,

I've been chewing on this problem over the weekend and got the idea that if you could zip up your index folder and send it to me, I can put your index files into my local development copy of mojoPortal and step through the code doing a search to find out exactly what is going on.

Could you send it to me at joe dot audette at gmail dotcom?

Thanks,

Joe

5/17/2010 7:56:08 AM
Gravatar
Total Posts 154

Re: Search Broken

Ok sent. 

5/20/2010 1:59:53 PM
Gravatar
Total Posts 154

Re: Search Broken

Thanks for all the help Joe!!!!

Something must have went wrong during an upgrade.  I reverted back to an old version, reapplied the upgrade and everything is working now. 

11/26/2011 12:25:47 AM
Gravatar
Total Posts 192

Re: Search Broken

hi. i'm having the same problem of "maxClauseCount is set to 1024".

by rebuilding the index, it will be ok, but again fails.

this is true for the site:

      "Do you have a lot of keywords in your meta settings for each page?

We may need to add a config option to not index those into the site search, it could possibly be causing this."

nearly every page has a different meta description.

what can I do?

(if you want to change code, could you post the files that have changed here too? or the code itself if it's not much.)

 

11/26/2011 6:56:32 AM
Gravatar
Total Posts 18439

Re: Search Broken

Hi,

You can try increasing the maxClauseCount by adding this to your user.config file:

 <add key="SearchMaxClauseCount" value="1024"/>

and increase the value until the error goes away.

Hope that helps,

Joe

You must sign in to post in the forums. This thread is closed to new posts.