Skip to content

Commit 88531f8

Browse files
authored
Merge pull request #8609 from Mikejo5000/mikejo-jsts2
Freshness pass on WS 2019, IIS docs for deployment and remote debugging
2 parents f4e975c + 9080c20 commit 88531f8

7 files changed

+60
-18
lines changed

docs/debugger/remote-debugging-aspnet-on-a-remote-iis-7-5-computer.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: "Remote debug ASP.NET on an IIS computer"
33
description: Learn how to set up and configure a Visual Studio ASP.NET MVC 4.5.2 application, deploy it to IIS, and attach the remote debugger from Visual Studio.
44
ms.custom: ['remotedebugging', 'seodec18']
5-
ms.date: 05/06/2020
5+
ms.date: 08/31/2021
66
ms.topic: "conceptual"
77
ms.assetid: 9cb339b5-3caf-4755-aad1-4a5da54b2a23
88
author: "mikejo5000"
@@ -244,7 +244,16 @@ For information on running the remote debugger as a service, see [Run the remote
244244

245245
The breakpoint should be hit in Visual Studio.
246246

247-
## <a name="bkmk_openports"></a> Troubleshooting: Open required ports on Windows Server
247+
## Troubleshooting IIS deployment
248+
249+
- If you can't connect to the host using the host name, try the IP address instead.
250+
- Make sure the required ports are open on the remote server.
251+
- Verify that the version of ASP.NET used in your app is the same as the version you installed on the server. For your app, you can view and set the version in the **Properties** page. To set the app to a different version, that version must be installed.
252+
- If the app tried to open, but you see a certificate warning, choose to trust the site. If you already closed the warning, you can edit the publishing profile, a *.pubxml file, in your project and add the following element (for test only): `<AllowUntrustedCertificate>true</AllowUntrustedCertificate>`
253+
- If the app does not start from Visual Studio, start the app in IIS to test that it deployed correctly.
254+
- Check the Output window in Visual Studio for status information, and check your error messages.
255+
-
256+
## <a name="bkmk_openports"></a> Open required ports on Windows Server
248257

249258
In most setups, required ports are opened by the installation of ASP.NET and the remote debugger. However, you may need to verify that ports are open.
250259

docs/debugger/remote-debugging-aspnet-on-a-remote-iis-computer.md

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: "Remote Debug ASP.NET Core on a Remote IIS Computer | Microsoft Docs"
33
description: Debug an ASP.NET Core application that has been deployed to a remote Internet Information Services (IIS) computer using the Visual Studio remote debugger.
44
ms.custom: "remotedebugging, SEO-VS-2020"
5-
ms.date: 05/06/2020
5+
ms.date: 08/27/2021
66
ms.topic: "conceptual"
77
ms.assetid: 573a3fc5-6901-41f1-bc87-557aa45d8858
88
author: "mikejo5000"
@@ -81,7 +81,7 @@ When you download the software, you may get requests to grant permission to load
8181

8282
1. Install the .NET Core Hosting Bundle on the hosting system. The bundle installs the .NET Core Runtime, .NET Core Library, and the ASP.NET Core Module. For more in-depth instructions, see [Publishing to IIS](/aspnet/core/publishing/iis?tabs=aspnetcore2x#iis-configuration).
8383

84-
For .NET Core 3, install the [.NET Core Hosting Bundle](https://dotnet.microsoft.com/permalink/dotnetcore-current-windows-runtime-bundle-installer).
84+
For the current .NET Core hosting bundle, install the [ASP.NET Core Hosting Bundle](https://dotnet.microsoft.com/permalink/dotnetcore-current-windows-runtime-bundle-installer).
8585
For .NET Core 2, install the [.NET Core Windows Server Hosting](https://aka.ms/dotnetcore-2-windowshosting).
8686

8787
> [!NOTE]
@@ -237,7 +237,17 @@ For information on running the remote debugger as a service, see [Run the remote
237237

238238
The breakpoint should be hit in Visual Studio.
239239

240-
## <a name="bkmk_openports"></a> Troubleshooting: Open required ports on Windows Server
240+
## Troubleshooting IIS deployment
241+
242+
- If you can't connect to the host using the host name, try the IP address instead.
243+
- Make sure the required ports are open on the remote server.
244+
- For ASP.NET Core, you need to make sure that the Application pool field for the **DefaultAppPool** is set to **No Managed Code**.
245+
- Verify that the version of ASP.NET used in your app is the same as the version you installed on the server. For your app, you can view and set the version in the **Properties** page. To set the app to a different version, that version must be installed.
246+
- If the app tried to open, but you see a certificate warning, choose to trust the site. If you already closed the warning, you can edit the publishing profile, a *.pubxml file, in your project and add the following element (for test only): `<AllowUntrustedCertificate>true</AllowUntrustedCertificate>`
247+
- If the app does not start from Visual Studio, start the app in IIS to test that it deployed correctly.
248+
- Check the Output window in Visual Studio for status information, and check your error messages.
249+
250+
## <a name="bkmk_openports"></a> Open required ports on Windows Server
241251

242252
In most setups, required ports are opened by the installation of ASP.NET and the remote debugger. However, you may need to verify that ports are open.
243253

@@ -246,14 +256,14 @@ In most setups, required ports are opened by the installation of ASP.NET and the
246256
247257
Required ports:
248258

249-
* 80 - Required for IIS
259+
* 80 - Required for IIS (HTTP)
250260
::: moniker range=">=vs-2019"
251261
* 4024 - Required for remote debugging from Visual Studio 2019 (see [Remote Debugger Port Assignments](../debugger/remote-debugger-port-assignments.md) for more information).
252262
::: moniker-end
253263
::: moniker range="vs-2017"
254264
* 4022 - Required for remote debugging from Visual Studio 2017 (see [Remote Debugger Port Assignments](../debugger/remote-debugger-port-assignments.md) for more information).
255265
::: moniker-end
256-
* UDP 3702 - (Optional) Discovery port enables you to the **Find** button when attaching to the remote debugger in Visual Studio.
266+
* UDP 3702 - (Optional) Discovery port enables you to use the **Find** button when attaching to the remote debugger in Visual Studio.
257267

258268
1. To open a port on Windows Server, open the **Start** menu, search for **Windows Firewall with Advanced Security**.
259269

@@ -266,6 +276,7 @@ Required ports:
266276
5. Select one or more network types to enable for the port and click **Next**.
267277

268278
The type you select must include the network to which the remote computer is connected.
279+
269280
6. Add the name (for example, **IIS**, **Web Deploy**, or **msvsmon**) for the Inbound Rule and click **Finish**.
270281

271282
You should see your new rule in the Inbound Rules or Outbound Rules list.

docs/debugger/remote-debugging-azure.md

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: "Remote Debug ASP.NET Core on IIS and Azure | Microsoft Docs"
33
description: Learn how to set up and configure a Visual Studio ASP.NET Core app, deploy it to IIS using Azure, and attach the remote debugger from Visual Studio.
44
ms.custom: "remotedebugging"
5-
ms.date: 05/06/2020
5+
ms.date: 08/27/2021
66
ms.topic: "conceptual"
77
ms.assetid: a6c04b53-d1b9-4552-a8fd-3ed6f4902ce6
88
author: "mikejo5000"
@@ -125,9 +125,9 @@ This article includes steps on setting up a basic configuration of IIS on Window
125125

126126
* If you want help to make sure that your app is set up, deployed, and running correctly in IIS so that you can debug, follow all the steps in this topic.
127127

128-
* Before you begin, follow all the steps described in [Install and run IIS](/azure/virtual-machines/windows/quick-create-portal).
128+
* Before you begin, follow all the steps described in [Create a Windows Virtual Machine](/azure/virtual-machines/windows/quick-create-portal), which includes steps to install the IIS web server.
129129

130-
* When you open port 80 in the Network security group, also open the [correct port](#bkmk_openports) for the remote debugger (4024 or 4022). That way, you won't have to open it later. If you're using Web Deploy, also open port 8172.
130+
* Make sure you open port 80 in the Azure [Network security group](/azure/virtual-machines/windows/nsg-quickstart-portal). When you verify that port 80 is open, also open the [correct port](#bkmk_openports) for the remote debugger (4024 or 4022). That way, you won't have to open it later. If you're using Web Deploy, also open port 8172.
131131

132132
### Update browser security settings on Windows Server
133133

@@ -144,7 +144,7 @@ When you download the software, you may get requests to grant permission to load
144144

145145
1. Install the .NET Core Hosting Bundle on the hosting system. The bundle installs the .NET Core Runtime, .NET Core Library, and the ASP.NET Core Module. For more in-depth instructions, see [Publishing to IIS](/aspnet/core/publishing/iis?tabs=aspnetcore2x#iis-configuration).
146146

147-
For .NET Core 3, install the [.NET Core Hosting Bundle](https://dotnet.microsoft.com/permalink/dotnetcore-current-windows-runtime-bundle-installer).
147+
For the current .NET Core hosting bundle, install the [ASP.NET Core Hosting Bundle](https://dotnet.microsoft.com/permalink/dotnetcore-current-windows-runtime-bundle-installer).
148148
For .NET Core 2, install the [.NET Core Windows Server Hosting](https://aka.ms/dotnetcore-2-windowshosting).
149149

150150
> [!NOTE]
@@ -287,7 +287,17 @@ Download the version of the remote tools that matches your version of Visual Stu
287287

288288
The breakpoint should be hit in Visual Studio.
289289

290-
### <a name="bkmk_openports"></a> Troubleshooting: Open required ports on Windows Server
290+
## Troubleshooting IIS deployment
291+
292+
- If you can't connect to the host using the host name, try the IP address instead.
293+
- Make sure the required ports are open on the remote server.
294+
- For ASP.NET Core, you need to make sure that the Application pool field for the **DefaultAppPool** is set to **No Managed Code**.
295+
- Verify that the version of ASP.NET used in your app is the same as the version you installed on the server. For your app, you can view and set the version in the **Properties** page. To set the app to a different version, that version must be installed.
296+
- If the app tried to open, but you see a certificate warning, choose to trust the site. If you already closed the warning, you can edit the publishing profile, a *.pubxml file, in your project and add the following element (for test only): `<AllowUntrustedCertificate>true</AllowUntrustedCertificate>`
297+
- If the app does not start from Visual Studio, start the app in IIS to test that it deployed correctly.
298+
- Check the Output window in Visual Studio for status information, and check your error messages.
299+
300+
### <a name="bkmk_openports"></a> Open required ports on Windows Server
291301

292302
In most setups, required ports are opened by the installation of ASP.NET and the remote debugger. However, if you are troubleshooting deployment issues and the app is hosted behind a firewall, you may need to verify that the correct ports are open.
293303

docs/deployment/includes/create-publish-settings-iis.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@
3333
* The *msdeploy.axd* file referenced in the `publishUrl` attribute is a dynamically generated HTTP handler file for Web Deploy. (For testing purposes, `http://myhostname:8172` generally works as well.)
3434
* The `publishUrl` port is set to port 8172, which is the default for Web Deploy.
3535
* The `destinationAppUrl` port is set to port 80, which is the default for IIS.
36-
* If you are unable to connect to the remote host in Visual Studio using the host name (in later steps), test the IP address in place of the host name.
36+
* If, in later steps, you are unable to connect to the remote host from Visual Studio using the host name, test the server's IP address in place of the host name.
3737

3838
> [!NOTE]
39-
> If you are publishing to IIS running on an Azure VM, you must open the Web Deploy and IIS ports in the Network Security group. For detailed information, see [Install and run IIS](/azure/virtual-machines/windows/quick-create-portal#install-web-server).
39+
> If you are publishing to IIS running on an Azure VM, you must open an inbound port for Web Deploy and IIS in the Network Security group. For detailed information, see [Open ports to a virtual machine](/azure/virtual-machines/windows/nsg-quickstart-portal).
4040

4141
5. Copy this file to the computer where you are running Visual Studio.

docs/deployment/includes/install-web-deploy-with-hosting-server.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
Web Deploy 3.6 for Hosting Servers provides additional configuration features that enable the creation of the publish settings file from the UI.
22

3+
The Web Platform Installer for IIS allows installation of version 3.6, not 4.0, so that is the version we recommend in this article.
4+
35
1. If you have Web Deploy already installed on Windows Server, uninstall it using **Control Panel** > **Programs** > **Uninstall a Program**.
46

57
2. Next, install Web Deploy 3.6 for Hosting Servers on Windows Server.

docs/deployment/tutorial-import-publish-settings-azure.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Publish to Azure by importing publish settings"
33
description: "Create and import a publishing profile to deploy an application from Visual Studio to Azure App Service"
4-
ms.date: 05/06/2020
4+
ms.date: 08/27/2021
55
ms.topic: tutorial
66
helpviewer_keywords:
77
- "deployment, publish settings"
@@ -85,7 +85,7 @@ A publish settings file (*\*.publishsettings*) is different than a publishing pr
8585
msdeploySite="DeployASPDotNetCore"
8686
userName="$DeployASPDotNetCore"
8787
userPWD="abcdefghijklmnopqrstuzwxyz"
88-
destinationAppUrl="http://deployaspdotnetcore20180508031824.azurewebsites.net"
88+
destinationAppUrl="http://deployaspdotnetcore2021.azurewebsites.net"
8989
SQLServerDBConnectionString=""
9090
mySQLDBConnectionString=""
9191
hostingProviderForumLink=""

docs/deployment/tutorial-import-publish-settings-iis.md

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Publish to IIS by importing publish settings"
33
description: "Create and import a publishing profile to deploy an application from Visual Studio to IIS"
4-
ms.date: 05/06/2020
4+
ms.date: 08/27/2021
55
ms.topic: tutorial
66
helpviewer_keywords:
77
- "deployment, publish settings"
@@ -79,7 +79,17 @@ A publish settings file (*\*.publishsettings*) is different than a publishing pr
7979

8080
[!INCLUDE [import-publish-settings](../deployment/includes/import-publish-settings-vs.md)]
8181

82-
After the app deploys successfully, it should start automatically. If it does not start from Visual Studio, start the app in IIS. For ASP.NET Core, you need to make sure that the Application pool field for the **DefaultAppPool** is set to **No Managed Code**.
82+
After the app deploys successfully, it should start automatically.
83+
84+
## Troubleshooting
85+
86+
- If you can't connect to the host using the host name, try the IP address instead.
87+
- Make sure the required ports are open on the remote server.
88+
- For ASP.NET Core, you need to make sure that the Application pool field for the **DefaultAppPool** is set to **No Managed Code**.
89+
- Verify that the version of ASP.NET used in your app is the same as the version you installed on the server. For your app, you can view and set the version in the **Properties** page. To set the app to a different version, that version must be installed.
90+
- If the app tried to open, but you see a certificate warning, choose to trust the site. If you already closed the warning, you can edit the *.pubxml file in your project and add the following element (for test only): `<AllowUntrustedCertificate>true</AllowUntrustedCertificate>`
91+
- If the app does not start from Visual Studio, start the app in IIS to test that it deployed correctly.
92+
- Check the Output window in Visual Studio for status information, and check your error messages.
8393

8494
## Next steps
8595

0 commit comments

Comments
 (0)