New Plugin notify_snmp: send notifications as snmp traps.

With this plugin you can send notifications as snmp traps and you have the freedom to choose the oids of the trap.
It's useful to send the notifications to other systems, for example to aggregate alerts of multiple monitoring systems.

An example of the configuration is:

    LoadPlugin notify_snmp
    <Plugin notify_snmp>
      <OIDs collectd>
        EnterpriseOID    "SNMPv2-SMI::experimental.100"
        TrapOID           "SNMPv2-SMI::experimental.100.2"
        SeverityOID       "SNMPv2-SMI::experimental.100.1.1"
        HostOID           "SNMPv2-SMI::experimental.100.1.2"
        PluginOID         "SNMPv2-SMI::experimental.100.1.3"
        PluginInstanceOID "SNMPv2-SMI::experimental.100.1.4"
        TypeOID           "SNMPv2-SMI::experimental.100.1.5"
        TypeInstanceOID   "SNMPv2-SMI::experimental.100.1.6"
        DataSourceOID     "SNMPv2-SMI::experimental.100.1.7"
        ValueOID          "SNMPv2-SMI::experimental.100.1.8"
        MessageOID        "SNMPv2-SMI::experimental.100.1.9"
        TimeStampOID      "SNMPv2-SMI::experimental.100.1.10"
      </OIDs>
      <Target snmphost>
        Address "192.168.1.100:162"
        Version 2
        Community "public"
        OIDs collectd
      </Target>
    </Plugin>

or as simple as:

    LoadPlugin notify_snmp
    <Plugin notify_snmp>
      <Target snmphost>
        Address "192.168.1.100:162"
        Version 2
        Community "public"
      </Target>
    </Plugin>

if you use the default values defined for oids:

    static struct {
        notify_snmp_enum_oids_t id;
        char *string;
    } notify_snmp_default_oids[] = {
        { NOTIFY_SNMP_ENTERPRISE_OID,     "SNMPv2-SMI::experimental.100" },
        { NOTIFY_SNMP_TRAP_OID,           "SNMPv2-SMI::experimental.100.1" },
        { NOTIFY_SNMP_SEVERITY_OID,       "SNMPv2-SMI::experimental.100.2.1" },
        { NOTIFY_SNMP_TIMESTAMP_OID,      "SNMPv2-SMI::experimental.100.2.2" },
        { NOTIFY_SNMP_HOST_OID,           "SNMPv2-SMI::experimental.100.2.3" },
        { NOTIFY_SNMP_PLUGIN_OID,         "SNMPv2-SMI::experimental.100.2.4" },
        { NOTIFY_SNMP_PLUGIN_INSTANCE_OID,"SNMPv2-SMI::experimental.100.2.5" },
        { NOTIFY_SNMP_TYPE_OID,           "SNMPv2-SMI::experimental.100.2.6" },
        { NOTIFY_SNMP_TYPE_INSTANCE_OID,  "SNMPv2-SMI::experimental.100.2.7" },
        { NOTIFY_SNMP_DATA_SOURCE_OID,    "SNMPv2-SMI::experimental.100.2.8" },
        { NOTIFY_SNMP_VALUE_OID,          "SNMPv2-SMI::experimental.100.2.9" },
        { NOTIFY_SNMP_MESSAGE_OID,        "SNMPv2-SMI::experimental.100.2.10" },
        { NOTIFY_SNMP_NULL_OID,           NULL }
    };

The "SNMPv2-SMI::experimental.100" could be changed for other.

It would be interesting that collectd have a enterprise oid to use in the traps.

    http://pen.iana.org/pen/PenApplication.page
    http://www.iana.org/assignments/enterprise-numbers/enterprise-numbers

The entry in the man page may need a rewrite because my poor English.