Failed to complete deployment task in Visual Studio 2010

I am trying to use the VS2010 1-Click Publish publishing function to deploy a test site from my laptop to my server. I have a firewall disabled on both machines, and the MS Deployment Service works on both my laptop and server.

However, when I try to publish VS2010 on my laptop, I get the following error:

Error 1 The network deployment task could not be established (the remote agent (URL https://192.168.1.181/:8172/msdeploy.axd?site=LocationsTest ) could not be contacted. Make sure that the remote agent service is installed and running on the target computer.)
The requested resource does not exist, or the requested URL is invalid.
Error Information:
The remote agent (URL https://192.168.1.181/:8172/msdeploy.axd?site=LocationsTest ) failed to bind. Verify that the remote agent service is installed and running on the target computer.
An unsupported response was received. The response header 'MSDeploy.Response' was '', but 'v1' was expected.
The remote server responded with an error: (404) Not found. 0 0 Test.Web

Any idea what I'm doing wrong here?

+63
visual-studio visual-studio-2010 web-deployment-project
May 31 '10 at 22:53
source share
15 answers

Make sure that the WMSvc service (website management service) is set to "Auto" (and running), so it is turned on when you reboot and check this link

+38
Jun 01 '10 at 17:18
source share

Restart visual studio .

It appeared to me several times after you successfully deployed WebApp on a server with IIS 7.5. Obviously, since the deployment / publication was successfully completed on the server before this error, there was very little that could go to the wrong server setup / configuration (if the previous successful deployment did not do something terribly wrong and deleted some configuration parameters to the server )

After restarting the server, make sure that the web management service and the web deployment service are working correctly, and checked with the cUrl tool that the GET from MsDeploy.axd was successful, there is only one thing left. Restart Visual Studio. The magical post-restart posting VS started working again. All by itself. The magic stuff is deployment on the Internet :)

+72
Aug 01 '11 at 6:29
source share

Make sure that you have correctly installed the site / application in the publication profile: Publish profile dialog in Visual Studio 2010

You get the same error message if the site or application name is spelled incorrectly.

+18
Mar 29 '11 at 19:07
source share

Although many different unrelated things can contribute to getting 404, I decided it for my own.

  • When installing / reinstalling the WebDeploy installer, select "Custom / Change", and then make sure that the "Service Management Delegation Interface" is one of the installed parameters, it is not installed by default, but is necessary for WebDeploy to work (installer error).
  • Use the new management service delegation icon on the IIS Manager node server to add the default "Deploy applications with content" role. But you can also specify the Run As option with a user who has the right to change IIS settings.
  • Restart the web management service.

After that, everything works fine. Assuming the web management service is configured correctly (mine is configured to accept remote connections, the firewall port was open, and the user I was loading from was added to each individual site I want to deploy (using the IMS Manager Permissions icon on each node site in IIS Manager).

+13
Oct 06 '11 at 12:10
source share

We found that the problem was that WebDeploy was installed before the web management service was enabled on the Windows 2008 server. After installing the web management service, completely uninstall Web Deploy. Then tarry and make sure all package components are selected.

After reinstallation, we were immediately able to publish to the server from my local machine, as well as from our CI.

A few words that should be noted after reading the other answers:

  • If you get 404 error, the problem is not security.
  • We did not have to restart Visual Studio for this change to take effect.
  • Reinstallation will start in automatic mode, do not use this setting.
+11
Mar 31 '12 at 2:59 a.m.
source share

I was able to fix the same problem when I changed the "Service URL" that uses the "Windows Management Service":

https://ExampleURL:8172/msdeploy.axd?site=SiteName 

to this, which uses the "Remote Agent Service" instead:

 http://ExampleURL 

After that, he did a great job.

+4
Jul 20 '12 at 19:55
source share

I got this error because I changed my password. The deployment wizard still saved my old password, after it retyped my password, now everything works fine.

+2
Feb 08 2018-12-12T00:
source share

I have installed a couple of web servers and I keep getting this problem, so I post my answer here to find it when I have a Google problem.

Basically, I always install Web Deploy 3 from the web platform installer. This is the first mistake. For some reason, this only installs half the material you need. If you installed this, uninstall it and download the Web Deploy installer. Then select “Finish” the installation.

If you follow this guide

Then ignore option 1. It's a trap

Start reading again with " 2. Download the Web Deploy Installer ... "

+2
May 27 '13 at 14:28
source share

Stupid to me, I did not have .NET 4 installed on the server

+1
Aug 14 '12 at 20:27
source share

I got 404 from IE browser from https: // servername: 8172 / MsDeploy.axd

But Chrome was not worried.

This may be the first test to find out if you can even contact the web management service on the server. In other words: When chome worked (it responded with a blank page), you have access to the service on the server.

However, you also need to have permission to deploy to a specific site. In IIS, locate the site and do it in the "IIS Manager Permissions" in the "Management" section.

+1
Oct 10 '12 at 9:20
source share

The same message will happen almost by accident when publishing projects with visual studio 2010.

The removal of the $projectname.Publish.xml file (in the project root directory) and its re-creation was fixed.

0
May 17 '11 at 9:55
source share

If you are using an SSL certificate, you must log in to the management service in the manager section of the IIS Server Manager and stop the service, select the correct certificate and start the service again. This is what worked for me (I was receiving a Forbidden message).

0
Oct 18 '11 at 13:17
source share

Like the dummy, this error threw itself at me because I did not install Remote Web Agent as part of the web deployment tool used here .

0
Aug 18 2018-12-18T00:
source share

Despite the fact that all the necessary software was installed, I had a similar error. I noticed that the service URL was not prefixed with http: //. After the prefix, it works well.

0
Apr 28 '14 at 4:32
source share

I was getting similar errors from VS 2013 and found a fix that I did not see about, mentioned any other answers.

Mistake:

  • The connected connection was closed
  • Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host from the build server (TFS 2010).

Fix:

The fix in my case was to include TLS 1.0 in the target again. This is a registry key, but I use the free IISCrypto applet for this.

0
Jul 05 '15 at
source share



All Articles