Search code examples
msdeploymicrosoft-web-deploy

Web deploy error ERROR_DESTINATION_NOT_REACHABLE


I am trying to deploy my application using the following msdeploy command:

MSDeploy.exe -source:contentPath="C:\Users\myUser\Documents\ui\dist" -dest:contentPath='c:/inetpub/wwwroot/dist',computerName="https://ec2-xx-xxx-xx-xx.ap-northeast-1.compute.amazonaws.com:8172/MSDeploy.axd?site=Default Web Site",username="administrator",password="XXXXXXXXX",authtype="Basic",includeAcls="False" -verb:sync -allowUntrusted

Getting the following error:

Working...
    Info: Using ID '01657062-cece-4713-8dc6-585537b265fd' for connections to the rem
    ote server.
    >> Error Code: ERROR_DESTINATION_NOT_REACHABLE
    >> More Information: Could not connect to the remote computer ("ec2-52-207-222-6
    5.compute-1.amazonaws.com"). On the remote computer, make sure that Web Deploy i
    s installed and that the required process ("Web Management Service") is started.
      Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_DESTINATION
    _NOT_REACHABLE.
    >> Error: Unable to connect to the remote server
    >> Error: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond xx.xxx.xx.xx:8172

I tried the same command for 6 other servers and it worked fine, but not working for 2 of the servers which are configured the same way.

  1. All the IIS installables are in place
  2. Firewall inbound rule for port 8172 (TCP) is in place, There are no issues with the other Firewall rules as i have turned the Firewalls off
  3. Installed Web Deploy 3.6 and Web deploy 3.6 for Hosting servers
  4. Made sure Web Management Service,Web Deployment Agent Service is started and set to Automatic

What am i missing ?


Solution

  • Added the rule to security group for port 8172 and it started working. But i have no clue why it was working from Visual studio before and not from command prompt.