From 5c3f6fc72aca6f12549735454e06400654ee2565 Mon Sep 17 00:00:00 2001 From: Fabian Arrotin Date: Oct 03 2024 12:14:22 +0000 Subject: Import upstream zabbix 6.0.34 Signed-off-by: Fabian Arrotin --- diff --git a/SOURCES/agent2.conf.socket.patch b/SOURCES/agent2.conf.socket.patch new file mode 100644 index 0000000..415b314 --- /dev/null +++ b/SOURCES/agent2.conf.socket.patch @@ -0,0 +1,21 @@ +diff -urN zabbix-6.4.0beta6.orig/src/go/conf/zabbix_agent2.conf zabbix-6.4.0beta6/src/go/conf/zabbix_agent2.conf +--- zabbix-6.4.0beta6.orig/src/go/conf/zabbix_agent2.conf 2023-01-12 18:58:00.992534889 +0200 ++++ zabbix-6.4.0beta6/src/go/conf/zabbix_agent2.conf 2023-01-13 09:30:59.464813623 +0200 +@@ -309,6 +309,8 @@ + # Default:/tmp/agent.plugin.sock + # PluginSocket= + ++PluginSocket=/run/zabbix/agent.plugin.sock ++ + ####### USER-DEFINED MONITORED PARAMETERS ####### + + ### Option: UnsafeUserParameters +@@ -350,7 +352,7 @@ + # Default: + # ControlSocket= + +-ControlSocket=/tmp/agent.sock ++ControlSocket=/run/zabbix/agent.sock + + ####### TLS-RELATED PARAMETERS ####### + diff --git a/SOURCES/fping3-sourceip-option.patch b/SOURCES/fping3-sourceip-option.patch index f1a21e5..d6ecf7f 100644 --- a/SOURCES/fping3-sourceip-option.patch +++ b/SOURCES/fping3-sourceip-option.patch @@ -1,7 +1,7 @@ -diff -urN zabbix-5.0.14.orig/src/libs/zbxicmpping/icmpping.c zabbix-5.0.14/src/libs/zbxicmpping/icmpping.c ---- zabbix-5.0.14.orig/src/libs/zbxicmpping/icmpping.c 2021-07-16 18:09:40.807727222 +0300 -+++ zabbix-5.0.14/src/libs/zbxicmpping/icmpping.c 2021-07-16 18:11:43.121350484 +0300 -@@ -53,34 +53,7 @@ +diff -urN zabbix-7.0.0alpha7.orig/src/libs/zbxicmpping/icmpping.c zabbix-7.0.0alpha7/src/libs/zbxicmpping/icmpping.c +--- zabbix-7.0.0alpha7.orig/src/libs/zbxicmpping/icmpping.c 2023-10-20 15:58:34.762406039 +0300 ++++ zabbix-7.0.0alpha7/src/libs/zbxicmpping/icmpping.c 2023-10-20 15:59:03.290569616 +0300 +@@ -75,36 +75,7 @@ static void get_source_ip_option(const char *fping, const char **option, unsigned char *checked) { @@ -10,6 +10,8 @@ diff -urN zabbix-5.0.14.orig/src/libs/zbxicmpping/icmpping.c zabbix-5.0.14/src/l - - zbx_snprintf(tmp, sizeof(tmp), "%s -h 2>&1", fping); - +- zabbix_log(LOG_LEVEL_DEBUG, "executing %s", tmp); +- - if (NULL == (f = popen(tmp, "r"))) - return; - diff --git a/SOURCES/zabbix-agent2.service b/SOURCES/zabbix-agent2.service index c7d0288..bc22363 100644 --- a/SOURCES/zabbix-agent2.service +++ b/SOURCES/zabbix-agent2.service @@ -15,6 +15,7 @@ ExecStop=/bin/kill -SIGTERM $MAINPID RestartSec=10s User=zabbix Group=zabbix +LimitNOFILE=8192 [Install] WantedBy=multi-user.target diff --git a/SOURCES/zabbix-proxy.service b/SOURCES/zabbix-proxy.service index 8e44e7a..9eb7311 100644 --- a/SOURCES/zabbix-proxy.service +++ b/SOURCES/zabbix-proxy.service @@ -15,6 +15,8 @@ After=postgresql-11.service After=postgresql-12.service After=postgresql-13.service After=postgresql-14.service +After=postgresql-15.service +After=postgresql-16.service [Service] Environment="CONFFILE=/etc/zabbix/zabbix_proxy.conf" diff --git a/SOURCES/zabbix-server.service b/SOURCES/zabbix-server.service index e06e0d2..3eb79ea 100644 --- a/SOURCES/zabbix-server.service +++ b/SOURCES/zabbix-server.service @@ -15,6 +15,8 @@ After=postgresql-11.service After=postgresql-12.service After=postgresql-13.service After=postgresql-14.service +After=postgresql-15.service +After=postgresql-16.service [Service] Environment="CONFFILE=/etc/zabbix/zabbix_server.conf" diff --git a/SPECS/zabbix.spec b/SPECS/zabbix.spec index b4bbce4..d924063 100644 --- a/SPECS/zabbix.spec +++ b/SPECS/zabbix.spec @@ -1,6 +1,6 @@ Name: zabbix -Version: 6.0.12 -Release: %{?alphatag:%{?alphatag}.}1%{?dist} +Version: 6.0.34 +Release: %{?alphatag:%{?alphatag}.}release2%{?dist} Summary: The Enterprise-class open source monitoring solution Group: Applications/Internet License: GPLv2+ @@ -35,15 +35,16 @@ Patch4: agent2.conf.patch Patch5: rhel6-go11.6.patch Patch6: conf.var.run.patch Patch7: agent2.conf.var.run.patch +Patch8: agent2.conf.socket.patch Buildroot: %{_tmppath}/zabbix-%{version}-%{release}-root-%(%{__id_u} -n) %{!?build_agent: %global build_agent 1} -%ifarch x86_64 +%ifarch x86_64 aarch64 %if 0%{?rhel} >= 6 -%{!?build_agent2: %global build_agent2 0} +%{!?build_agent2: %global build_agent2 1} %endif %if 0%{?rhel} >= 8 %{!?build_web_service: %global build_web_service 1} @@ -89,31 +90,25 @@ Buildroot: %{_tmppath}/zabbix-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: make %if 0%{?rhel} >= 8 -BuildRequires: libssh-devel >= 0.9.0 BuildRequires: mariadb-connector-c-devel BuildRequires: postgresql-devel >= 12.0 -BuildRequires: golang golang-bin -%endif -%if 0%{?rhel} >= 7 -BuildRequires: curl-devel >= 7.13.1 -BuildRequires: libevent-devel -BuildRequires: OpenIPMI-devel >= 2 -BuildRequires: gnutls-devel -BuildRequires: openldap-devel -BuildRequires: unixODBC-devel -BuildRequires: pcre2-devel BuildRequires: sqlite-devel BuildRequires: net-snmp-devel -BuildRequires: libxml2-devel +BuildRequires: openldap-devel +BuildRequires: gnutls-devel +BuildRequires: unixODBC-devel +BuildRequires: curl-devel >= 7.13.1 +BuildRequires: OpenIPMI-devel >= 2 +BuildRequires: libssh-devel >= 0.9.0 BuildRequires: java-devel >= 1.6.0 +BuildRequires: libxml2-devel +BuildRequires: libevent-devel +%endif +%if 0%{?rhel} >= 7 +BuildRequires: pcre2-devel %else BuildRequires: pcre-devel %endif -%if 0%{?rhel} == 7 -BuildRequires: libssh2-devel -BuildRequires: postgresql-devel -BuildRequires: mariadb-devel -%endif %if 0%{?rhel} >= 6 BuildRequires: openssl-devel >= 1.0.1 %endif @@ -122,8 +117,10 @@ BuildRequires: systemd %endif %if 0%{?build_selinux_policy} BuildRequires: policycoreutils-devel +%if 0%{rhel} >= 9 BuildRequires: selinux-policy-devel %endif +%endif %description Zabbix is the ultimate enterprise-level software designed for @@ -491,6 +488,10 @@ mv database/sqlite3/schema.sql database/sqlite3/proxy.sql %endif %endif +%if 0%{?build_agent2} +%patch8 -p1 +%endif + %build # Build consists of 1-3 configure/make passes, one for each database. # pass 1: is sqlite proxy, may be omitted. @@ -601,7 +602,7 @@ make_flags="$make_flags ALERT_SCRIPTS_PATH=/usr/lib/zabbix/alertscripts" # pass 1 if [ -n "$build_conf_1" ]; then %configure $build_conf_common $build_conf_1 - make $make_flags + make -j24 $make_flags mv src/zabbix_proxy/zabbix_proxy src/zabbix_proxy/zabbix_proxy_sqlite3 fi @@ -609,7 +610,7 @@ fi # pass 2 if [ -n "$build_conf_2" ]; then %configure $build_conf_common $build_conf_2 - make $make_flags + make -j24 $make_flags %if 0%{?build_server} mv src/zabbix_server/zabbix_server src/zabbix_server/zabbix_server_pgsql %endif @@ -622,7 +623,7 @@ fi # pass 3 if [ -n "$build_conf_3" ]; then %configure $build_conf_common $build_conf_3 - make $make_flags + make -j24 $make_flags %if 0%{?build_server} mv src/zabbix_server/zabbix_server "src/zabbix_server/zabbix_server_$build_db_3" %endif @@ -701,7 +702,7 @@ install -Dm 0644 -p %{SOURCE22} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/zabbix-a %if 0%{?build_web_service} cat %{SOURCE3} | sed \ - -e 's|COMPONENT|web-service|g' \ + -e 's|COMPONENT|web_service|g' \ > $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/zabbix-web-service cp man/zabbix_web_service.man $RPM_BUILD_ROOT%{_mandir}/man8/zabbix_web_service.8 install -Dm 0644 -p %{SOURCE23} $RPM_BUILD_ROOT%{_unitdir}/zabbix-web-service.service @@ -1385,9 +1386,164 @@ if [ $1 = 0 ] && semodule -l | grep -q zabbix_policy; then semodule -r zabbix_po %changelog -* Tue Dec 20 2022 Fabian Arrotin - 6.0.12-1 -- Disabled agent2 build (missing go rpm pkgs) -- Fixed BuildRequires to cover el7/el8/el9 diff in one .spec +* Thu Sep 27 2024 Zabbix Packager - 6.0.34-release2 +- added OpenSSL compilation flags + +* Thu Sep 26 2024 Zabbix Packager - 6.0.34-release1 +- update to 6.0.34 + +* Tue Sep 24 2024 Zabbix Packager - 6.0.34-rc2.release1 +- update to 6.0.34rc2 + +* Mon Sep 16 2024 Zabbix Packager - 6.0.34-rc1.release1 +- update to 6.0.34rc1 + +* Tue Aug 13 2024 Zabbix Packager - 6.0.33-release2 +- update to 6.0.33 + +* Tue Aug 06 2024 Zabbix Packager - 6.0.33-rc1.release2 +- second release of 6.0.33rc1 + +* Tue Aug 06 2024 Zabbix Packager - 6.0.33-rc1.release1 +- update to 6.0.33rc1 + +* Mon Jul 15 2024 Zabbix Packager - 6.0.32-release1 +- update to 6.0.32 + +* Tue Jul 09 2024 Zabbix Packager - 6.0.32-rc1.release1 +- update to 6.0.32rc1 + +* Mon Jun 17 2024 Zabbix Packager - 6.0.31-release1 +- update to 6.0.31 + +* Mon Jun 10 2024 Zabbix Packager - 6.0.31-rc1.release1 +- update to 6.0.31rc1 + +* Tue May 21 2024 Zabbix Packager - 6.0.30-release1 +- update to 6.0.30 + +* Wed May 15 2024 Zabbix Packager - 6.0.30-rc1.release1 +- update to 6.0.30rc1 + +* Mon Apr 22 2024 Zabbix Packager - 6.0.29-release1 +- update to 6.0.29 + +* Mon Apr 15 2024 Zabbix Packager - 6.0.29-rc1.release1 +- update to 6.0.29rc1 + +* Mon Mar 25 2024 Zabbix Packager - 6.0.28-release1 +- update to 6.0.28 + +* Mon Mar 18 2024 Zabbix Packager - 6.0.28-rc1.release1 +- update to 6.0.28rc1 + +* Mon Feb 26 2024 Zabbix Packager - 6.0.27-release1 +- update to 6.0.27 + +* Mon Feb 19 2024 Zabbix Packager - 6.0.27-rc1.release1 +- update to 6.0.27rc1 + +* Mon Jan 29 2024 Zabbix Packager - 6.0.26-release1 +- update to 6.0.26 + +* Mon Jan 22 2024 Zabbix Packager - 6.0.26-rc1.release1 +- update to 6.0.26rc1 + +* Wed Dec 13 2023 Zabbix Packager - 6.0.25-release1 +- update to 6.0.25 + +* Thu Dec 07 2023 Zabbix Packager - 6.0.25-rc1.release1 +- update to 6.0.25rc1 + +* Thu Nov 30 2023 Zabbix Packager - 6.0.24-release1 +- update to 6.0.24 + +* Thu Nov 23 2023 Zabbix Packager - 6.0.24-rc1.release1 +- update to 6.0.24rc1 +- added After statements for postgresql 15 and 16 to server and proxy systemd unit files + +* Tue Oct 31 2023 Zabbix Packager - 6.0.23-release1 +- update to 6.0.23 + +* Mon Oct 23 2023 Zabbix Packager - 6.0.23-rc1.release1 +- update to 6.0.23rc1 + +* Mon Sep 25 2023 Zabbix Packager - 6.0.22-release1 +- update to 6.0.22 + +* Tue Sep 19 2023 Zabbix Packager - 6.0.22-rc1.release1 +- update to 6.0.22rc1 + +* Wed Sep 06 2023 Zabbix Packager - 6.0.21-release2 +- added support for aarch64 + +* Tue Aug 22 2023 Zabbix Packager - 6.0.21-release1 +- update to 6.0.21 + +* Tue Aug 15 2023 Zabbix Packager - 6.0.21-rc1.release1 +- update to 6.0.21rc1 +- fixed web_service logrotate configuration file (ZBX-23169) + +* Mon Jul 31 2023 Zabbix Packager - 6.0.20-release1 +- update to 6.0.20 + +* Mon Jul 24 2023 Zabbix Packager - 6.0.20-rc1.release1 +- update to 6.0.20rc1 + +* Tue Jun 27 2023 Zabbix Packager - 6.0.19-release1 +- update to 6.0.19 + +* Mon Jun 19 2023 Zabbix Packager - 6.0.19-rc1.release1 +- update to 6.0.19rc1 + +* Tue May 30 2023 Zabbix Packager - 6.0.18-release1 +- update to 6.0.18 + +* Mon May 22 2023 Zabbix Packager - 6.0.18-rc1.release1 +- update to 6.0.18rc1 + +* Mon Apr 24 2023 Zabbix Packager - 6.0.17-release1 +- update to 6.0.17 + +* Wed Apr 19 2023 Zabbix Packager - 6.0.17-rc2.release1 +- update to 6.0.17rc2 + +* Mon Apr 17 2023 Zabbix Packager - 6.0.17-rc1.release1 +- update to 6.0.17rc1 + +* Tue Apr 11 2023 Zabbix Packager - 6.0.16-release1 +- update to 6.0.16 + +* Wed Apr 05 2023 Zabbix Packager - 6.0.16-rc1.release1 +- update to 6.0.16rc1 + +* Fri Mar 31 2023 Zabbix Packager - 6.0.15-release1 +- update to 6.0.15 + +* Wed Mar 29 2023 Zabbix Packager - 6.0.15-rc2.release1 +- update to 6.0.15rc2 + +* Wed Mar 22 2023 Zabbix Packager - 6.0.15-rc1.release1 +- update to 6.0.15rc1 + +* Wed Mar 08 2023 Zabbix Packager - 6.0.14-release1 +- update to 6.0.14 + +* Mon Feb 27 2023 Zabbix Packager - 6.0.14-rc2.release1 +- update to 6.0.14rc2 + +* Mon Feb 20 2023 Zabbix Packager - 6.0.14-rc1.release1 +- update to 6.0.14rc1 +- removed c99-1.patch; use -std=gnu99 compiler flag instead + +* Wed Feb 01 2023 Zabbix Packager - 6.0.13-release1 +- update to 6.0.13 + +* Fri Jan 27 2023 Zabbix Packager - 6.0.13-rc1.release1 +- update to 6.0.13rc1 +- added LimitNOFILE=8192 to agent2 systemd service file (ZBX-22061) +- added agent2.conf.socket.patch (ZBX-22061) +- added c99-1.patch * Mon Dec 05 2022 Zabbix Packager - 6.0.12-release1 - update to 6.0.12