What is windows firewall remote management

Windows Remote Management

Purpose

Windows Remote Management (WinRM) is the Microsoft implementation of WS-Management Protocol, a standard Simple Object Access Protocol (SOAP)-based, firewall-friendly protocol that allows hardware and operating systems, from different vendors, to interoperate.

The WS-Management protocol specification provides a common way for systems to access and exchange management information across an IT infrastructure. WinRM and Intelligent Platform Management Interface (IPMI), along with the Event Collector are components of the Windows Hardware Management features.

Where applicable

You can use WinRM scripting objects, the WinRM command-line tool, or the Windows Remote Shell command line tool WinRS to obtain management data from local and remote computers that may have baseboard management controllers (BMCs). If the computer runs a Windows-based operating system version that includes WinRM, the management data is supplied by Windows Management Instrumentation (WMI).

You can also obtain hardware and system data from WS-Management protocol implementations running on operating systems other than Windows in your enterprise. WinRM establishes a session with a remote computer through the SOAP-based WS-Management protocol rather than a connection through DCOM, as WMI does. Data returned to WS-Management protocol are formatted in XML rather than in objects.

The Intelligent Platform Management Interface (IPMI) WMI provider is a standard WMI provider with classes that obtain BMC sensor data from computers with appropriate hardware. IPMI data can be accessed using the WinRM scripting API, the WMI Scripting, or COM APIs.

Developer audience

The developer audience is the IT Pro who writes scripts to automate the management of servers or the ISV developer obtaining data for management applications.

Run-time requirements

WinRM is part of the operating system. However, to obtain data from remote computers, you must configure a WinRM listener. For more information, see Installation and Configuration for Windows Remote Management. If a BMC is detected at system startup, then the IPMI provider loads; otherwise, the WinRM scripting objects and the WinRM command-line tool are still available.

In this section

Link to public WS-Management protocol specification, WinRM architecture, relationship to WMI, hardware management with the IPMI provider, configuration and installation.

Getting started using the WinRM scripting API and hardware management.

List of scripting interfaces defined by Microsoft Web Services for Management (WS-Management) Automation and class definitions of the WMI classes created by the IPMI provider and classes that communicate with the IPMI driver to obtain baseboard management controller (BMC) data.

Configure remote Management in Server Manager

Applies To: Windows Server (Semi-Annual Channel), Windows Server 2016, Windows Server 2012 R2, Windows Server 2012

In Windows Server, you can use Server Manager to perform management tasks on remote servers. remote management is enabled by default on servers that are running Windows Server 2016. To manage a server remotely by using Server Manager, you add the server to the Server Manager server pool.

You can use Server Manager to manage remote servers that are running older releases of Windows Server, but the following updates are required to fully manage these older operating systems.

To manage servers that are running Windows Server releases older than Windows Server 2016, install the following software and updates to make the older releases of Windows Server manageable by using Server Manager in Windows Server 2016.

Operating System Required Software Manageability
Windows Server 2012 R2 or Windows Server 2012 — .NET Framework 4.6
— Windows Management Framework 5.0. The Windows Management Framework 5.0 download package updates Windows Management Instrumentation (WMI) providers on Windows Server 2012 R2 , Windows Server 2012 , and Windows Server 2008 R2 . The updated WMI providers let Server Manager collect information about roles and features that are installed on the managed servers. Until the update is applied, servers that are running Windows Server 2012 R2 , Windows Server 2012 , or Windows Server 2008 R2 have a manageability status of Not accessible.
— The performance update associated with Knowledge Base article 2682011 is no longer necessary on servers that are running Windows Server 2012 R2 or Windows Server 2012 .
Windows Server 2008 R2 — .NET Framework 4.5
— Windows Management Framework 4.0. The Windows Management Framework 4.0 download package updates Windows Management Instrumentation (WMI) providers on Windows Server 2008 R2 . The updated WMI providers let Server Manager collect information about roles and features that are installed on the managed servers. Until the update is applied, servers that are running Windows Server 2008 R2 have a manageability status of Not accessible.
— The performance update associated with Knowledge Base article 2682011 lets Server Manager collect performance data from Windows Server 2008 R2 .
Windows Server 2008 — .NET Framework 4
— Windows Management Framework 3.0 The Windows Management Framework 3.0 download package updates Windows Management Instrumentation (WMI) providers on Windows Server 2008 . The updated WMI providers let Server Manager collect information about roles and features that are installed on the managed servers. Until the update is applied, servers that are running Windows Server 2008 have a manageability status of Not accessible — verify earlier versions run Windows Management Framework 3.0.
— The performance update associated with Knowledge Base article 2682011 lets Server Manager collect performance data from Windows Server 2008 .

for detailed information about how to add servers that are in workgroups to manage, or manage remote servers from a workgroup computer that is running Server Manager, see add Servers to Server Manager.

Enabling or disabling remote management

In Windows Server 2016, remote management is enabled by default. Before you can connect to a computer that is running Windows Server 2016 remotely by using Server Manager, Server Manager remote management must be enabled on the destination computer if it has been disabled. The procedures in this section describe how to disable remote management, and how to re-enable remote management if it has been disabled. In the Server Manager console, the remote management status for the local server is displayed in the Properties area of the Local Server page.

Local administrator accounts other than the built-in Administrator account may not have rights to manage a server remotely, even if remote management is enabled. The remote User Account Control (UAC) LocalAccountTokenFilterPolicy registry setting must be configured to allow local accounts of the Administrators group other than the built-in administrator account to remotely manage the server.

In Windows Server 2016, Server Manager relies on Windows remote Management (WinRM) and the Distributed component Object model (DCOM) for remote communications. The settings that are controlled by the Configure remote Management dialog box only affect parts of Server Manager and Windows PowerShell that use WinRM for remote communications. They do not affect parts of Server Manager that use DCOM for remote communications. For example, Server Manager uses WinRM to communicate with remote servers that are running Windows Server 2016, Windows Server 2012 R2, or Windows Server 2012, but uses DCOM to communicate with servers that are running Windows Server 2008 and Windows Server 2008 R2, but do not have the Windows Management Framework 4.0 or Windows Management Framework 3.0 updates applied. Microsoft Management Console (mmc) and other legacy management tools use DCOM. For more information about how to change these settings, see To configure mmc or other tool remote management over DCOM in this topic.

Procedures in this section can be completed only on computers that are running Windows Server. You cannot enable or disable remote management on a computer that is running Windows 10 by using these procedures, because the client operating system cannot be managed by using Server Manager.

To enable WinRM remote management, select one of the following procedures.

Настройка брандмауэра Windows для удаленной отладки Configure Windows Firewall for remote debugging

В сети, защищенной брандмауэром Windows, необходимо настроить брандмауэр для разрешения удаленной отладки. On a network protected by Windows Firewall, the firewall must be configured to permit remote debugging. Visual Studio и средства удаленной отладки пытаются открыть правильные порты брандмауэра во время установки или запуска, но также может потребоваться открыть порты или разрешить отладку приложений вручную. Visual Studio and the remote debugging tools try to open the correct firewall ports during installation or startup, but you may also need to open ports or allow apps manually.

В этой статье описывается настройка брандмауэра Windows для включения удаленной отладки на компьютерах с Windows 10, 8/8.1 и 7, а также на компьютерах с Windows Server 2012 R2, 2012 и 2008 R2. This topic describes how to configure the Windows firewall to enable remote debugging on Windows 10, 8/8.1, and 7; and Windows Server 2012 R2, 2012, and 2008 R2 computers. Компьютер с Visual Studio и удаленный компьютер не должны работать под управлением разных операционных систем. The Visual Studio and remote computer don’t have to be running the same operating system. Например, на компьютере с Visual Studio может использоваться Windows 10, а на удаленном компьютере — Windows Server 2012 R2. For example, the Visual Studio computer can run Windows 10, and the remote computer can run Windows Server 2012 R2.

Инструкции по настройке брандмауэра Windows немного различаются в зависимости от операционной системы. Кроме того, они другие в прежних версиях Windows. The instructions for configuring the Windows firewall differ slightly on different operating systems, and for older versions of Windows. В параметрах Windows 8/8.1, Windows 10 и Windows Server 2012 используется слово приложение, тогда как в Windows 7 и Windows Server 2008 используется слово программа. Windows 8/8.1, Windows 10, and Windows Server 2012 settings use the word app, while Windows 7 and Windows Server 2008 use the word program.

Настройка портов для удаленной отладки Configure ports for remote debugging

Visual Studio и удаленный отладчик пытаются открыть правильные порты во время установки или запуска. Visual Studio and the remote debugger try to open the correct ports during installation or startup. Однако в некоторых сценариях, таких использование стороннего брандмауэра, может потребоваться открыть порты вручную. However, in some scenarios, such as a third-party firewall, you may need to open ports manually.

Открытие порта To open a port:

В меню Windows Пуск найдите и откройте Брандмауэр Windows в режиме повышенной безопасности. In Windows Start menu, search for and open Windows Firewall with Advanced Security. В Windows 10 это Брандмауэр Защитника Windows с повышенной безопасностью. In Windows 10, this is Windows Defender Firewall with Advanced Security.

Для нового входящего порта выберите Правила для входящего трафика, затем Новое правило. For a new incoming port, select Inbound Rules and then select New Rule. Для правила для исходящего трафика выберите Правила для исходящего трафика. For an outgoing rule, select Outbound Rules instead.

В окне мастера создания правил для входящего трафика выберите Порт, а затем нажмите кнопку Далее. In the New Inbound Rule Wizard, select Port, and then select Next.

Выберите TCP или UDP в зависимости от номера порта из следующих таблиц. Select either TCP or UDP, depending on the port number from the following tables.

В разделе Определенные локальные порты введите номер порта из следующих таблиц, а затем нажмите кнопку Далее. Under Specific local ports, enter a port number from the following tables, and select Next.

Нажмите кнопку Проверить соединение, а затем Далее. Select Allow the Connection, and then select Next.

Выберите один тип сети или несколько для включения, в том числе тип сети для удаленного подключения, а затем нажмите кнопку Далее. Select one or more network types to enable, including the network type for the remote connection, and then select Next.

Присвойте правилу имя (например, msvsmon, IIS или Веб-развертывание), а затем нажмите кнопку Готово. Add a name for the rule (for example, msvsmon, IIS, or Web Deploy), and then select Finish.

Новое правило должно появиться и быть выбранным в списке Правила для входящего трафика или Правила для исходящего трафика. The new rule should appear and be selected in the Inbound Rules or Outbound Rules list.

Чтобы открыть порт с помощью PowerShell, выполните следующие действия: To open a port using PowerShell:

Для Брандмауэра Windows можно использовать команды PowerShell, например New-NetFirewallRule. For Windows Firewall, you can use PowerShell commands such as New-NetFirewallRule.

В следующем примере порт 4024 открывается для удаленного отладчика на удаленном компьютере. The following example opens port 4024 for the remote debugger on the remote computer. Путь, который необходимо использовать, может отличаться. The path you need to use may be different.

Порты на удаленном компьютере, обеспечивающие удаленную отладку Ports on the remote computer that enable remote debugging

Для удаленной отладки на удаленном компьютере должны быть открыты следующие порты. For remote debugging, the following ports must be open on the remote computer:

Порты Ports Входящий или исходящий Incoming/Outgoing Протокол Protocol Описание Description
4022 4022 Входящий Incoming TCP TCP Для Visual Studio 2017. For VS 2017. Номер порта увеличивается на 2 с каждой версией Visual Studio. The port number increments by 2 for each Visual Studio version. Более подробную информацию см. в разделе Назначение портов удаленного отладчика Visual Studio. For more information, see Visual Studio remote debugger port assignments.
4023 4023 Входящий Incoming TCP TCP Для Visual Studio 2017. For VS 2017. Номер порта увеличивается на 2 с каждой версией Visual Studio. The port number increments by 2 for each Visual Studio version. Этот порт используется только для удаленной отладки 32-разрядного процесса из 64-разрядной версии удаленного отладчика. This port is only used to remote debug a 32-bit process from a 64-bit version of the remote debugger. Более подробную информацию см. в разделе Назначение портов удаленного отладчика Visual Studio. For more information, see Visual Studio remote debugger port assignments.
3702 3702 Исходящий Outgoing UDP UDP (Необязательно.) Требуется для обнаружения удаленного отладчика. (Optional) Required for remote debugger discovery.
Порты Ports Входящий или исходящий Incoming/Outgoing Протокол Protocol Описание Description
4024 4024 Входящий Incoming TCP TCP Для Visual Studio 2019. For VS 2019. Номер порта увеличивается на 2 с каждой версией Visual Studio. The port number increments by 2 for each Visual Studio version. Более подробную информацию см. в разделе Назначение портов удаленного отладчика Visual Studio. For more information, see Visual Studio remote debugger port assignments.
4025 4025 Входящий Incoming TCP TCP Для Visual Studio 2019. For VS 2019. Номер порта увеличивается на 2 с каждой версией Visual Studio. The port number increments by 2 for each Visual Studio version. Этот порт используется только для удаленной отладки 32-разрядного процесса из 64-разрядной версии удаленного отладчика. This port is only used to remote debug a 32-bit process from a 64-bit version of the remote debugger. Более подробную информацию см. в разделе Назначение портов удаленного отладчика Visual Studio. For more information, see Visual Studio remote debugger port assignments.
3702 3702 Исходящий Outgoing UDP UDP (Необязательно.) Требуется для обнаружения удаленного отладчика. (Optional) Required for remote debugger discovery.

Если выбрать параметр Использовать режим совместимости управляемого кода в разделе Сервис > Параметры > Отладка, следует открыть эти дополнительные порты удаленного отладчика. If you select Use Managed Compatibility Mode under Tools > Options > Debugging, open these additional remote debugger ports. Режим совместимости управляемого кода позволяет использовать устаревшую версию отладчика Visual Studio 2010. Debugger Managed Compatibility Mode enables a legacy, Visual Studio 2010 version of the debugger.

Порты Ports Входящий или исходящий Incoming/Outgoing Протокол Protocol Описание Description
135, 139, 445 135, 139, 445 Исходящий Outgoing TCP TCP Обязательный. Required.
137, 138 137, 138 Исходящий Outgoing UDP UDP Обязательный. Required.

Если, согласно политике домена, обмен данными по сети должен выполняться по протоколу IPSec, необходимо открыть дополнительные порты как на компьютере с Visual Studio, так и на удаленном компьютере. If your domain policy requires network communication to be performed through IPSec, you must open additional ports on both the Visual Studio and remote computers. Для отладки на удаленном веб-сервере IIS откройте порт 80 на удаленном компьютере. To debug on a remote IIS web server, open port 80 on the remote computer.

Порты Ports Входящий или исходящий Incoming/Outgoing Протокол Protocol Описание Description
500, 4500 500, 4500 Исходящий Outgoing UDP UDP Требуется, если в соответствии с политикой домена обмен данными по сети должен осуществляться по протоколу IPSec. Required if your domain policy requires network communication to be performed through IPSec.
80 80 Исходящий Outgoing TCP TCP Требуется для отладки веб-сервера. Required for web server debugging.

Сведения о разрешении взаимодействия с конкретными приложениями через брандмауэр Windows см. в разделе Настройка удаленной отладки через брандмауэр Windows. To allow specific apps through the Windows firewall, see Configure remote debugging through Windows Firewall.

Настройка удаленной отладки через брандмауэр Windows Configure remote debugging through Windows firewall

Можно установить средства удаленной отладки на удаленном компьютере или запустить их из общей папки. You can install the remote debugging tools on the remote computer, or run them from a shared folder. В любом случае необходимо правильно настроить брандмауэр удаленного компьютера. In either case, the remote computer firewall must be configured correctly.

На удаленном компьютере средства удаленной отладки находятся в следующей папке: On a remote computer, the remote debugging tools are in:

* \Common7\IDE\Remote Debugger\ * \Common7\IDE\Remote Debugger\

Разрешение и настройка удаленного отладчика через брандмауэр Windows Allow and configure the remote debugger through Windows Firewall

В меню Windows Пуск найдите и откройте Брандмауэр Windows или Брандмауэр Защитника Windows. In Windows Start menu, search for and open Windows Firewall, or Windows Defender Firewall.

Щелкните Разрешить взаимодействие с приложением через брандмауэр Windows. Select Allow an app through Windows Firewall.

Если удаленный отладчик или удаленный отладчик Visual Studio не отображаются в разделе Разрешенные приложения и компоненты, выберите Изменить параметры, а затем выберите Разрешить другое приложение. If Remote Debugger or Visual Studio Remote Debugger doesn’t appear under Allowed apps and features, select Change settings, and then select Allow another app.

Если приложение удаленного отладчика по-прежнему отсутствует в диалоговом окне Добавление приложения, нажмите кнопку Обзор и в зависимости от архитектуры приложения перейдите к папке * \Common7\IDE\Remote Debugger\ . If the remote debugger app still isn’t listed in the Add an app dialog, select Browse, and navigate to * \Common7\IDE\Remote Debugger\ , depending on the appropriate architecture for your app. Выберите msvsmon.exe, а затем нажмите кнопку Добавить. Select msvsmon.exe, and then select Add.

В списке Приложения выберите только что добавленный удаленный отладчик. In the Apps list, select the Remote Debugger that you just added. Выберите Типы сетей, затем выберите один тип сети или несколько для включения, в том числе тип сети для удаленного подключения. Select Network types, and then select one or more network types, including the network type for the remote connection.

Выберите Добавить, а затем нажмите кнопку ОК. Select Add, and then select OK.

Устранение неполадок подключения удаленной отладки Troubleshoot the remote debugging connection

Если вы не можете присоединиться к приложению с помощью удаленного отладчика, проверьте правильность всех портов брандмауэра, протоколов, типов сетей и параметров приложения для удаленной отладки. If you can’t attach to your app with the remote debugger, make sure the remote debugging firewall ports, protocols, network types, and app settings are all correct.

В меню Windows Пуск найдите и откройте Брандмауэр Windows, а затем выберите Разрешить взаимодействие с приложением через брандмауэр Windows. In the Windows Start menu, search for and open Windows Firewall, and select Allow an app through Windows Firewall. Убедитесь, что в списке Разрешенные приложения и компоненты отображается выбранный удаленный отладчик или удаленный отладчик Visual Studio и выбраны правильные типы сетей. Make sure Remote Debugger or Visual Studio Remote Debugger appears in the Allowed apps and features list with a selected check box, and the correct network types are selected. В противном случае добавьте необходимые приложения и параметры. If not, add the correct apps and settings.

В меню Windows Пуск найдите и откройте Брандмауэр Windows в режиме повышенной безопасности. In the Windows Start menu, search for and open Windows Firewall with Advanced Security. Убедитесь, что в разделе Правила для входящего трафика (и при необходимости в разделе Правила для исходящего трафика) отображается удаленный отладчик или удаленный отладчик Visual Studio с зеленым флажком, а все параметры заданы правильно. Make sure Remote Debugger or Visual Studio Remote Debugger appears under Inbound Rules (and optionally, Outbound Rules) with a green checkmark icon, and that all settings are correct.

  • Чтобы просмотреть или изменить параметры правила, щелкните правой кнопкой мыши приложение Удаленный отладчик в списке и выберите пункт Свойства. To view or change the rule settings, right-click the Remote Debugger app in the list and select Properties. Используйте вкладки Свойства, чтобы включить или отключить правило или изменить номера портов, протоколы или типы сетей. Use the Properties tabs to enable or disable the rule, or change port numbers, protocols, or network types.
  • Если приложение удаленного отладчика не отображается в списке правил, добавьте и настройте нужные порты. If the remote debugger app doesn’t appear in the rules list, add and configure the correct ports.
Читайте также:  Как вернуть удаленный калькулятор для windows 10
Оцените статью