Archive for the ‘Windows SharePoint Services 3.0’ Category

Windows SharePoint Services Search Won’t Start (Stuck in ‘Starting’)

September 11, 2009

I recently added a new Search server to my single-server SharePoint farm and wanted to move the search load off my Web Front-End (WFE) server to the new Index server. I set up the new Index server with MOSS SP2 and added my new server to the farm. I then realised that I didn’t have MOSS SP2 on my WFE, so I duly installed that as well. However when running the SharePoint Products and Technologies Configuration Wizard, when it tried to start the Windows SharePoint Services Search service I got the following error in my log files:

The call to SPSearchServiceInstance.Provision (server ‘MOSS’) failed. Setting back to previous status ‘Disabled’. System.IO.FileNotFoundException: The system cannot find the file specified.       at Microsoft.SharePoint.Search.Administration.MSSITLB.IGatherManagerAdmin3.SetDefaultAccount(String bstrAccount, String bstrPassword)     at Microsoft.SharePoint.Search.Administration.Gatherer.ProvisionGlobalProperties()     at Microsoft.SharePoint.Search.Administration.Gatherer.Provision()     at Microsoft.SharePoint.Search.Administration.SPSearchServiceInstance.Synchronize(Boolean installGathererApplication)     at Microsoft.SharePoint.Search.Administration.SPSearchServiceInstance.Provision()     at Microsoft.SharePoint.Search.Internal.UI.SPSearchServiceInstanceSettings.BtnSubmit_Click(Object se… 

After a lot of web trawling for a solution (most of which say “database corrupt reinstall” or “just reinstall that will fix it” and various other related solutions) I checked my server databases. Everything was hosted on my single server at that time and it was also the database server for the system. The existing search server database was over 3Gb but with 2.0Gb free I wondered if disk space could be the problem? So I deleted about 2Gb of old database backups and tried again. All worked wonderfully! My disk space went from 4.5Gb free to 2.0Gb free so it wanted 2.5Gb space and I must have been just under what it required.

I couldn’t see where the additional data was being put – I am assuming at this stage it was copying/moving/creating a database file and just didn’t have enough space on disk to perform the operation, but rather than a “disk full” it just gives you “FileNotFoundException”.

Advertisements

WCF Talking to SharePoint Web Services

November 12, 2008

This had nailed me for about 3 days – how to get a Windows Communication Foundation-based call to a SharePoint 2007 Web Service.  Thankfully, there is a solution:

http://blah.winsmarts.com/2008-7-Using_a_WCF_Client_to_talk_to_SharePoint_OOTB_Web_Services.aspx

In particular, I was using:

<security mode=TransportCredentialOnly>
<transport clientCredentialType=Ntlm/>
</security>

in my app.config, which I think was the issue.  Replacing that with:

<security mode=TransportCredentialOnly>
<transport clientCredentialType=Ntlm proxyCredentialType=Ntlm realm=“”/>
<message clientCredentialType=UserName algorithmSuite=Default/>
</security>

and the code change as specified in the blog post fixed everything!  Once again, I am a victim of not knowing enough about WCF security configuration *sigh*  Annoyingly, some web service calls worked, and some didn’t, which made it more difficult to spot the issue.  These worked:

  • SiteData (GetSiteAndWeb)
  • Lists (GetList)

but this one (my important one!) didn’t:

  • Lists (GetListItems)

After I made the config change, all worked perfectly.

 

UPDATE: Two more items to add to this post, the first in particular because I kept on getting exceptions all wrapped up in a FaultException:

“Exception of type ‘Microsoft.SharePoint.SoapServer.SoapServerException’ was thrown.” 

This was particularly annoying because I couldn’t work out any way to get the underlying exception information.

  1. Adding this line fixed my FaultException problem :
    sharepointServiceClient.ClientCredentials.Windows.AllowedImpersonationLevel = System.Security.Principal.TokenImpersonationLevel.Impersonation;
  2. Make sure you set the Endpoint address to the site you want to interrogate.  Usually this means adding a line similar to:
    listsClient.Endpoint.Address = new EndpointAddress(webInfo.SiteUrl + “/_vti_bin/lists.asmx”);
    otherwise you will probably just get FaultExceptions / SoapServerExceptions and not be able to work out why!