Tuesday, March 25, 2008

/LM/W3SVC/1/ROOT/AppName is unavailable

So I created this neat c# web service and went to deploy it to our clustered environment.
Before that I ran the web setup on a dev server and it installed flawlessly so what a big surprise it was that when i tried to install it in production I got this lovely message:



(it says: 'the specified path 'lm/w3svc/1/root/yourappname' is unavailable. the internet information server might not be running or the path exists and is redirected to another machine. please check the status of this virtual directory in the internet services manager')

don't you love it when all is fine while you develop but when you try to deploy something maddeningly breaks...

Few hours of google search didn't bring any solutions, so i had to figure it out myself, being the genius IIS admin, that i am (not).
first i thought this might be due to our production servers being in a cluster, (mis?)lead by the '...is redirected to another machine' part of the message, but even taking one or the other of the servers off the cluster (temporarily) didn't help.
after a few similar guess/error tries i simply created a folder in inetpub where my web service would be dwelling, created a virtual folder pointing to this empty folder, run the setup again and.....it didnt break this time(!) - simply copied the contents of the web service and off we went

so i guess Okam's razor works...even for deploying c# web service solutions in IIS

lovely ;-)