First Last Prev Next    No search results available
Details
: fix for bogus uptime metrics
Bug#: 209
: Ganglia Monitoring System
: gmond
Status: RESOLVED
Resolution: DUPLICATE of bug 169
: Sun
: Linux
: 3.0.x
: P2
: normal

:
:
:
  Show dependency tree - Show dependency graph
People
Reporter: Dave Love <d.love@liverpool.ac.uk>
Assigned To: Sourceforge Bugzilla <ganglia-bugzilla@lists.sourceforge.net>

Attachments


Note

You need to log in before you can comment on or make changes to this bug.

Related actions


Description:   Opened: 2008-09-10 06:45
gmond was reporting the last boot time as the epoch on our systems
(Sun 8-core x2200s and 4-core x4100s running SuSE 10.3) and so
reporting bogus uptimes.

The reason is that /proc/stat is too big (~9kB) for the allocated
buffer, so the data at the end aren't read.  This fixes it on these
systems, but I don't know what determines the size of /proc/stat and
whether it might need an even bigger buffer sometimes.

This is against 3.0.7, but looks appropriate for the head source too.

2008-08-23  Dave Love  <d.love@liverpool.ac.uk>

	* libmetrics/linux/metrics.c (BUFFSIZE): Double size to account
	for large /proc/stat on some systems.

--- libmetrics/linux/metrics.c	2008/08/23 09:55:23	1.1
+++ libmetrics/linux/metrics.c	2008/08/23 10:05:53
@@ -35,7 +35,7 @@
 
 /* Never changes */
 #ifndef BUFFSIZE
-#define BUFFSIZE 8192
+#define BUFFSIZE 16384
 #endif
 char proc_cpuinfo[BUFFSIZE];
 char proc_sys_kernel_osrelease[BUFFSIZE];
------- Comment #1 From Bernard Li 2008-09-11 12:15:13 -------
Hi Dave:

Thanks for the patch!

This looks like a dup of 169 though:

http://bugzilla.ganglia.info/cgi-bin/bugzilla/show_bug.cgi?id=169

Perhaps you can submit your patch there and close this one as a dup of 169?
------- Comment #2 From Carlo Marcelo Arenas Belon 2008-09-12 22:39:44 -------

*** This bug has been marked as a duplicate of 169 ***

First Last Prev Next    No search results available