Page 1 of 1

SNMP trap definition

Posted: Mon Mar 09, 2026 2:16 pm
by davemulv1
If I go to Edit Trap Definition in order to modify the severity, I check the box for "Enable Passive Service Setup" and use the Severity pulldown to change it to say "Warning". I save it, and it restarts SNMPTT service and seems to work logging said trap as a Warning. But if I go back in to look at the definition it has reset to Severity = "Parse Severity Level ($s)". Shouldn't the setting "stick" in the GUI?
Screenshot 2026-03-09 151819.png
Thanks,

Dave

Re: SNMP trap definition

Posted: Tue Mar 10, 2026 3:17 am
by Dan682Lee
Dave, what you’re seeing is actually expected behavior with SNMPTT’s trap definition handling. The GUI lets you override severity temporarily, but when you go back in, the definition reverts to “Parse Severity Level ($s)” because SNMPTT is designed to parse severity directly from the incoming trap variable unless you hard‑code it in the configuration file.
Here’s what’s happening under the hood:
- Enable Passive Service Setup allows you to map traps to Nagios service states.
- When you select “Warning” in the GUI, SNMPTT applies that override and restarts the service, so the trap logs correctly as a Warning.
- However, the GUI is reading the definition file again when you reopen it, and since the file still has $s (parse severity), it shows that instead of your override.
So yes, the override “works” at runtime, but it doesn’t persist in the definition unless you manually edit the SNMPTT configuration file (or the template that generates it) to replace $s with a fixed severity value. The GUI doesn’t currently write that change back into the definition—it’s more of a runtime mapping tool.
If you want the setting to stick permanently:
- Edit the trap definition file directly (usually snmptt.conf or a generated include file).
- Replace Parse Severity Level ($s) with Warning.
- Restart SNMPTT.
That way, when you reopen the GUI, it will show “Warning” consistently.
Would you like me to walk you through the exact config file lines to change so the GUI reflects your chosen severity, rather than just applying it temporarily?

Re: SNMP trap definition

Posted: Tue Mar 10, 2026 4:52 am
by rolandewing
It sounds like the GUI change is only applied temporarily when the service restarts, but the original configuration may still be defined in the SNMPTT trap configuration file. If the trap definition in the config uses “Parse Severity Level ($s)”, the GUI might revert to that value after reloading. You may want to check whether the trap configuration file is overriding the setting or if the change needs to be saved there as well.