net-mgmt/zabbix-proxy: add StartSNMPPollers option - #5644
Open
b-hoffen wants to merge 1 commit into
Open
Conversation
The parameter was not exposed in the GUI, so it could only be set by editing zabbix_proxy.conf by hand, which is overwritten whenever the template is regenerated. Monitoring many SNMP hosts commonly needs more than the default of one poller. The field is optional and omitted from the generated configuration when left empty, so existing setups are unaffected. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Important notices
Before you submit a pull request, we ask you kindly to acknowledge the following:
If AI was used, please disclose:
StartAgentPollersimplementation (net-mgmt/zabbix-proxy: Add StartAgentPollers and MaxConcurrentChecksPerPoller options to Zabix Proxy plugin #5037) and drafted the three changes to match its style, along with the commit message and this description. I defined the scope, reviewed the diff, and carried out all functional testing on OPNsense hardware.Describe the problem
StartSNMPPollersis not exposed in the Zabbix Proxy settings form, so it always stays at the Zabbix default of 1. The only way to change it is to edit/usr/local/etc/<variant>/zabbix_proxy.confby hand, and the plugin regenerates that file on every settings apply, silently discarding the change. Monitoring a larger number of SNMP hosts commonly needs more than one poller.Describe the proposed solution
Expose the parameter as an optional field, following the same pattern used for
StartAgentPollersin #5037:General.xml—startsnmppollersas anIntegerField, range 0-1000forms/general.xml— "Start SNMP Pollers", next to Start Agent Pollerszabbix_proxy.conf.in— guarded withhelpers.exists(...) and != ''Left empty the field emits nothing, so existing configurations are unaffected.
StartSNMPPollersrequires Zabbix >= 7.0 and this template is shared by the zabbix6/zabbix7/zabbix74 variants. This matches the existingStartAgentPollersandMaxConcurrentChecksPerPollerfields, and as the field is empty by default there is no change for zabbix6 users.Tested on os-zabbix74-proxy 1.17 with zabbix74-proxy 7.4.11:
StartSNMPPollersabsent from the generated config, verified with the element present but empty inconfig.xml, which is the state after any settings save1001and non-numeric input rejected by model validation5:StartSNMPPollers=5generated, proxy starts, fivesnmp pollerprocesses, no configuration warnings in the proxy logRelated issue
None. This is a small additive change mirroring the existing
StartAgentPollersfield, so I did not open an issue first — happy to do so if you would prefer.