Forum Discussion
Configure SNAT Pool custom SNMP MIB
Hello community,
I'm trying to monitor how many connections are in my SNAT pool to control that connection limits are not exceeded. My NMS is Zabbix.
In my scenario, I get "Current Connections" for each SNAT Pool using next snmp query:
snmpwalk -v2c -c public localhost F5-BIGIP-LOCAL-MIB::ltmSnatPoolStatServerCurConns
F5-BIGIP-LOCAL-MIB::ltmSnatPoolStatServerCurConns."/Common/SNAT_test" = Gauge32: 513
F5-BIGIP-LOCAL-MIB::ltmSnatPoolStatServerCurConns."/Common/SNAT_pub" = Gauge32: 21444
After this, I would like to trigger an alert (in Zabbix) when those Current Connections exceed 80% of the SNAT Pool capacity (to include a new IP in the pool in that case). We estimate the SNAT Pool capacity in 65k connections for each IP in the pool. A query with next structure would be perfect to set this trigger:
snmpwalk -v2c -c public localhost F5-BIGIP-LOCAL-MIB::XXXXXXXXXXXXXXXX
F5-BIGIP-LOCAL-MIB::XXXXXXXXXXXXXXXX."/Common/SNAT_test" = INTEGER: 2
F5-BIGIP-LOCAL-MIB::XXXXXXXXXXXXXXXX."/Common/SNAT_pub" = INTEGER: 7
(Note that the result should show how many IPs are configured in each pool).
I didn't find anything like this in MIB, so I decided to create a custom MIB, but just a few of structures are available (INT, STRING, GAUGE, and COUNTER), and Lists are not included. So I guess this is not possible using this way... 😞
Any idea to solve this? (create "custom_mib.tcl" dynamically with a crontab is not an option).
I have tried if lists of strings are permited using next code:
/config/snmp/custom_mib.tcl
register_mib ".2" testmib string
proc testmib {}
{
set result [split "Hello world" " "]
return $result
}
But after SNMP query, no string splitting was performed:
snmpwalk -v2c -c public localhost F5-BIGIP-COMMON-MIB::bigipTrafficMgmt.100.2
F5-BIGIP-COMMON-MIB::bigipTrafficMgmt.100.2.0 = STRING: "Hello World"
KR,
Dario.
I've already found a way to commit this issue. I share this info to help someone in the same situation.
This problemas about SNAT Pool exhaustion was solved in v12. Now you can configure a threshold previous to port exhaustion which creates an entry in the log. Using Alertd you can configure a custom trap alert.
Exhaustion SNAT Pool - > https://support.f5.com/csp/article/K63275550
Custom Alerts -> https://support.f5.com/csp/article/K3727
Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com