MSDeploy - Destination Not Reachable - asp.net

I have installed Web Deploy 3.5 on Windows Server 2008 R2 and tried to run remote publish web application through visual studio 2012. However, I got the error - Destination Not Reachable.
I read some post and checked below and still got no luck.
Firewall was off
Both Web Management Service and Web Deployment Agent Service were restarted and running
Tried to open https://[server]:8172/msDeploy.axd in a browser and it is reachable. (Use default 8172)
Tried to use http://[server]/MsDeployAgentService and it is working with Admin username/password.
Did I miss anything? Thanks.

Maybe same issue as in https://stackoverflow.com/questions/16708021/msdeploy-wmsvc-not-working ?
It appears you have to activate the web management service first and
then install web deploy and i'd done it the other way round. I
uninstalled WebDeploy and re-installed it, restarted the server and
its working

I also met the same problem. When installing WebDeploy, do not choose classic installation, but choose complete installation.

If you messed with SSL certificates this could be one of the causes as well:
https://serverfault.com/questions/613634/could-not-connect-to-remote-computer-web-deploy-error-destination-not-reachable#answer-812712

Related

ERR_CONNECTION_RESET with IIS express in Visual Studio 2017

We´ve created a ASP.Net Core Web App and added some controllers. For some reason when I want to run the application, it connects to my local IIS express and the only message that occurs is the following
ERR_CONNECTION_RESET
I don´t try to connect to the port via SSL, so I don´t think it´s a certificate issue.
It doesn´t matter which controller I try to call. For some reason this behaviour appears just on my machine. If I create a new Wep App it works perfectly fine.
I tried the following steps:
Changed the port number in the web server settings in the project properties
Uninstalled IIS Express and reinstalled it
Deleted the hole .vs folder in my project
Host the web app on my local IIS Server
Compared the hole project settings with the project settings of a machine, where it runs fine
I´m stuck on this problem for 2 days now and don´t want to reinstall VS2017. Maybe it´s just a little thing which I´ve missed.
Thanks for your replies :)
The problem was based on my Visual Studio instance. Reinstalling Visual Studio + repairing after this over the VS-installer solved my problem
If your problem is: ERR_CONNECTION_RESET and you said you tried:
Changed the port number in the web server settings in the project properties
Consider that IIS express reserve ports in the range 44300 to 44399.
I had exatly the same ERR_CONNECTION_RESET when i set IIS Express port out of this range.
The solution was to put port number inside this range. Hope it helps you.

Problems publishing site to localhost on windows 2008 rs server

I must preface this post by saying that I am not an experienced developer, I am in the process of learning through trial and error and a lot of google searches so detailed (step-by-step) feedback would be greatly appreciated. I created a website, which does not use a database, using visual studio 2015 and I am attempting to host it locally on a Windows 2008 R2 server.
I installed IIS and loaded the asp.net v4.0 framework. The site works fine, produces no errors when I test it and works after being published only if the visual studio is still running.
However, when I close the Visual studio and open my browser window to http://localhost:50044 (which is the URL listed in properties menu in VS), I also tried using port :80 and nothing. When trying to add Web Site via the IIS management utility I receive the following authentication error: ”Cannot verify access path (C:\Inetpub\wwwroot).”
I checked the permissions and windows authentication is enabled with read access, and all other permissions seem to be correct. I am at a loss, I'm sure it is probably something simple that I am missing due to my lack of knowledge and experience. Any help would be appreciated.
It's sounds like you are running on IIS express which in your case stops running when you close visual studio. Normal process is create a new website in IIS and point to the folder where your web.config is. You can then hack your host file (C:\Windows\System32\drivers\etc) so DNS works. Add an entry like "127.0.0.1 mytestwebsite.com". I hope that helps
So I figured out part of what was happening. I didn't realize that visual studio has built in IIS and was using that by default.
I ran VS as an admin, created a new project, then attempted to create a virtual directory thru VS under the project/properties/web tab. I selected local IIS and entered http://localhost/boc and it returns an error: unable to create vd. Web server http://localhost... Could not be found.
I then went in to the IIS manager and set up a virtual directory with no issues. However, when I attempt to reference it thru VS I again receive an error message.
Any ideas?

Error: "The configuration section 'system.webServer/management/delegation' cannot be read because it is missing schema

I am trying to publish a website from my computer to an IIS web server via web deploy.
I have 3 servers. All servers have installed the same things (Webdeploy etc.) and the services are started (Web Deployment Agent Service and Web Management Service).
On the first server I have no problems on connecting. But the other two servers give me some error when I "Validate Connection" in Visual Studio to the IIS. When I look at the logs on the IIS server, there are my accesses listet with html code 200 (ok).
An error ocurred when the request was processed on the remote computer. Filename: MACHINE/WEBROOT
Error: The configuration section 'system.webServer/management/delegation' cannot be read because it is missing schema
I really have no idea what could solve this problem and hope you are able to help me.
I had the exact same problem, it turned out I had installed Web Deploy 3.6 on top of 3.5. Remove Web Deploy 3.6 and reinstall 3.5 and see if it solves your issue.
You can also try #james-wilkins comment below: "In my case I installed Web Deploy BEFORE installing the management service..."
Uninstall and then re-install Web Deploy.
This fixed the problem for me -- the 'repair' option in the installer did not.
In my case, I installed Web Deploy BEFORE installing the management service. I tried to do a "change" on the install to include the management service (or you can add the feature from add/remove windows features), but that didn't help (got the error on this post). In the end, a simple uninstall and reinstall of 3.6 was what worked for me. Seems it needs the Web Management Service to be installed FIRST. Typical MS instructions don't even mention this at all.

Visual Studio Debug says Unable to launch IIS Express Web server (failed to register localhost:443)

I am using VS2012, .NET 4.5. I just downloaded NuGetGalary from github and trying to build and run the Web application of it.
I am using IIS Express with project Url http://localhost:8081
But when I launch the project, I get the following error message
What could be wrong ?
Silly reason,
I used this Microsoft Support Article to find out what was wrong. Turned out it was VMWare Workstation Server service holding up the 443 port. I stopped the service and now project launches fine.
Since I can't add comments yet, I put my thoughts here.
Since you launch the site on "localhost:8081", and it can't be launched because of port 443 being used, it's probably that inside the solution, some service is started, and by default is running on 443.
Your solution consisted of stopping the app "VMWare Workstation Server" which seemed to be using the same port. This might not always be possible, depending the type of app using the port.
What you could also have done (maybe), is configuring the project/service (inside Visual Studio) to use another port than 443.
You can usually find this element in the project properties.

Visual Studio 2012 Web Deploy to Windows Server 2008 R2 with IIS 7 and /msdeploy.axd 404 error

In Visual Studio 2012 RC when I try to validate a Web Deploy connection I get this error message:
ERROR_DESTINATION_NOT_REACHABLE
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 IIS logs located at C:\inetpub\logs\LogFiles\W3SVC1. There I can see my attempts to validate the connection because they contain my IP address:
2012-07-13 20:58:49 185.201.117.17 HEAD /msdeploy.axd site=Default%20Web%20Site 8172 - 189.10.32.194 - 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... :)
Edit 1
Yesterday I also tried the following msdeploy command on my local machine to list the the contents of a folder called test on the server [ and it worked as expected ]:
C:\Program Files\IIS\Microsoft Web Deploy V3>msdeploy -verb:dump -source:content
path=c:\test,computerName=xxxxxxxxxx.publiccloud.com.br,username=User,password=Password
Info: Using ID 'a246a13c-7777-4226-964c-fe9934c60b77' for connections to the rem
ote server.
MSDeploy.contentPath
c:\test
c:\test
c:\test\test.txt
Edit 2
After a lot of install/reinstall operations I finally got to a point where Windows Server 2008 is returning a 503 HTTP error when I try to publish the web site using VS 2012 RC or even msdeploy in the command line.
Looks like the best thing to do now is to do a clean install of Windows Server 2008 since I got a messed up VM server image to work with. Hope it'll do the trick.
Just for the record, this is the msdeploy command VS 2012 tries to execute. I did a copy/paste and tried it with msdeploy in the command line:
C:\Program Files (x86)\IIS\Microsoft Web Deploy V3\msdeploy.exe -source:manifest='E:\SISPEC\SISPEC\obj\Release\Package\SISPEC.SourceManifest.xml' -dest:auto,ComputerName="https://xxxxxxxxxx.publiccloud.com.br:8172/msdeploy.axd?site=Default%20Web%20Site",UserName='UserName',Password='Password',IncludeAcls='False',AuthType='Basic' -verb:sync -enableRule:DoNotDeleteRule -disableLink:AppPoolExtension -disableLink:ContentExtension -disableLink:CertificateExtension -setParamFile:"E:\SISPEC\SISPEC\obj\Release\Package\SISPEC.Publish.Parameters.xml" -retryAttempts=2
just to get the same 503 Server Unavailable message.
Edit 3
This question was cross-posted at the IIS Web Deployment Tool (MS Deploy) forum here.
Fyi - I too was getting the 404 errors. It turned out that I had to download the full package and install everything.
http://www.iis.net/downloads/microsoft/web-deploy#additionalDownloads
I had this same error (ERROR_DESTINATION_NOT_REACHABLE). I was able to fix the issue by opening port 8172.
I then ran into the error: ERR_COULD_NOT_CONNECT_TO_REMOVESVC which I was able to resolve by installing every component of Web Deploy 3.0. It was trying to hit /MSDEPLOYAGENTSERVICE which by default isn't installed by the Web Deploy 3.0 installer.
I had to manually add the Deployment Handler. In IIS Manager, with the server selected, choose "IIS|Handler Mappings|Add Managed Handler...".
Request path: msdeploy.axd
Type: Microsoft.Web.Deployment.DeploymentAgentHandler,..., Version=9...
Name: Web Deploy Whatever
In my case, the default certificate issued for WMSVC was not issued for the machine-name. My Solution was to:
Issue a certificate for the machine name from my domain CA. This could be self-signed if you're willing to trust the certificate.
Install that certificate under the Personal certificate store
stop the web management service
change the certificate to my properly issued certificate
restart the service.
Did you check your handlers? You can test this by creating an HTML page on the same folder and trying to access that HTML. If you can, then go check that your site has the necessary handlers. Also, make sure your DNS record are pointing to the correct IP address.
First I tried just Repair install of Web Deploy 3.0 and not worked. Removing and installing solved my issue.
In my case I had both Web Deploy 2.0 and 3.0 on server machine.
Removing both and installing just 3.0 solved my issue.
Ensure Web Management Service is started.
I deleted SSL certificate and the service stopped working.
If all previous indications fail, and if you are using an Azure virtual machine, where the endpoint for 8172 is open, I have solved it deleting the endpoint and opening it again. I believe the first time I have selected using Floating IP Enabled, and that did not work. Just create the endpoint again, select disable floating ip and done!

Resources