aboutsummaryrefslogtreecommitdiffstats
path: root/net-mgmt
diff options
context:
space:
mode:
authorsylvio <sylvio@FreeBSD.org>2012-05-12 21:55:28 +0800
committersylvio <sylvio@FreeBSD.org>2012-05-12 21:55:28 +0800
commita3760bed8c6696a9f80b9b1f2ffcd19528bfc508 (patch)
tree99b512c2ae1b262b0489087426fcb26e59479dce /net-mgmt
parent33975b9bae44a96a42fc84f5431f35f9fdd3feb8 (diff)
downloadfreebsd-ports-gnome-a3760bed8c6696a9f80b9b1f2ffcd19528bfc508.tar.gz
freebsd-ports-gnome-a3760bed8c6696a9f80b9b1f2ffcd19528bfc508.tar.zst
freebsd-ports-gnome-a3760bed8c6696a9f80b9b1f2ffcd19528bfc508.zip
- Update to 1.8.13,2
- Add patch to proc.c to address ZBX-3897 and ZBX-4704 until applied upstream PR: ports/167802 Submitted by: Jim Riggs <ports@christianserving.org> (maintainer)
Diffstat (limited to 'net-mgmt')
-rw-r--r--net-mgmt/zabbix-server/Makefile3
-rw-r--r--net-mgmt/zabbix-server/distinfo4
-rw-r--r--net-mgmt/zabbix-server/files/patch-src_libs_zbxsysinfo_freebsd__proc.c98
-rw-r--r--net-mgmt/zabbix2-server/Makefile3
-rw-r--r--net-mgmt/zabbix2-server/distinfo4
-rw-r--r--net-mgmt/zabbix2-server/files/patch-src_libs_zbxsysinfo_freebsd__proc.c98
6 files changed, 202 insertions, 8 deletions
diff --git a/net-mgmt/zabbix-server/Makefile b/net-mgmt/zabbix-server/Makefile
index 1b7380357118..20f115e21f9c 100644
--- a/net-mgmt/zabbix-server/Makefile
+++ b/net-mgmt/zabbix-server/Makefile
@@ -6,8 +6,7 @@
#
PORTNAME= zabbix
-PORTVERSION= 1.8.10
-PORTREVISION= 1
+PORTVERSION= 1.8.13
PORTEPOCH= 2
CATEGORIES= net-mgmt
MASTER_SITES= SF/zabbix/ZABBIX%20Latest%20Stable/${PORTVERSION}
diff --git a/net-mgmt/zabbix-server/distinfo b/net-mgmt/zabbix-server/distinfo
index af147086e15d..9d1bb6b81705 100644
--- a/net-mgmt/zabbix-server/distinfo
+++ b/net-mgmt/zabbix-server/distinfo
@@ -1,2 +1,2 @@
-SHA256 (zabbix-1.8.10.tar.gz) = d965d23f2ce8c7ddee7a1532863a208fae28958e3fc0871e0229ffa06f88a54b
-SIZE (zabbix-1.8.10.tar.gz) = 4217417
+SHA256 (zabbix-1.8.13.tar.gz) = ac4497cde031b793e492e874b091d109da7d5410c4ba55f54cad0749ae47e667
+SIZE (zabbix-1.8.13.tar.gz) = 4235482
diff --git a/net-mgmt/zabbix-server/files/patch-src_libs_zbxsysinfo_freebsd__proc.c b/net-mgmt/zabbix-server/files/patch-src_libs_zbxsysinfo_freebsd__proc.c
new file mode 100644
index 000000000000..fe686e0eb785
--- /dev/null
+++ b/net-mgmt/zabbix-server/files/patch-src_libs_zbxsysinfo_freebsd__proc.c
@@ -0,0 +1,98 @@
+--- src/libs/zbxsysinfo/freebsd/proc.c.orig 2011-12-28 03:27:42.000000000 -0600
++++ src/libs/zbxsysinfo/freebsd/proc.c 2012-04-25 21:54:13.877489156 -0500
+@@ -36,17 +36,13 @@
+ # define ZBX_PROC_PID ki_pid
+ # define ZBX_PROC_COMM ki_comm
+ # define ZBX_PROC_STAT ki_stat
+-# define ZBX_PROC_TSIZE ki_tsize
+-# define ZBX_PROC_DSIZE ki_dsize
+-# define ZBX_PROC_SSIZE ki_ssize
++# define ZBX_PROC_VSIZE ki_size
+ #else
+ # define ZBX_COMMLEN MAXCOMLEN
+ # define ZBX_PROC_PID kp_proc.p_pid
+ # define ZBX_PROC_COMM kp_proc.p_comm
+ # define ZBX_PROC_STAT kp_proc.p_stat
+-# define ZBX_PROC_TSIZE kp_eproc.e_vm.vm_tsize
+-# define ZBX_PROC_DSIZE kp_eproc.e_vm.vm_dsize
+-# define ZBX_PROC_SSIZE kp_eproc.e_vm.vm_ssize
++# define ZBX_PROC_VSIZE kp_eproc.e_vm.vm_map.size
+ #endif
+
+ static char *get_commandline(struct kinfo_proc *proc)
+@@ -97,7 +93,7 @@
+ char procname[MAX_STRING_LEN],
+ buffer[MAX_STRING_LEN],
+ proccomm[MAX_STRING_LEN], *args;
+- int do_task, pagesize, count, i,
++ int do_task, count, i,
+ proc_ok, comm_ok,
+ mib[4], mibs;
+
+@@ -152,8 +148,6 @@
+ if (0 != get_param(param, 4, proccomm, sizeof(proccomm)))
+ *proccomm = '\0';
+
+- pagesize = getpagesize();
+-
+ mib[0] = CTL_KERN;
+ mib[1] = KERN_PROC;
+ if (NULL != usrinfo)
+@@ -164,7 +158,11 @@
+ }
+ else
+ {
++#if(__FreeBSD_version > 500000)
++ mib[2] = KERN_PROC_PROC;
++#else
+ mib[2] = KERN_PROC_ALL;
++#endif
+ mib[3] = 0;
+ mibs = 3;
+ }
+@@ -184,11 +182,6 @@
+
+ for (i = 0; i < count; i++)
+ {
+-#if(__FreeBSD_version > 500000)
+- if (proc[i].ki_flag & P_KTHREAD) /* skip a system thread */
+- continue;
+-#endif
+-
+ proc_ok = 0;
+ comm_ok = 0;
+ if (*procname == '\0' || 0 == strcmp(procname, proc[i].ZBX_PROC_COMM))
+@@ -205,8 +198,7 @@
+
+ if (proc_ok && comm_ok)
+ {
+- value = proc[i].ZBX_PROC_TSIZE + proc[i].ZBX_PROC_DSIZE + proc[i].ZBX_PROC_SSIZE;
+- value *= pagesize;
++ value = proc[i].ZBX_PROC_VSIZE; /* vsize is bytes not pages */
+
+ if (0 == proccount++)
+ memsize = value;
+@@ -306,7 +298,11 @@
+ }
+ else
+ {
++#if(__FreeBSD_version > 500000)
++ mib[2] = KERN_PROC_PROC;
++#else
+ mib[2] = KERN_PROC_ALL;
++#endif
+ mib[3] = 0;
+ mibs = 3;
+ }
+@@ -326,11 +322,6 @@
+
+ for (i = 0; i < count; i++)
+ {
+-#if(__FreeBSD_version > 500000)
+- if (proc[i].ki_flag & P_KTHREAD) /* skip a system thread */
+- continue;
+-#endif
+-
+ proc_ok = 0;
+ stat_ok = 0;
+ comm_ok = 0; \ No newline at end of file
diff --git a/net-mgmt/zabbix2-server/Makefile b/net-mgmt/zabbix2-server/Makefile
index 1b7380357118..20f115e21f9c 100644
--- a/net-mgmt/zabbix2-server/Makefile
+++ b/net-mgmt/zabbix2-server/Makefile
@@ -6,8 +6,7 @@
#
PORTNAME= zabbix
-PORTVERSION= 1.8.10
-PORTREVISION= 1
+PORTVERSION= 1.8.13
PORTEPOCH= 2
CATEGORIES= net-mgmt
MASTER_SITES= SF/zabbix/ZABBIX%20Latest%20Stable/${PORTVERSION}
diff --git a/net-mgmt/zabbix2-server/distinfo b/net-mgmt/zabbix2-server/distinfo
index af147086e15d..9d1bb6b81705 100644
--- a/net-mgmt/zabbix2-server/distinfo
+++ b/net-mgmt/zabbix2-server/distinfo
@@ -1,2 +1,2 @@
-SHA256 (zabbix-1.8.10.tar.gz) = d965d23f2ce8c7ddee7a1532863a208fae28958e3fc0871e0229ffa06f88a54b
-SIZE (zabbix-1.8.10.tar.gz) = 4217417
+SHA256 (zabbix-1.8.13.tar.gz) = ac4497cde031b793e492e874b091d109da7d5410c4ba55f54cad0749ae47e667
+SIZE (zabbix-1.8.13.tar.gz) = 4235482
diff --git a/net-mgmt/zabbix2-server/files/patch-src_libs_zbxsysinfo_freebsd__proc.c b/net-mgmt/zabbix2-server/files/patch-src_libs_zbxsysinfo_freebsd__proc.c
new file mode 100644
index 000000000000..fe686e0eb785
--- /dev/null
+++ b/net-mgmt/zabbix2-server/files/patch-src_libs_zbxsysinfo_freebsd__proc.c
@@ -0,0 +1,98 @@
+--- src/libs/zbxsysinfo/freebsd/proc.c.orig 2011-12-28 03:27:42.000000000 -0600
++++ src/libs/zbxsysinfo/freebsd/proc.c 2012-04-25 21:54:13.877489156 -0500
+@@ -36,17 +36,13 @@
+ # define ZBX_PROC_PID ki_pid
+ # define ZBX_PROC_COMM ki_comm
+ # define ZBX_PROC_STAT ki_stat
+-# define ZBX_PROC_TSIZE ki_tsize
+-# define ZBX_PROC_DSIZE ki_dsize
+-# define ZBX_PROC_SSIZE ki_ssize
++# define ZBX_PROC_VSIZE ki_size
+ #else
+ # define ZBX_COMMLEN MAXCOMLEN
+ # define ZBX_PROC_PID kp_proc.p_pid
+ # define ZBX_PROC_COMM kp_proc.p_comm
+ # define ZBX_PROC_STAT kp_proc.p_stat
+-# define ZBX_PROC_TSIZE kp_eproc.e_vm.vm_tsize
+-# define ZBX_PROC_DSIZE kp_eproc.e_vm.vm_dsize
+-# define ZBX_PROC_SSIZE kp_eproc.e_vm.vm_ssize
++# define ZBX_PROC_VSIZE kp_eproc.e_vm.vm_map.size
+ #endif
+
+ static char *get_commandline(struct kinfo_proc *proc)
+@@ -97,7 +93,7 @@
+ char procname[MAX_STRING_LEN],
+ buffer[MAX_STRING_LEN],
+ proccomm[MAX_STRING_LEN], *args;
+- int do_task, pagesize, count, i,
++ int do_task, count, i,
+ proc_ok, comm_ok,
+ mib[4], mibs;
+
+@@ -152,8 +148,6 @@
+ if (0 != get_param(param, 4, proccomm, sizeof(proccomm)))
+ *proccomm = '\0';
+
+- pagesize = getpagesize();
+-
+ mib[0] = CTL_KERN;
+ mib[1] = KERN_PROC;
+ if (NULL != usrinfo)
+@@ -164,7 +158,11 @@
+ }
+ else
+ {
++#if(__FreeBSD_version > 500000)
++ mib[2] = KERN_PROC_PROC;
++#else
+ mib[2] = KERN_PROC_ALL;
++#endif
+ mib[3] = 0;
+ mibs = 3;
+ }
+@@ -184,11 +182,6 @@
+
+ for (i = 0; i < count; i++)
+ {
+-#if(__FreeBSD_version > 500000)
+- if (proc[i].ki_flag & P_KTHREAD) /* skip a system thread */
+- continue;
+-#endif
+-
+ proc_ok = 0;
+ comm_ok = 0;
+ if (*procname == '\0' || 0 == strcmp(procname, proc[i].ZBX_PROC_COMM))
+@@ -205,8 +198,7 @@
+
+ if (proc_ok && comm_ok)
+ {
+- value = proc[i].ZBX_PROC_TSIZE + proc[i].ZBX_PROC_DSIZE + proc[i].ZBX_PROC_SSIZE;
+- value *= pagesize;
++ value = proc[i].ZBX_PROC_VSIZE; /* vsize is bytes not pages */
+
+ if (0 == proccount++)
+ memsize = value;
+@@ -306,7 +298,11 @@
+ }
+ else
+ {
++#if(__FreeBSD_version > 500000)
++ mib[2] = KERN_PROC_PROC;
++#else
+ mib[2] = KERN_PROC_ALL;
++#endif
+ mib[3] = 0;
+ mibs = 3;
+ }
+@@ -326,11 +322,6 @@
+
+ for (i = 0; i < count; i++)
+ {
+-#if(__FreeBSD_version > 500000)
+- if (proc[i].ki_flag & P_KTHREAD) /* skip a system thread */
+- continue;
+-#endif
+-
+ proc_ok = 0;
+ stat_ok = 0;
+ comm_ok = 0; \ No newline at end of file