Hi all
A new take on updating current zabbix_agentd 4.2.6 to latest LTS version. This set updates the agent version, fixes a few problems with the original addon and adds a few ipfire-specific metrics for the user to monitor out of the box (which I will document on the wiki when the patch-set is accepted).
The differences with the previous patch submission are: - patch 1: update to v5.0.20 - patch 2: - In the previous version the correct modules dir was commented out in the rootfile and was manually removed in the uninstall script if it was not empty. But since it is also included in the backup I figured it can be removed always by remove_files so I kept it in the rootfile now. - Checks before creating dirs are added in install script to see if dir is not already existing (like most other addons seem to do) - Function extract_backup_includes was not called in update.sh script causing possible scenarios where those includes are not present when backup needs to be taken or restored. - patch 3: Made sure to remove all configfiles upon uninstall as everything is in the backup. Also made sure that the ipfire supplied userparameter_pakfire.conf file is not added in addon-backup hence correctly updated on pak update. - patch 4: Is a small new patch to default the zabbix agent to listen only on GREEN as that is probably where the user's Zabbix server is and is a safer default than listening on all interfaces. - patch 5: was formerly patch4. - Grouped all ipfire (non-pakfire) related metrics in a single config file for simplicity. - Replaced the previous problematic iptables related metric and sudo rights with the renewed and safer getipstats binary. - Removed the services related metrics and perl script for now as we first need to have the new services metadata in the pak's and related pakfire functions so that I don't need to copy the bad code from services.cgi as I did before. - Added 2 new metrics: number of active dhcp leases and number of captive portal users. Those where contributed by StackKorora on my Zabbix template for IPFire on github.
As it was almost a year ago, previous patch submission and discussion can be found here: https://lists.ipfire.org/pipermail/development/2021-April/009872.html
I hope I addressed all concerns there where on the previous submission.
Regards Robin