TFS 2010 Beta2: Troubleshooting SharePoint configuration issues (TF249038).

In configuring the integration between Team Foundation Server and SharePoint Products, one of the most common errors we see in Beta 2 is:

TF249038: The following Web service is not available: https://servername/_vti_bin/TeamFoundationIntegrationService.asmx. This Web service is used for the Team Foundation Server Extensions for SharePoint Products. Either the extensions are not installed, or there is a problem with the URL. Verify that the following URL is a valid SharePoint Web application and is available: https://servername. If the URL is correct, verify that it is available and the firewall is not blocking access to it.

Troubleshooting Information

Possible causes

Determining what happened and what to do about it

The call to the web service actually returned HTML instead of some kind of exception.  SharePoint often does this with things like access denied or timeouts.

This is the most common cause of this error.

What happened?

1. The best way to check what happened is to take a look at the SharePoint logs which are normally located at "%ProgramFiles%\Common Files\Microsoft Shared\web server extensions\12\LOGS" on the SharePoint server.

2. If you are creating a new site,

a. Look for an entry that starts with “CreateSite BEGIN” where the arguments listed after that include your new site’s location.

b. Now, look for “ThreadAbortExecption” between the “CreateSite BEGIN” and the “CreateSite END” log messages.  This is the classic indication that the call has timed out.

3. If you aren’t creating a site, then just check for the ThreadAbortExceptions.

How can I fix it?

Timeouts appear to be the most common problem.  If you are seeing timeouts, there are a couple of things you can try:

1. You can try “warming up” SharePoint before you try to create a new project.  You can do this by visiting the site created for the team project collection (e.g.: https://servername/sites/DefaultCollection).

2. If you are running in a VPC/VM environment, try increasing the memory allocated to the VPC/VM.  When its memory constrained, creating a SharePoint site takes much longer than it normally would.

If it does not appear to be a timeout, see if you can determine a cause and solution based on the SharePoint logs. If you cannot, post a question to the Microsoft Visual Studio Team Foundation Server 2010 Beta 2 forum at https://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/threads. Please include detailed information on what you were doing that resulted in the error as well as any log information you were able to find. Please also let us know if this was a one-time failure or if it is reproducible.

The Microsoft.TeamFoundation.SharePoint.wsp did not get deployed to the SharePoint Products server.  This web service is deployed to SharePoint as part of this package.

What happened?

1. Verify that the Extensions for SharePoint were installed on the server. Also, confirm that the configuration wizard was run.

a. Open the Team Foundation Administration Console on the SharePoint Products server.

b. Click on the “Extensions for SharePoint Products” node.

c. If there is a link to configure installed features, then it has not been configured.

2. In the "%AllUsersProfile%\Application Data\Microsoft\Team Foundation\Server Configuration\Logs" folder, find a log file with the string Microsoft.TeamFoundation.SharePoint.wsp in it.  Then take a look at the logging around the STSADM.exe commands to see what if anything failed.

3. Then go to the SharePoint Central Administration site.

4. Click on the Operations tab.

5. Click on Solution Management (under Global Configuration).

6. There should be 3 TFS related WSPs located there.  2 of them should be globally deployed and the third should be deployed to all of the content web applications.

clip_image002[1]

How can I fix it?

1. If these were not deployed, you may be able to correct it by running the Team Foundation Extensions for SharePoint extensions installation and wizard again.

2. You can also deploy these WSPs (solutions) manually if you are a Farm Administrator in SharePoint. This only works if the installation has been done to lay down the assemblies needed.

a. The files are located at “%ProgramFiles%\Microsoft Team Foundation Server 2010\Tools\Templates”.

b. Open a command prompt and change to the “%ProgramFiles%\Common Files\Microsoft Shared\web server extensions\12\BIN” folder.

c. To add the solution to the SharePoint database, run the following command for each of the three WSP files: stsadm.exe -o addsolution -filename wspfile.wsp

d. Now, we’ll deploy each solution using the SharePoint Central Administration site. Open it in a web browser.

e. Click on the Operations tab.

f. Click on Solution Management (under Global Configuration).

g. You should now see the WSPs that were added above.

h. Click on the first one.

i. Click Deploy Solution on the next page.

j. Select to deploy it now and click OK on the next page.

k. Repeat the deploy steps for each of the solutions.

l. Finally, grant Modify permissions for the “WSS_WPG” group to the following folder: %CommonProgramFiles%\Microsoft\Team Foundation\Web Access”.

We get a web exception back.  This might be something like the server is not available.

What happened?

1. The log for the action you’re doing may contain more information. 

2. Project Creation logs are on the client machine and are typically located in %Temp% for the user creating the project.  They are normally named VSTS_TeamProjectCreation_(timestamp).log.

3. TFS Configuration Team Project Collection creation logs can be accessed using the Team Foundation Administration Console.

How can I fix it?

1. Try to correct the problem from the web exception and try again. If needed, search the web and our forums to see if there is a solution to the problem.

2. If you cannot determine the cause of the web exception, post a question to the Microsoft Visual Studio Team Foundation Server 2010 Beta 2 forum at https://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/threads. Please include detailed information on what you were doing that resulted in the error as well as any log information you were able to find. Please also let us know if this was a one-time failure or if it is reproducible.

The SharePoint site cannot actually start up or there is a firewall blocking your access to it.  The startup problems can happen if the credentials for the site are not valid, the sites are running under .NET 4.0 (instead of 2.0), there are errors in the web.config file.

What happened?

The SharePoint sites must work in a browser in order for our integration to work.

1. Check that you can get to SharePoint Central Administration site using a web browser.

2. Check that you can get to the content SharePoint sites using a web browser.

How can I fix it?

1. Try to correct the problem and try again.

2. If you cannot determine the cause of the problem or correct it, post a question to the Microsoft Visual Studio Team Foundation Server 2010 Beta 2 forum at https://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/threads. Please include detailed information on what you were doing that resulted in the error as well as any log information you were able to find. Please also let us know if this was a one-time failure or if it is reproducible.

What are we doing to make this better in RTM?
1. Because timeouts appear to be the most common problem, we are increasing the timeout to 5 minutes (from 90 seconds) in several of our web service methods.

2. During the initial configuration of the SharePoint extensions, we cycle IIS which makes it “cold” before creating a project.  We’re going to try to warm up the SharePoint site after we cycle IIS in the RTM version.

3. Web exception messages will be included in the RTM version of the exception above.

4. When we get HTML or some other response that is not valid, that information will be included in the exception data and in the logs.

Additional Information

To get a better understanding of the integration between Team Foundation Server and SharePoint Products, see https://msdn.microsoft.com/en-us/library/ms253177(VS.100).aspx.

Credits:

Many thanks to Mary Ellen Chaffin, for providing this nice writeup.