Today I ran into an issue at my client that I thought was worth writing about.
I have created a separte web application for collaboration sites (i.e http://collaboration). The client wanted to have a security trimmed list (Links) of all the collaboration sites that the user was able to access. I did some research and determined an approach using the serach.asmx webservice. I created a new data service referencing
http://collaboration/_vti_bin/search.asmx and configured my search query for the “queryex” method. I found a good example of what I wanted to do on a blog called Mikes Notebook (thanks Mike). Here is a reference http://mikesnotebook.wordpress.com/2012/01/16/global-site-directory-for-sharepoint-2010/.
I am using a data view web part to display the data from the datasource. The query in the datasource uses a specific search scope to return all the sites that the logged in user has access to under the specific site collection. It returns the Title, Description of the site and the url. Here is an example of what it looks like
This code worked in my single server dev envrionment with no issues. In the production environment is was only working randomly. It was intermittently failing with an error. I could hit F5 to refresh the page and then it would work. After digging into the uls logs I saw that it was getting a Unauthroized 401 error.
Both of the web front ends have been configured to disable the loopback check. What was happening to the best of my knowledge was probably a double hop type issue, and we are using ntlm.
The request would come in under the load balanced ip address of say 175.xxx.xx.xxx and then it would be on one of the web front ends say 10.xxx.xx.150 and then it would try to call out to the webservice i.e http://collaboration.somesite.com/_vti_bin/search.asmx this call was failing since it would resolve back out to the 175.xxx.xx.xxx ip address.
I ended up putting a host entry in both web front end servers to route collaboration.somesite.com to the local virtualized ip address of the individual web front end.
I hope this may save someone in the future from dealing with a similiar issue. I could envision this happening in other areas as well.

Today I had lunch at a local sandwhich shop near my house and I was suprised to see they had a Coca-Cola Freestyle. I saw a tv program on CNBC about Coke probably over a year or so ago where they mentioned this machine. 