Net-SNMP example subagent
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
LICENSES
.gitignore
CMakeLists.txt
LICENSE
NET-SNMP-TUTORIAL-MIB.txt
NET-SNMP-TUTORIAL-MIB.txt.license
README.md
nstMIBObjects.c
nstMIBObjects.h
ve_build.h.in
ve_data.c
ve_data.h
ve_main.c

README.md

Vigilant Enigma

standard-readme compliant reuse compliant

Net-SNMP example subagent

How to write an AgentX based extension to Net-SNMP in C with CMake as build system.

Background

It was hard to find any working examples which do not make extensive use of magic code generators, outdated wiki pages, complicated code not needed for a simple example, …

Install

There's no install. You have to compile the source by yourself. This mini project uses CMake for build. You can use all kinds of CMake GUIs, do what your preferred style is. A simple way to build on command line, starting in the source directory, would be:

mkdir -p build
cd build
cmake ..
make

Note: You can change the AgentX master socket to be connected to by changing the CMake variable VE_AGENTX_MASTER_SOCKET, there's no config file or command line argument for that. (Remember: this is just a simple example, that would not be focus of this project.)

Dependencies

You need Net-SNMP library headers. On Debian based systems you get those with the libsnmp-dev package.

Usage

There's nothing special about using this. Start the binary from your CMake build folder.

Contribute

PRs accepted.

License

This project is licensed under BSD Zero Clause License. The parts generated by mib2c and the NET-SNMP-TUTORIAL-MIB are subject to the Net-SNMP license.