[packages/net-snmp] Bug 1314610 - snmpd complaining twice "Cannot statfs net:[********]#***: No such file or directory"

glen glen at pld-linux.org
Mon Jun 4 09:54:10 CEST 2018


commit c3c768527e0fa7110927eb149e2df13f64e2e4d2
Author: Elan Ruusamäe <glen at pld-linux.org>
Date:   Mon Jun 4 10:50:12 2018 +0300

    Bug 1314610 - snmpd complaining twice "Cannot statfs net:[********]#***: No such file or directory" every 10 minutes

 1314610.patch | 24 ++++++++++++++++++++++++
 net-snmp.spec |  4 +++-
 2 files changed, 27 insertions(+), 1 deletion(-)
---
diff --git a/net-snmp.spec b/net-snmp.spec
index e082293..c6c4698 100644
--- a/net-snmp.spec
+++ b/net-snmp.spec
@@ -26,7 +26,7 @@ Summary(uk.UTF-8):	Набір утиліт для протоколу SNMP від
 Name:		net-snmp
 # NOTE: 5.7.x is LTS version
 Version:	5.7.3
-Release:	14
+Release:	15
 License:	BSD-like
 Group:		Networking/Daemons
 Source0:	http://downloads.sourceforge.net/net-snmp/%{name}-%{version}.tar.gz
@@ -57,6 +57,7 @@ Patch13:	%{name}-TCP_STATS_CACHE_TIMEOUT.patch
 Patch14:	%{name}-logging.patch
 Patch15:	%{name}-Remove-U64-typedef.patch
 Patch16:	%{name}-Fix-Makefile-PL.patch
+Patch17:	1314610.patch
 URL:		http://www.net-snmp.org/
 BuildRequires:	autoconf >= 2.63
 BuildRequires:	automake
@@ -458,6 +459,7 @@ SNMP dla trzech wersji tego protokołu (SNMPv3, SNMPv2c, SNMPv1).
 %patch14 -p1
 %patch15 -p1
 %patch16 -p1
+%patch17 -p1
 
 %build
 %{__libtoolize}
diff --git a/1314610.patch b/1314610.patch
new file mode 100644
index 0000000..0831d5d
--- /dev/null
+++ b/1314610.patch
@@ -0,0 +1,24 @@
+Bug 1314610 - snmpd complaining twice "Cannot statfs net:[********]#***: No such file or directory" every 10 minutes
+https://bugzilla.redhat.com/show_bug.cgi?id=1314610
+
+diff -urNp old/agent/mibgroup/hardware/fsys/fsys_mntctl.c new/agent/mibgroup/hardware/fsys/fsys_mntctl.c
+--- old/agent/mibgroup/hardware/fsys/fsys_mntctl.c	2017-10-11 14:54:48.111065174 +0200
++++ new/agent/mibgroup/hardware/fsys/fsys_mntctl.c	2017-10-11 15:11:16.996918197 +0200
+@@ -88,7 +88,6 @@ netsnmp_fsys_arch_load( void )
+     char          *path;
+     struct statfs  stat_buf;
+     netsnmp_fsys_info *entry;
+-    char               tmpbuf[1024];
+ 
+     /*
+      * Retrieve information about the currently mounted filesystems...
+@@ -160,8 +159,7 @@ netsnmp_fsys_arch_load( void )
+             continue;
+ 
+         if ( statfs( entry->path, &stat_buf ) < 0 ) {
+-            snprintf( tmpbuf, sizeof(tmpbuf), "Cannot statfs %s", entry->path );
+-            snmp_log_perror( tmpbuf );
++            NETSNMP_LOGONCE(( LOG_ERROR, "Cannot statfs %s", entry->path ));
+             continue;
+         }
+         entry->units =  stat_buf.f_bsize;
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/net-snmp.git/commitdiff/c3c768527e0fa7110927eb149e2df13f64e2e4d2



More information about the pld-cvs-commit mailing list