Blame README.systemd

Packit Service b38f0b
README.systemd
Packit Service b38f0b
--------------
Packit Service b38f0b
Net-SNMP provides two daemons, which support systemd system manager. 
Packit Service b38f0b
See http://www.freedesktop.org/wiki/Software/systemd to learn how
Packit Service b38f0b
systemd works. Both socket activation and notification is supported by these
Packit Service b38f0b
daemons.
Packit Service b38f0b
Packit Service b38f0b
To enable systemd support, the sources must be compiled with
Packit Service b38f0b
--with-systemd configure option.
Packit Service b38f0b
Packit Service b38f0b
snmpd - The SNMP agent
Packit Service b38f0b
----------------------
Packit Service b38f0b
Socket activation od snmpd daemon is implemented, but it's discouraged.
Packit Service b38f0b
The reason is simple - snmpd not only listens and processes SNMP requests
Packit Service b38f0b
from network, but also gathers system statistics counters, sends traps and
Packit Service b38f0b
communicates with subagents. It even opens few netlink sockets.
Packit Service b38f0b
Packit Service b38f0b
In other words, snmpd should run from system start to properly work.
Packit Service b38f0b
This can be done in two ways:
Packit Service b38f0b
1) either as snmpd service unit with 'Type=notification' and without a socket
Packit Service b38f0b
   unit
Packit Service b38f0b
2) or as snmpd service unit with 'Type=simple', appropriate socket socket unit
Packit Service b38f0b
   and the snmpd service enabled. This way systemd creates the snmpd listening
Packit Service b38f0b
   socket early during boot and passes the sockets to snmpd slightly later
Packit Service b38f0b
   (but still during machine boot). This way systemd can paralelize start of
Packit Service b38f0b
   services, which depend on snmpd. Admins must adjust the socket file manually,
Packit Service b38f0b
   depending if the snmpd support AgentX, IPv6, SMUX etc.
Packit Service b38f0b
Packit Service b38f0b
snmpd should be started with '-f' command line parameter to disable forking -
Packit Service b38f0b
systemd does that for us automatically.
Packit Service b38f0b
Packit Service b38f0b
Packit Service b38f0b
snmptrapd - The trap processing daemon
Packit Service b38f0b
--------------------------------------
Packit Service b38f0b
snmptrapd supports full socket activation and also notification (if needed).
Packit Service b38f0b
Both 'Type=simple' (with appropriate socket unit) and 'Type=notify' services
Packit Service b38f0b
will work. Again, '-f' parameter should be provided on snmptrapd command line.
Packit Service b38f0b
Packit Service b38f0b
If integration with SNMP agent using AgentX protocol is enabled, snmptrapd should
Packit Service b38f0b
start during boot and not after first SNMP trap arrives. Same rules as for snmpd
Packit Service b38f0b
applies then.