Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I downloaded the file from sourceforge and unzipped it with 7-zip. When I open the folder there is no "install.exe" or anything like that. Believe it or not there are no tutorials on this that I can find online. I went into the win32 folder and ran but it gave me this message

Please run VCVARS32.BAT first to set up the Visual Studio build environment.

There is no file called vcvars32.bat, all I have is the Visual Studio 2005 Remote Debugger. I opened up a command prompt and ran install-net-snmp.bat in the win32 folder and it seemed to be successful but it doesn't show in my installed programs in Control Panel.

Basically my question is... How do I get net-snmp up and running on Windows 7?


EDIT: The reason I want to use Net-SNMP is because I need to use SNMPv3 and the Windows agent doesn't support it.

share|improve this question
up vote 4 down vote accepted

Sounds like you downloaded the source code, but what you really want is the Win32 binaries.

Version 5.5 is the last version that has Windows x86 and x64 binaries precompiled by the project developers.

But even if you install the 5.5 binaries on Windows, I do not think it shows up in the control panel or start menu. It's not going to have a window you can open and click things in.

share|improve this answer
There should be instructions for starting snmpd as a service so that it can be stopped and started from the Services control panel. The configuration is done by editing snmpd.conf and restarting the service. – mtinberg Jun 24 '11 at 22:35
I actually went to /usr/bin and ran 'registeragent' with cmd to get the service started. Thank you for your responses. – Steve Jun 27 '11 at 15:46
It does show up in the control panel by the way. – Steve Jun 28 '11 at 13:58
Thanks Bill, I was able to download the x86 version that worked on my windows XP SP3 anyone know any good tutorials for getting started with net-snmp – user90500 Aug 4 '11 at 14:29

Yeah, I really don't know why Net-SNMP doesn't distribute prebuilt binaries with their code. It's bizarre.

Anyways, I recently built 5.7.3 for Windows 64-bit (with full support for SSL, IPv6, and SNMP extension DLLs). You can download the binaries here:

Because I compiled this with Visual Studio 2015, you will also have to install the Visual C++ Redistributable for Visual Studio 2015 from here:

Unzip the archive to C:\Program Files\Net-SNMP. You should be able to run the bin\snmpd.exe file to launch the agent. Edit etc\snmp\snmpd.conf (or run bin\snmpconf) to configure the agent. You can run:

snmpd.exe -register <add arguments to snmp.exe here>

to install the agent as a Windows service. Remember to add an exception to your Windows firewall for the snmpd.exe executable. And that's how you install Net-SNMP for Windows x64.

I'll also provide you with the exact steps I used to compile the binaries, so at least this can be documented concisely somewhere on the Internet. The official documentation for how to do this is incredibly lengthy, erroneous, and outdated.

Prerequisites: Active Perl x64, Visual Studio Community Edition (I used 2015). Note that the version of Visual Studio you use will effect the paths used below in the compilation instructions, so modify the path below accordingly if you're using something other than the 2015 edition.

First, compile OpenSSL for Windows x64. Unzip the source code, and in the same directory:

call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" x64
perl Configure VC-WIN64A --prefix=C:\OpenSSL-Win64
nmake -f ms\nt.mak
nmake -f ms\nt.mak install
move C:\OpenSSL-Win64\lib\libeay32.lib C:\OpenSSL-Win64\lib\libeay32MD.lib

That last step renames the OpenSSL static library to something that Net-SNMP expects.

Now, compile Net-SNMP. Unzip the source code, and in the win32 directory:

call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" x64
set Platform=x64
set TARGET_CPU=x64
set INCLUDE=%INCLUDE%;C:\OpenSSL-Win64\include
set LIB=%LIB%;C:\OpenSSL-Win64\lib
perl Configure --with-sdk --with-winextdll --with-ssl --with-ipv6 --config=release --linktype=static --prefix="c:/Program Files/Net-SNMP"
manual step: edit net-snmp\net-snmp-config.h, comment out #define snprintf (this is fixed in their git repository)
nmake clean
nmake install

One you've installed Net-SNMP, you can uninstall and delete everything else just fine (Active Perl, Visual Studio, OpenSSL, etc.) and Net-SNMP will still work. Obviously make sure you keep the VC++ redistributable installed.

I hope this helps somebody out there.

share|improve this answer

Found this link on wiki -

to build in windows you need several non-native tools it appears. You could give this a try.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.