Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

Search in SharePoint throws an error, NullReferenceException, whether using the Search box on a normal page or even just loading the Advanced Search page.

I was originally getting System.ServiceModel.ServerTooBusyException and Round Robin Service Load Balancer EndpointFailure errors in the SharePoint ULS logs whenever I tried to search. I examined IIS and determined that the Web Apps existed. I stopped and started the Search Query and Site Settings Serviec on the server. That was the last I saw of the EndpointFailure and ServerTooBusyException errors.

However, a new error showed up. This time is was a System.NullReferenceException from SetPropertiesOnQueryReader() at CoreResultsWebPart.OnInit(). KB Article 976462 looked promising, until further research showed that it adds the AllowInsecureTransport property in the SecurityBindingElement class, and changes the value from its default of False to True. However, this property exists and is already set to True in my environment.

I found this same problem, however deleting the Search Service Apps and Proxies, recreating them and performing an IISRESET did not fix my problem.

When the Advanced Enterprise Search page is brought up, an error is returned to the screen: Object reference not set to an instance of an object.

This is the log entry out of the ULS:

CoreResultsWebPart::OnInit: Exception initializing: System.NullReferenceException: Object reference not set to an instance of an object. at Microsoft.Office.Server.Search.WebControls.CoreResultsWebPart.SetPropertiesOnQueryReader() at Microsoft.Office.Server.Search.WebControls.CoreResultsWebPart.OnInit(EventArgs e)

Internal server error exception: System.NullReferenceException: Object reference not set to an instance of an object. at Microsoft.Office.Server.Search.WebControls.CoreResultsWebPart.SetPropertiesOnQueryReader() at Microsoft.Office.Server.Search.WebControls.CoreResultsWebPart.OnInit(EventArgs e) System.NullReferenceException: Object reference not set to an instance of an object. at Microsoft.Office.Server.Search.WebControls.CoreResultsWebPart.SetPropertiesOnQueryReader() at Microsoft.Office.Server.Search.WebControls.CoreResultsWebPart.OnInit(EventArgs e)

share|improve this question

2 Answers 2

I have had a very similar issue this week and I've just resolved it. The logs looked much the same with null references but the front-end trouble occured as the enterprise search template showing a 'could not connect to search service' issue. The search service was running and previously worked fine...

In any case, I was in a position where I could nuke my search subsite and start again. Which I did but still had the same issue. Tried recreating the search app but still no-go. So I deleted the search application and created one with a new name, put a new enterprise search site over it and now my problem is solved...

Hope this is relevant/suitable to your requirements and helps you past this b*@%&%d of a problem.

share|improve this answer

Couldnt agree more with @Foocode.

  1. Nuke the site.
  2. Delete the Search Application.
  3. Check the Index drive - this is where u may have some issue - if the old index doesnt remove due to some corruption / damage. You may have to resort to hard removal.
  4. Setup the Search Foundation Search first - if you already havent
  5. Setup Search App
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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