Web Deployment Tool (MS Deploy)
Visual Studio 2012 Web Deploy to Windows Server 2008 R2 with IIS 7 an...
Last post Aug 01, 2013 01:46 AM by email@example.com
Jul 14, 2012 07:14 PM|leniel|LINK
In Visual Studio 2012 RC when I try to validate a Web Deploy connection I get this error message:
The required Web Management Service is started on the server and Web Deploy 3.0 RC is installed.
Then using Remote Desktop Connection I log on the server and go check
logs located at C:\inetpub\logs\LogFiles\W3SVC1
2012-07-13 20:58:49 126.96.36.199 HEAD /msdeploy.axd site=Default%20Web%20Site 8172 - 188.8.131.52 - 404 0 2 78
It's giving me a 404.
After trying to get this working for almost 6 hours now (reading a
lot of material including this great Troubleshooting guide by IIS team
titled Troubleshooting Web Deploy problems with Visual Studio and this related question Visual Studio 2010 Web deployment task failed)
I decided to ask for help here and see if anyone has a clue about what
can be the problem... Do you know what's causing this 404 error?
If you need any more info, just ask me and I'll provide it... :)
Yesterday I also tried the following
C:\Program Files\IIS\Microsoft Web Deploy V3>msdeploy -verb:dump -source:content
Info: Using ID 'a246a13c-7777-4226-964c-fe9934c60b77' for connections to the rem
Windows Server 2008 Firewall is disabled and I can access IIS on the server from my local machine with these URLs:
Windows Server 2008
visual studio 2012
Jul 17, 2012 09:52 PM|krolson|LINK
Is it true that you are an administrator on xxxxxxx.publiccloud.com.br server? It looks like you are (as in your edit you are able to view content using what we call the "agent" service - which is an admin only service). Web Deploy will let you publish with
either of 2 services: MSDepSvc (the "agent" service that is administrator only and installs with Web Deploy) and WMSvc (the "handler" service that is delegatable to non-admins and relies on WMSvc IIS component being installed). They each use different URLs
for the connection - so I can tell that the successful comman is an Agent command by the "computeranme" value.
If you are an administrator, and the dump command is working for you, you can try just switching VS to using the Agent service instead of WMSvc (WMSvc is the default if you specify only the computer name for Service URL). I believe you can tell VS to use
the Agent by specifying the Service URL as http://<serverName>
EDIT: looks like formatting got weird - just to be clear - there should be no carats in that Service URL
If you would like to keep using the WMSvc service, I can try to help you troubleshoot further. An equivalent msdeploy command to check the connectiong that uses the handler would look like this:
msdeploy.exe -verb:dump -source:iisapp="Default Web Site",computername=https://xxxxx.publiccloud.com.br:8172/msdeploy.axd?site=Default%20Web%20Site,username=<User name>,password=<Password>,authType=basic -allowUntrusted
Jul 18, 2012 12:05 AM|leniel|LINK
Thanks for taking the time to answer the question. I really appreciate it! :)
Is it true that you are an administrator on xxxxxxx.publiccloud.com.br server?
Yes, this is a dedicated server a client rented here in Brazil and I'm using the Administrator account. This hosting provider has their own firewall and the ports 8172, 443, 80, etc... are also opened there while the Win 2008 server's own firewall is completely
I managed to overcome the 404 error I described and now I'm stuck with a 503 (Server unavailable) error. I have documented my steps at StackOverflow with more details (I initially posted this question there). Here's the link:
If you have any clue about what can be causing such 503, I'd be happy to try to troubleshoot further because it's really compensating when we get things working the way they should. I particularly learned a lot this last weekend just fiddling with IIS and Windows
Server 2008. :D
By the way: trying to solve the 503 error I tried changing the the Default Web Site's AppPool Identity but nothing changed... and the AppPool is Started for sure. :) I mention this because if you search Google for 503 and IIS you'll find a lot of similar problems
related to AppPool being stopped. Of course there can be many reasons for the 503 error but I couldn't figure out what's going on with the server (maybe some additional Service is stopped or even a Role Service wasn't added, beats me!).
I also looked IIS logs everywhere and couldn't find any valuable information... :(
As I mention at StackOverflow, I got this messed up Win Server 2008 and if I can't get Web Deploy working I think the best solution is to do a clean install of Win Server 2008 and start again. :)
I tried the command you mentioned and this is the 503 error I told you:
C:\Program Files\IIS\Microsoft Web Deploy V3>msdeploy.exe -verb:dump -source:iis
app="Default Web Site",computername=https://xxxxxxxxxx.publiccloud.com.br:8172/ms
Info: Using ID 'dc905e17-03cd-45bb-8b6b-f28ca24579ad' for connections to the rem
Error Code: ERROR_COULD_NOT_CONNECT_TO_REMOTESVC
More Information: Could not connect to the remote computer ("xxxxxxxxxx.publicclo
ud.com.br") using the specified process ("Web Management Service") because the s
erver did not respond. Make sure that the process ("Web Management Service") is
started on the remote computer. Learn more at: http://go.microsoft.com/fwlink/?
Error: The remote server returned an error: (503) Server Unavailable.
Error count: 1.
Web Management Service is started for sure! :)
Aug 10, 2012 05:07 PM|krolson|LINK
Sorry for the delayed reply! Did you try using the agent service instead (i.e. change the computer name value in your publish settings to
http://servername - and use admin credentials)? If you do a command like the following, and it works, it means you should be able to publish using this administrator service rather than WMSvc:
msdeploy.exe -verb:dump -source:iisapp="Default Web Site",computername=xxxxx.publiccloud.com.br,username=<AdminUser name>,password=<Password>
Another thing to try is just to see if the issue is limited to the WMSvc connection. Web Deploy on the server side won't even see your request until after it gets through the WMSvc connection. Could you try connecting through inetmgr (which uses WMSvc) using
the same credentials that were giving you the 503 earlier? There's a walkthrough of how to do this connection in this section "Connect to a Site or an Application in IIS Manager" (http://learn.iis.net/page.aspx/159/configuring-remote-administration-and-feature-delegation-in-iis-7/)
- though if you are on a client SKU you may first need to install IIS Manager for Remote Administration, available in WebPI or directly here:
Aug 01, 2013 01:46 AMfirstname.lastname@example.org|LINK
Web Deploy using the Agent Service
1. http://test.com/ I believe you need the http protocol this maybe obscured but just to be clear in the service URL
2. Web Deploy has to be installed on the target server and the service has to be runnning and port 80 or 443 open in both firewalls at both ends and any in between.
3. the pool account has to have read, execute and list contents on the targetted web apps directory (root folder)
4. username and password have to be correct domainname\username or machinename\username if its in a work group
5. the site name is actually the name of the website in IIS (the picture of the little planet)
6. Getting a 404 may indicate that ASP.NET is not registered on the IIS Web Server and you will need to run aspnet_iisreg.exe from the relevant .NET frameworks root directory
http://technet.microsoft.com/en-us/library/dd569059(v=ws.10).aspx web deploy 3.0 uses .NET 4.0 (ASP.NET 4.0)