Install and configure SNMP on Hyper-V Server Core

Hyper-V standalone, also known as Server Core is a GUI-less product you install on your bare metal and manage it through PowerShell or Hyper-V Manager. In this article, you will learn how to enable and configure SNMP on your Hyper-V server.

Hyper-V server is available through two channels. You can install it as a Windows Server role (GUI included), or as a standalone Hyper-V. Hyper-V standalone, also called Server core is a GUI-less product you install on your bare metal and manage it through PowerShell or Hyper-V Manager.

Hyper-V Server Core UI

In this article, I’ll show you how to enable SNMP on your Hyper-V server core using PowerShell and Server Manager. For demonstration purposes, I use Hyper-V 2019 Server core? I wrote an interesting article about changes in Windows Server 2022. You can read it here Is This Really the End of Hyper-V Server?

If you are using Windows Server that is Full GUI-based, please check the article Can you still monitor your Windows Server 2022 with SNMP.

Step 1: Install SNMP Service

You need to install the SNMP service using PowerShell.

If you are unsure if SNMP is already installed on your Windows Server Core, you can run the following command to verify it. The “Available” means that service is available, and “Installed” that is installed.

Get-WindowsFeature SNMP*
Check if SNMP is available and already installed

Run the following command to install SNMP Service and press Enter.

Install-WindowsFeature SNMP-Service
Install SNMP Service

You can verify the status of the SNMP service by typing the following command. As you can see SNMP Service is successfully installed.

Get-WindowsFeature SNMP*
Verify if SNMP is installed

If you also want to install SNMP WMI Provider, type the following command and press Enter.

Install-WindowsFeature SNMP-Service -IncludeAllSubFeature
Install SNMP WMI Provider

You have successfully installed SNMP Service. Now it is time for the configuration part.

Step 2: Configure SNMP Service

There are no PowerShell cmdlets for SNMP administration, hence you need to do create and edit a few registry keys. The registry key for configuring SNMP is located at

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SNMP\Parameters

However, we can make it easier. Instead of playing with PowerShell and registry keys, you can remotely access SNMP service from Server Manager or MMC (Microsoft Management Console).

  1. Connect to one of your Windows Servers.
  2. Open Server Manager and navigate to Tools > Services > Actions > Connect to another computer.
Services: Connect to another computer
  1. Type the FQDN of your Hyper-V server and click OK to connect to it. Once you are connected, you can remotely configure SNMP.
Connect to Hyper-V server
  1. Expand Services and navigate to SNMP Service and then Right click > Properties.
  2. Click on the Security tab to configure community string and ACL.
  3. Click on Add… under Community to create a community string. In my case, the community string is called prtgnetworkmonitor
  4. Select Accept SNMP packets from these hosts and click Add… to add the IP of your NMS (Network Monitoring Solution). In my case, the IP is 192.168.88.21 which is my PRTG Core Server. This means Windows machine will only accept SNMP communication coming and going to my NMS.
Remotely configure SNMP Service
  1. Click Apply and OK and you are done.
Monitoring Hyper-V Server Core using SNMP

Now you can monitor your Hyper-V Server Core using SNMP, or SNMP Traps (requires additional configuration). In my case below, I am monitoring several metrics (uptime, CPU load, RAM, HDD usage, network traffic, and DNS service) by using PRTG and SNMP.

I hope you enjoyed this article as I did. If you think this might interesting to your friends and network, please share it using the social media button below. Thank you.

Comments (2):

  1. Pavel

    December 7, 2021 at 14:06

    I didn’t know we can handle this using Server Manager. It is much easier than doing it using PowerShell or regedit.

    Reply
    • Jasmin Kahriman

      December 7, 2021 at 21:44

      Hi Pavel – I am glad to hear this was helpful for you.

      Reply

Leave a Reply

Your email address will not be published.

Share via
Copy link