Description: Be quiet on access error SNMP agents can legitimately be not allowed to access mount points, such as trying to get to things under /run/user. This patch changes a EACCES error to a debug message. Author: Craig Small Origin: Debian Bug-Debian: https://bugs.debian.org/792832 Reviewed-by: Craig Small Last-Update: 2025-12-23 --- a/agent/mibgroup/hardware/fsys/fsys_mntent.c +++ b/agent/mibgroup/hardware/fsys/fsys_mntent.c @@ -6,6 +6,7 @@ #include "hardware/fsys/hw_fsys_private.h" #include +#include #ifdef HAVE_MNTENT_H #include #endif @@ -321,7 +322,10 @@ if (!logged && asprintf(&tmpbuf, "Cannot statfs %s", entry->path) >= 0) { - snmp_log_perror(tmpbuf); + if (errno == EACCES) + DEBUGMSGTL(("fsys", "%s\n", tmpbuf)); + else + snmp_log_perror(tmpbuf); free(tmpbuf); logged = 1; }