Skip to content

zabbix: bring to parity between agent, server, and proxy; and do some cleanup#30010

Closed
danielfdickinson wants to merge 9 commits into
openwrt:masterfrom
danielfdickinson:pr-zabbix-bump-7-0-28
Closed

zabbix: bring to parity between agent, server, and proxy; and do some cleanup#30010
danielfdickinson wants to merge 9 commits into
openwrt:masterfrom
danielfdickinson:pr-zabbix-bump-7-0-28

Conversation

@danielfdickinson

@danielfdickinson danielfdickinson commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

📦 Package Details

Maintainer: @danielfdickinson

Description:

  • Update to latest LTS. See release notes: https://www.zabbix.com/rn/rn7.0.28
  • Use separate users for server and proxy. This is the upstream recommendation, and
    fits with our seperation of agent and server.
  • Tweak the agentd and server patch configuration and bring agentd and
    server confgurations to parity.
  • Tweak server initscript and bring agentd to parity
    • Genericize zabbix_server initscript.
    • Add shellcheck overrides where needed.
    • Add a 'never_root' config option (default true) that determines
      whether server starts as an unprivileged user or starts as root and
      drops to an unprivileged user (unless config is changed so it always
      runs as root).
    • Bring zabbix_agentd initscript to parity with zabbix_server for the
      initscript and configuration.
    • Tweak Makefile to reduce repetition
  • Bring proxy to parity with server and agentd
    • Add config file patch for proxy
    • Add initscript for proxy
    • Update Makefile and support files to bring proxy to parity with
      agentd and server.
  • Preserve user config files across sysupgrade
  • Move agentd openwrt-supplied params to separated dir
  • stop shipping sysctld conf in package
  • add php8-mod-simplexml dependency to frontend

🧪 Run Testing Details

  • OpenWrt Version: OpenWrt SNAPSHOT r35362-9e43544bc6
  • OpenWrt Target/Subtarget: bcm27xx/bcm2712
  • OpenWrt Device: Raspberry Pi 5 Model B Rev 1.0

✅ Formalities

  • I have reviewed the CONTRIBUTING.md file for detailed contributing guidelines.

If your PR contains a patch:

  • It can be applied using git am
  • It has been refreshed to avoid offsets, fuzzes, etc., using
    make package/<your-package>/refresh V=s
  • It is structured in a way that it is potentially upstreamable
    N/A: OpenWrt-specific configuration tweaks

@danielfdickinson danielfdickinson changed the title zabbix: bump verstion to 7.0.28 and add proxy zabbix: bump version to 7.0.28 and add proxy Jul 16, 2026
@danielfdickinson

Copy link
Copy Markdown
Contributor Author

Oh dear, I've confused the bot with the sed scripts.

Comment thread admin/zabbix/patches/010-change-agentd-config.patch
Update to latest LTS. See release notes:
https://www.zabbix.com/rn/rn7.0.28

Signed-off-by: Daniel F. Dickinson <dfdpublic@wildtechgarden.ca>
This is the upstream recommendation, and fits with our seperation
of agent and server.

Signed-off-by: Daniel F. Dickinson <dfdpublic@wildtechgarden.ca>
Tweak the agentd and server patch configuration and bring agentd and
server confgurations to parity.

Signed-off-by: Daniel F. Dickinson <dfdpublic@wildtechgarden.ca>

@openwrt-ai openwrt-ai left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed the sed-script conversion and proxy additions. Two functional issues flagged inline (both in the "replace conf file patches with sed scripts" commit); the commit messages themselves accurately describe their changes.


Generated by Claude Code

Comment thread admin/zabbix/Makefile Outdated
Comment thread admin/zabbix/files/zabbix_agentd.conf.sed Outdated
* Genericize zabbix_server initscript.
* Add shellcheck overrides where needed.
* Add a 'never_root' config option (default true) that determines
  whether server starts as an unprivileged user or starts as root and
  drops to an unprivileged user (unless config is changed so it always
  runs as root).
* Bring zabbix_agentd initscript to parity with zabbix_server for the
  initscript and configuration.
* Tweak Makefile to reduce repetition

Signed-off-by: Daniel F. Dickinson <dfdpublic@wildtechgarden.ca>
* Add config file patch for proxy
* Add initscript for proxy
* Update Makefile and support files to bring proxy to parity with
  agentd and server.

Signed-off-by: Daniel F. Dickinson <dfdpublic@wildtechgarden.ca>
@danielfdickinson

Copy link
Copy Markdown
Contributor Author

@BKPepe More files/* issues 🤷 Do you want me to create another issue, as suggested at the bottom of the comment, or is this enough for you?

Comment thread admin/zabbix/files/keep.d/zabbix_agentd Outdated
@@ -0,0 +1 @@
/etc/zabbix_agentd.conf.d

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think just put this into the conffiles and you dont need to use keep.d, right?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmmm... I thought conffiles had to be files not directories. Will test.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

afaik it works with directories as well. :) We can document it somewhere, if it isnt.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Once you confirm that conffiles works for directories as well, I’ll update the bot to recommend using conffiles instead. This will also fix the false positive where it flags things not strictly meant for /etc/config.

Well, new feature. It's a bit cheeky, but we'll fine-tune it

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can confirm directories in conffiles are preserved.

@BKPepe BKPepe mentioned this pull request Jul 17, 2026
1 task
@danielfdickinson
danielfdickinson force-pushed the pr-zabbix-bump-7-0-28 branch 2 times, most recently from d2a08f6 to 1c47514 Compare July 17, 2026 06:34
@danielfdickinson danielfdickinson changed the title zabbix: bump version to 7.0.28 and add proxy zabbix: bump to 7.0.28, bring to parity between agent, server, and proxy, and do some cleanup Jul 17, 2026
@danielfdickinson danielfdickinson changed the title zabbix: bump to 7.0.28, bring to parity between agent, server, and proxy, and do some cleanup zabbix: bump to 7.0.28; bring to parity between agent, server, and proxy; and do some cleanup Jul 17, 2026
@danielfdickinson

Copy link
Copy Markdown
Contributor Author

Built while I slept. Will run-test when I am back from work this evening.

Add the user config file directories (/etc/zabbix_x.conf.d) to the
list of directories and files to preserve across sysupgrade.

Signed-off-by: Daniel F. Dickinson <dfdpublic@wildtechgarden.ca>
Avoid treating openwrt-supplies params files as configuration data.
Instead have them in a separate directory which is included in the
zabbix_agentd configuration by default.

Signed-off-by: Daniel F. Dickinson <dfdpublic@wildtechgarden.ca>
The sysctl file increases max files to allow the default full
complement of discovery workers, however this is probably not a
hard requirement and such a conf not shipped elsewhere in tree, so
leave that to the user to configure. (The syslog messages from
zabbix-server and/or zabbix-proxy provided the needed information).

Signed-off-by: Daniel F. Dickinson <dfdpublic@wildtechgarden.ca>
While the frontend can mostly operate without php8-mod-simplexml, when
trying to import XML templates the user only gets unhelpful error
messages and is unlikely to realize the module is required for that
functionality. Therefore have the frontend depend on php8-mod-simplexml.

Signed-off-by: Daniel F. Dickinson <dfdpublic@wildtechgarden.ca>
@danielfdickinson
danielfdickinson marked this pull request as ready for review July 17, 2026 19:34
@danielfdickinson

Copy link
Copy Markdown
Contributor Author

@BKPepe Would you prefer this split into two or three PRs? The commits are reasonably atomic, so I don't think a split is required, but I thought I would ask, despite the fact that waiting for PRs to clear is a pain.

@openwrt-ai openwrt-ai left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-reviewed at head after the restructure from sed-scripts back to config patches (9 commits since my last review). Each commit message matches its diff, the three USERIDs and per-service conf.d dirs line up, and the sysctl removal is consistent across file/install/conffiles. One minor parity nit left inline.


Generated by Claude Code

if [ "$never_root" -eq 1 ]; then
procd_set_param user ${USER}
fi
procd_set_param respawn

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: This commit brings agentd to parity with zabbix_server, but the agentd instance omits procd_set_param file ${CONFIG}, which both zabbix_server.init:45 and zabbix_proxy.init:44 set. Without it procd won't track the config file, so editing /etc/zabbix_agentd.conf and running reload won't restart the agent. If the omission is intentional, ignore; otherwise:

Suggested change
procd_set_param respawn
procd_set_param file ${CONFIG}
procd_set_param respawn

Generated by Claude Code

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed this is #30026 where these changes now live.

@danielfdickinson danielfdickinson changed the title zabbix: bump to 7.0.28; bring to parity between agent, server, and proxy; and do some cleanup zabbix: bring to parity between agent, server, and proxy; and do some cleanup Jul 18, 2026
@danielfdickinson

Copy link
Copy Markdown
Contributor Author

Have split into #30025, #30026, and #30027. Therefore closing this 'omnibus' PR.

@BKPepe

BKPepe commented Jul 18, 2026

Copy link
Copy Markdown
Member

@BKPepe Would you prefer this split into two or three PRs? The commits are reasonably atomic, so I don't think a split is required, but I thought I would ask, despite the fact that waiting for PRs to clear is a pain.

Oh, that's up to you, but from my point of view, it is always better to have it splitted.

@danielfdickinson
danielfdickinson deleted the pr-zabbix-bump-7-0-28 branch July 18, 2026 12:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants