WMI: How can I fix the port?
9,453
The following procedure is an automated setup to allow WMI to have a fixed port. The procedure uses the winmgmt command-line tool. To set up a fixed port for WMI
- At the command prompt, type winmgmt -standalonehost
- Stop the WMI service by typing the command net stop "Windows Management Instrumentation"
- Restart the WMI service again in a new service host by typing net start "Windows Management Instrumentation"
- Establish a new port number for the WMI service by typing netsh firewall add portopening TCP 24158 WMIFixedPor
Author by
YoyoMan
Updated on September 18, 2022Comments
-
YoyoMan almost 2 years
I need to use WMI for getting some information from my servers. But I have a server in DMZ, so I need to open a port in my firewall. I've searching and I found that WMI uses random port. How can this be fixed?
-
Volodymyr Molodets over 11 yearsWhat OS is installed on a DMZ server?
-
YoyoMan over 11 yearsHi, it's Windows server 2003, 2008 and Seven.
-
-
YoyoMan over 11 yearsshikran, I've already test this manipulation but it doesn't change anything. For information, I use Splunk for getting log files.
-
Volodymyr Molodets over 11 yearsFixed port cannot be set on a Windows Server 2003 machine. This option appeared starting from Windows Vista. "...Starting with Windows Vista, you can set up the WMI service to run as the only process in a separate host and specify a fixed port." Source: msdn.microsoft.com/en-us/library/windows/desktop/…
-
YoyoMan over 11 yearsHi, I don't have a local firewall on the PCs but a network firewall, so it's why I need fixe a WMI port for open it.
-
Volodymyr Molodets over 11 yearsYou'd better mention this next time in your question. In such situation, you can only setup fixed port on a Windows Server 2008 and Windows 7 machines, but not W2K3 server. Follow this link: msdn.microsoft.com/en-us/library/windows/desktop/…
-
YoyoMan over 11 yearsSorry for that. I've already did this manipulation, but my Splunk Server use always random port for WMI.