Unable to connect TeamCity to TFS

Like many other posts, I have a giant error message saying that I cannot connect to TFS from TeamCity.  Sadly, I don't see many solutions to such problems.  But, here goes.

------------
Failed for the root 'TruDB-Main' #5: TFS failed. ExitCode: 111, command: C:\TeamCity\webapps\ROOT\WEB-INF\plugins\tfs\bin\tfs-native.exe @@C:\TeamCity\temp\TC-TFS-65-1514_443\command.params, in file: {http://tfs01:8080/tfs, /user:***** /password:***** /hash:S, /noProxy, C:\TeamCity\temp\TC-TFS-65-1514_440.result, GetCurrentVersion}, completed in: 0 second(s)
stdout: TFS Native Verifier v8.0 Copyright (C) 2006-2013 JetBrains s.r.o.
Running under .NET Framework 4.0.30319.18408
INFO -
INFO - Use Team Explorer 2012
INFO -
TFS Native Accessor v8.0 Copyright (C) 2006-2013 JetBrains s.r.o.
INFO - Connecting to server http://tfs01:8080/tfs
INFO - WebProxy is disabled
Get current version:
Server='http://tfs01:8080/tfs'
Username='steve'
ERROR - TF400324: Team Foundation services are not available from server http://tfs01:8080/tfs.
Technical information (for administrator):
Page not found.
System.Exception: TF400324: Team Foundation services are not available from server http://tfs01:8080/tfs.
Technical information (for administrator):
Page not found. ---> Microsoft.TeamFoundation.TeamFoundationServiceUnavailableException: TF400324: Team Foundation services are not available from server http://tfs01:8080/tfs.
Technical information (for administrator):
Page not found. ---> System.Net.WebException: The remote server returned an error: (404) Not Found.
at System.Net.HttpWebRequest.GetResponse()
at Microsoft.TeamFoundation.Client.Channels.TfsHttpWebRequest.SendRequestAndGetResponse(HttpWebRequest webRequest, WebException& webException)
--- End of inner exception stack trace ---
at Microsoft.TeamFoundation.Client.Channels.TfsHttpWebRequest.ReadResponse(HttpWebResponse webResponse, WebException webException)
at Microsoft.TeamFoundation.Client.Channels.TfsHttpWebRequest.IsAuthenticationChallenge(TfsMessage requestMessage, HttpWebResponse webResponse, WebException webException, TfsMessage& responseMessage)
at Microsoft.TeamFoundation.Client.Channels.TfsHttpWebRequest.SendRequest()
at Microsoft.TeamFoundation.Client.Channels.TfsHttpRequestChannel.Request(TfsMessage message, TimeSpan timeout)
at Microsoft.TeamFoundation.Client.Channels.TfsHttpClientBase.Invoke(TfsClientOperation operation, Object[] parameters, TimeSpan timeout, Object[]& outputs)
at Microsoft.TeamFoundation.Framework.Client.Registration.GetRegistrationEntries(String toolId)
at Microsoft.TeamFoundation.Framework.Client.RegistrationProxy.GetRegistrationEntries(String toolId)
at Microsoft.TeamFoundation.Framework.Client.RegistrationService.RefreshMemoryCache()
at Microsoft.TeamFoundation.Framework.Client.RegistrationService.RefreshCachesIfNeeded(Boolean direct)
at Microsoft.TeamFoundation.Framework.Client.RegistrationService.GetRegistrationEntries(String toolId)
at Microsoft.TeamFoundation.Framework.Client.PreFrameworkServerDataProvider.FindServiceLocation(String serviceType, String toolId)
at Microsoft.TeamFoundation.Framework.Client.PreFrameworkServerDataProvider.LocationForCurrentConnection(String serviceType, Guid serviceIdentifier)
at Microsoft.TeamFoundation.Client.TfsConnection.EnsureProviderConnected()
at JetBrains.TeamCity.Tfs.Command.Do() in c:\BuildAgent\work\23f504c63c17dfdf\TfsNativeAccessor\src\Command.cs:line 28
at JetBrains.TeamCity.Tfs.Program.Main(String[] args) in c:\BuildAgent\work\23f504c63c17dfdf\TfsNativeAccessor\src\Program.cs:line 143
--- End of inner exception stack trace ---
at JetBrains.TeamCity.Tfs.Program.Main(String[] args) in c:\BuildAgent\work\23f504c63c17dfdf\TfsNativeAccessor\src\Program.cs:line 438
----------

Maybe the root error is: ERROR - TF400324: Team Foundation services are not available from server http://tfs01:8080/tfs.  

Or maybe it's: Page not found. ---> System.Net.WebException: The remote server returned an error: (404) Not Found.

I assume that this is not all that interesting: Failed for the root 'TruDB-Main' #5: TFS failed. ExitCode: 111



I have verified that I can access TFS inside Visual Studio with the username and password.


Anyone know what's wrong?  What to test/try?
3 comments
Comment actions Permalink

Hi Steve,

Did you ever resolve this issue?

We are experiencing the same thing but for a slightly different setup - we have an on-premise TeamCity server connecting to Visual Studio Online and external NuGet feed. I think server access to internet resources needs to go through a proxy server but I cannot find anything in the TeamCity admin interface or documentation about how to configure proxy settings to be used by TeamCity.

Regards,

Phil

0
Comment actions Permalink

Sorry, even though we did resolve the issue, I don't remember how.  It might come back to me, but don't hold your breath :)

0
Comment actions Permalink

Hi Philip,

Please see How to set up TeamCity behind a proxy server in documentation. Also configuration steps are described in the comment for NuGet related issue.

0

Please sign in to leave a comment.