The past few weeks I was challenged on my current project to get an environment set up that works well with Microsoft Test Manager (MTM). To give some context, MTM and the test agents work great if you work in a simple domain configuration, but I work in an environment where there is a set of active directory domains and trust relationships. In such an environment, you might hit some roadblocks.
To give an overview on the basic setup of this environment:
So I am the blue guy trying to do some work in MTM (especially automating my test runs) and I work from Domain PROD
I have my test controller running on our build server, since that machine doesn’t have to do anything most of the day. that server is running in domain DEV
My test server is running IIS and is the web server of our web application. This server also runs in Domain DEV, same as our Database Server.
So what are the problems I ran into and how where they solved?
First of all, getting the Test controller up and running on the build server was easy, just install the Visual Studio Test Controller 2010 as found in this download. I run the build controller under a custom domain service account and gave it the appropriate rights (place them in the specially created admin groups). btw. Make sure you install SP1 of Visual Studio 2010 here as well, since that includes some important patches for your controller and agent infrastructure.
So the real challenge I faced was getting MTM to work with the test controller in domain DEV. I work in domain PROD and try to connect to the controller running in Domain DEV.
I constantly saw the controller running when I logged on in domain DEV and when I try to look if the controller is visible from domain DEV, then that just works fine. Only when I connect from Domain PROD workstation to Domain DEV test controller I see the controller is not available 🙁
When I looked at the client and server communication using e.g. process monitor from sysinternals, you see the two have successful communication. The connect and exchange data, but I still get the controller symbol not available ….
Next step was to enable tracing of the controller on the server and there it revealed something that was really a pity to find. It seems that the MTM tries to connect to the controller and that succeeds, but it will try to set up a second communication channel. It seems the test controller is communicating the server endpoint back to MTM to connect. When it communicates this hostname to MTM it does not use the fully qualified domain name. Now this is not a problem when you run in one domain. But running in two domains breaks this scenario, because domain PROD has an other default DNS suffix then Domain DEV. Meaning that the communicated host name can not be resolved.
The way you can fix this is by adding the controller name (so the NetBIOS name not the fully qualified domain name) in the host file on your machine (<installdrive>\windows\system32\drivers\etc)
There you add the name of the test controller and it’s IP address. Once you have done that, you can refresh the controller status page in MTM and you will see it works correct. (and hope the machine does not change IP)
All in all a pain in the but, but once you have found the work around it works as excepted.
One thing to note is that I am using MTM 2010 here, I have not been able to use the 2012 product in this specific environment and it will take some month before we are allowed to upgrade the TFS server to 2012. Once we have that upgraded we will use MTM 2012 and I hope these issues are solved.
CTO at Xpirit, Microsoft Regional Director, Visual studio ALM MVP, Speaker, Pluralsight Author and IT Architect Consultant