boche.net – VMware vEvangelist 06月11日 22:50
Site Recovery Manager Firewall Rules for Windows Server
index_new5.html
../../../zaker_core/zaker_tpl_static/wap/tpl_guoji1.html

 

本文探讨了VMware Site Recovery Manager (SRM) 在Windows Server 2019上安装时遇到的一个关键问题:防火墙规则缺失导致SRM插件无法在vSphere Client中显示。尽管VMware逐渐减少了对Microsoft Windows和SQL Server的支持,转向基于Photon OS的设备,但在某些情况下,用户仍可能需要在Windows Server 2019上部署SRM。文章详细分析了问题的原因,并提供了通过PowerShell脚本手动添加防火墙规则的解决方案,以确保SRM功能的正常运行。

🌐 VMware已逐步减少对Microsoft Windows和SQL Server的支持,倾向于基于Photon OS的设备,但部分用户仍需在Windows Server 2019上部署SRM。

🔥 在Windows Server 2019上安装SRM时,安装程序不会自动创建必要的防火墙规则,导致SRM插件在vSphere Client中不可见。

💡 文章提供了手动创建防火墙规则的解决方案,包括通过Windows Firewall UI、Group Policy Object (GPO) 或脚本(如PowerShell),以解决SRM插件无法显示的问题。

🔑 作者提供了PowerShell脚本示例,用于添加四个关键的入站防火墙规则,这些规则允许SRM相关流量通过,从而确保SRM功能的正常运行。

I have a hunch Google sent you here. Before we get to what you’re looking for, I’m going to digress a little. tl;dr folks feel free to jump straight to the frown emoji below for what you’re looking for.

Since the Industrial Revolution, VMware has supported Microsoft Windows and SQL Server platforms to back datacenter and cloud infrastructure products such as vCenter Server, Site Recovery Manager, vCloud Director (rebranded recently to VMware Cloud Director), and so on. However, if you’ve been paying attention to product documentation and compatibility guides, you will have noticed support for Microsoft platforms diminishing in favor of easy to deploy appliances based on Photon OS and VMware Postgres (vPostgres). This is a good thing – spoken by a salty IT veteran with a strong Windows background.

2019 is where we really hit a brick wall. vCenter Server 6.7 is the last version that supports installation on Windows and that ended on Windows Server 2016 – there was never support for Windows Server 2019 (reference VMware KB 2091273 – Supported host operating systems for VMware vCenter Server installation). In vSphere 7.0, vCenter Server for Windows has been removed and support is not available. For more information, see Farewell, vCenter Server for Windows. Likewise, Microsoft SQL Server 2016 was the last version to support vCenter Server (matrix reference).

Site Recovery Manager (SRM) is in the same boat. It was born and bred on Winodws and SQL Server back ends. But once again we find a Photon OS-based appliance with embedded vPostres available along with product documentation which highlights diminishing support for Microsoft Windows and SQL.

Taking a closer look at the documentation…

Compatibility Matrices for VMware Site Recovery Manager 8.2

Compatibility Matrices for VMware Site Recovery Manager 8.3

Ignoring the labyrinth of supported product and platform compatibility matrices above, one may choose to forge ahead and install SRM on Windows Server 2019 anyway. I’ve done it several times in the lab but there was a noted takeaway.

When I logged into the vSphere Client, the SRM plug-in was not visible. In my travels, there’s a few reasons why this symptom can occur.

Wait, what? The Windows Firewall wasn’t typically a problem in the past. That is correct. The SRM installation does create four inbound Windows Firewall rules (none outbound) on Windows Server up through 2016. However, for whatever reason, the SRM installation does not create these needed firewall rules on Windows Server 2019. The lack of firewall rules allowing SRM related traffic will block the plug-in. Reference Network Ports for Site Recovery Manager.

One obvious workaround here would be to disable the Windows Firewall but what fun would that be? Also this may violate IT security plans, trigger an audit, require exception filings. Been there, done that, ish. Let’s dig a little deeper.

The four inbound Windows Firewall rules ultimately wind up in the Windows registry. A registry export of the four rules actually created by an SRM installation is shown below. Through trial and error I’ve found that importing the rules into the Windows registry with a .reg file results in broken rules so for now I would not recommend that method.

Windows Registry Editor Version 5.00[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\FirewallRules]"{B37EDE84-6AC1-4F7D-9E42-FA44B8D928D0}"="v2.26|Action=Allow|Active=TRUE|Dir=In|App=C:\\Program Files\\VMware\\VMware vCenter Site Recovery Manager\\bin\\vmware-dr.exe|Name=VMware vCenter Site Recovery Manager|Desc=This feature allows connections using VMware vCenter Site Recovery Manager.|""{F6EAE3B7-C58F-4582-816B-C3610411215B}"="v2.26|Action=Allow|Active=TRUE|Dir=In|Protocol=6|LPort=9086|Name=VMware vCenter Site Recovery Manager - HTTPS Listener Port|""{F6E7BE93-C469-4CE6-80C4-7069626636B0}"="v2.26|Action=Allow|Active=TRUE|Dir=In|App=C:\\Program Files\\VMware\\VMware vCenter Site Recovery Manager\\external\\commons-daemon\\prunsrv.exe|Name=VMware vCenter Site Recovery Manager Client|Desc=This feature allows connections using VMware vCenter Site Recovery Manager Client.|""{66BF278D-5EF4-4E5F-BD9E-58E88719FA8E}"="v2.26|Action=Allow|Active=TRUE|Dir=In|Protocol=6|LPort=443|Name=VMware vCenter Site Recovery Manager Client - HTTPS Listener Port|"

The four rules needed can be created by hand in the Windows Firewall UI, configured centrally via Group Policy Object (GPO), or scripted with netsh or PowerShell. I’ve chosen PowerShell and created the script below for the purpose of adding the rules. Pay close attention in that two of these rules are application path specific. Change the drive letter and path to the applications as necessary or the two rules won’t work properly.

# Run this PowerShell script directly on a Windows based VMware Site# Recovery Manager server to add four inbound Windows firewall rules# needed for SRM functionality.# Jason Boche# http://boche.net# 4/29/20New-NetFirewallRule -DisplayName "VMware vCenter Site Recovery Manager" -Description "This feature allows connections using VMware vCenter Site Recovery Manager." -Direction Inbound -Program "C:\Program Files\VMware\VMware vCenter Site Recovery Manager\bin\vmware-dr.exe" -Action AllowNew-NetFirewallRule -DisplayName "VMware vCenter Site Recovery Manager - HTTPS Listener Port" -Direction Inbound -LocalPort 9086 -Protocol TCP -Action AllowNew-NetFirewallRule -DisplayName "VMware vCenter Site Recovery Manager Client" -Description "This feature allows connections using VMware vCenter Site Recovery Manager Client." -Direction Inbound -Program "C:\Program Files\VMware\VMware vCenter Site Recovery Manager\external\commons-daemon\prunsrv.exe" -Action AllowNew-NetFirewallRule -DisplayName "VMware vCenter Site Recovery Manager Client - HTTPS Listener Port" -Direction Inbound -LocalPort 443 -Protocol TCP -Action Allow

Test execution was a success.

PS S:\PowerShell scripts> .\srmaddwindowsfirewallrules.ps1Name                  : {10ba5bb3-6503-44f8-aad3-2f0253c980a6}DisplayName           : VMware vCenter Site Recovery ManagerDescription           : This feature allows connections using VMware vCenter Site Recovery Manager.DisplayGroup          :Group                 :Enabled               : TrueProfile               : AnyPlatform              : {}Direction             : InboundAction                : AllowEdgeTraversalPolicy   : BlockLooseSourceMapping    : FalseLocalOnlyMapping      : FalseOwner                 :PrimaryStatus         : OKStatus                : The rule was parsed successfully from the store. (65536)EnforcementStatus     : NotApplicablePolicyStoreSource     : PersistentStorePolicyStoreSourceType : LocalName                  : {ea88dee8-8c96-4218-a23d-8523e114d2a9}DisplayName           : VMware vCenter Site Recovery Manager - HTTPS Listener PortDescription           :DisplayGroup          :Group                 :Enabled               : TrueProfile               : AnyPlatform              : {}Direction             : InboundAction                : AllowEdgeTraversalPolicy   : BlockLooseSourceMapping    : FalseLocalOnlyMapping      : FalseOwner                 :PrimaryStatus         : OKStatus                : The rule was parsed successfully from the store. (65536)EnforcementStatus     : NotApplicablePolicyStoreSource     : PersistentStorePolicyStoreSourceType : LocalName                  : {a707a4b8-b0fd-4138-9ffa-2117c51e8ed4}DisplayName           : VMware vCenter Site Recovery Manager ClientDescription           : This feature allows connections using VMware vCenter Site Recovery Manager Client.DisplayGroup          :Group                 :Enabled               : TrueProfile               : AnyPlatform              : {}Direction             : InboundAction                : AllowEdgeTraversalPolicy   : BlockLooseSourceMapping    : FalseLocalOnlyMapping      : FalseOwner                 :PrimaryStatus         : OKStatus                : The rule was parsed successfully from the store. (65536)EnforcementStatus     : NotApplicablePolicyStoreSource     : PersistentStorePolicyStoreSourceType : LocalName                  : {346ece5b-01a9-4a82-9598-9dfab8cbfcda}DisplayName           : VMware vCenter Site Recovery Manager Client - HTTPS Listener PortDescription           :DisplayGroup          :Group                 :Enabled               : TrueProfile               : AnyPlatform              : {}Direction             : InboundAction                : AllowEdgeTraversalPolicy   : BlockLooseSourceMapping    : FalseLocalOnlyMapping      : FalseOwner                 :PrimaryStatus         : OKStatus                : The rule was parsed successfully from the store. (65536)EnforcementStatus     : NotApplicablePolicyStoreSource     : PersistentStorePolicyStoreSourceType : LocalPS S:\PowerShell scripts>

After logging out of the vSphere Client and logging back in, the Site Recovery plug-in loads and is available.

Feel free to use this script but be advised, as with anything from this site, it comes without warranty. Practice due diligence. Test in a lab first. Etc.

With virtual appliance being fairly mainstream at this point, this article probably won’t age well but someone may end up here. Maybe me. It has happened before.

Fish AI Reader

Fish AI Reader

AI辅助创作,多种专业模板,深度分析,高质量内容生成。从观点提取到深度思考,FishAI为您提供全方位的创作支持。新版本引入自定义参数,让您的创作更加个性化和精准。

FishAI

FishAI

鱼阅,AI 时代的下一个智能信息助手,助你摆脱信息焦虑

联系邮箱 441953276@qq.com

相关标签

VMware SRM Windows Server 2019 防火墙 PowerShell
相关文章