简体   繁体   中英

Unable to deploy asp.net website inspite of successfully publishing it

I have an asp.net web application which stores and retrieves values from a sql server database. Publish profile is:

    <WebPublishMethod>MSDeploy</WebPublishMethod>
    <LastUsedBuildConfiguration>Debug</LastUsedBuildConfiguration>
    <LastUsedPlatform>Any CPU</LastUsedPlatform>
    <SiteUrlToLaunchAfterPublish>http://localhost:1381/</SiteUrlToLaunchAfterPublish>
    <LaunchSiteAfterPublish>True</LaunchSiteAfterPublish>
    <ExcludeApp_Data>False</ExcludeApp_Data>
    <MSDeployServiceURL>192.168.xx.xx</MSDeployServiceURL>
    <DeployIisAppPath>LMS</DeployIisAppPath>
    <RemoteSitePhysicalPath />
    <SkipExtraFilesOnServer>False</SkipExtraFilesOnServer>
    <MSDeployPublishMethod>WMSVC</MSDeployPublishMethod>
    <EnableMSDeployBackup>False</EnableMSDeployBackup>
    <UserName>administrator</UserName>
    <_SavePWD>True</_SavePWD>

It builds successfully. When published it shows the following error:

Web deployment task failed. (Could not connect to the remote computer ("192.168.10.237") using the specified process ("Web Management Service") because the server 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/?LinkId=221672#ERROR_COULD_NOT_CONNECT_TO_REMOTESVC .)

I have checked that the said service is running on the remote computer. What I am trying to do is deploy this on our intranet server which houses our active directory services too. It publishes successfully on the local machine but when accessing it through the browser, it shows error 500.19 and fails to connect. To resolve it I followed everything said here:

http://support.microsoft.com/kb/942055

But all in vain. I have tried publishing the website and database separately as in using the File System and FTP publish methods too, but nothing works. Please help.

  • Install IIS and the Web Management Service on your Windows Server

  • Configure WMSVC so that remote connections are allowed.

check out this blog click here

I had this problem connecting Visual Studio 2015 to a Windows Server 2016. The suggestions at https://www.iis.net/learn/publish/troubleshooting-web-deploy/troubleshooting-web-deploy-problems-with-visual-studio solved it - I had to check and change quite a few firewall rules and services, and I think some of them took a few minutes to take effect so I'm not exactly what fixed it for me.

But I think specifically checking "enable remote connections" in the management service control panel, and then restarting the service, was a big one that was hard to find.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM