Donnerstag, 20. September 2012

HTTP 503 Error in TFS

The night before my TFS Express talk at the BASTA conference I faced an ugly error with my TFS Express installation. The installation ran fine, I could start management console, access the database but trying to access the website at localhost:8080/tfs yielded the 503 error.

As a result of a quick Google query I found out that there is plenty of discussion on the web about this topic, for example at StackOverflow or on MSDN. Some post state that they never found a solution for this, other show a long list of possible things to try - nothing worked for me.

By luck I found the solution to my problem. I used RavenDb on my machine before, which is running on port 8080 as well. Due to a different problem in Raven I had in mind that it does some urlacl-stuff by reserving an urlacl for the URL http://+:8080. This is used to assign rights for accesing this URL for the logged on user. If you face a 503 error when trying to use RavenDb with IIS deployment you should run the following command line:


netsh http delete urlacl http://+:8080/


It seems that running raven from the console does a urlacl reservation, which in turn makes TFS to stop working. The solution to the problem was similar to the solution mentioned on the RavenDb website. Run the above command line and TFS works fine - I assume RavenDb will no longer work properly.

This is neither a RavenDb mistake nor a TFS mistake - you should just configure these servers to run on different ports if they run concurrently.

Anyway this is one possible solutions out of a thousand and perhaps it might save someone some valuable time. Happy serving...




1 Kommentar: