Xymon Mailing List Archive search

Windows memory trending

7 messages in this thread

list Larry Barber · Tue, 19 Jul 2005 15:28:29 -0400 (EDT) ·
I just noticed that all the memory trending graphs for Windows machines
are broken. They just show zero's all across the board. Is this a known
problem, or is something broken in my setup?

Thanks,
Larry Barber
list Henrik Størner · Tue, 19 Jul 2005 21:42:39 +0200 ·
quoted from Larry Barber
On Tue, Jul 19, 2005 at 03:28:29PM -0400, user-7a6c75d6cc10@xymon.invalid wrote:
I just noticed that all the memory trending graphs for Windows machines
are broken. They just show zero's all across the board. Is this a known
problem, or is something broken in my setup?
Do you have the bb-memory extension installed on your Windows boxes,
or just the BBNT client ?

If you dont know - is there a "memory" column for these boxes, or 
only the "cpu" column ? bb-memory generates a "memory" column, the
standard BBNT client does not.

I suspect it's the BBNT client that is feeding your memory graphs.
It has some problems with large-memory systems, but it could also be
a bug in Hobbit. Please send me the output from the "cpu" status on
one of these boxes.


Regards,
Henrik
list Larry Barber · Tue, 19 Jul 2005 15:52:08 -0400 (EDT) ·
We're just running the NT client, I have enough trouble getting the NT
admins to just install that, let alone anything else. It probably is the
memory size that's causing problems. Here's a sample of the return from
the cpu test:

Tue Jul 19 14:44:37 CDT 2005 [ANANKE] up: 83 days, 1 users, 40 procs,
load=1%, PhysicalMem: 3840MB(23%)


Memory Statistics
Total Physical memory:          4025925632 bytes (3.75GB)
Available Physical memory:      3102130176 bytes (2.89GB)
Total PageFile size:            4294967295 bytes (4.00GB)
Available PageFile size:        4294967295 bytes (4.00GB)
Total Virtual memory size:      2147352576 bytes (2.00GB)
Available Virtual memory size:  2119045120 bytes (1.97GB)

Most active processes
00.81%	tomcat5 (0x190 [400])
00.03%	System (0x4 [4])
00.02%	winlogon (0x2ac [684])
00.02%	Rtvscan (0x8a8 [2216])
00.00%	VxSvc (0x918 [2328])
00.00%	svchost (0x444 [1092])
00.00%	StarbaseServer (0x13d0 [5072])
00.00%	sqlservr (0x608 [1544])
00.00%	csrss (0x294 [660])


Thanks,
Larry Barber
quoted from Henrik Størner


On Tue, 2005-07-19 at 14:42 -0500, user-ce4a2c883f75@xymon.invalid wrote:
On Tue, Jul 19, 2005 at 03:28:29PM -0400, user-7a6c75d6cc10@xymon.invalid
wrote: > I just noticed that all the memory trending graphs for Windows
machines > are broken. They just show zero's all across the board. Is this a
known > problem, or is something broken in my setup?

Do you have the bb-memory extension installed on your Windows boxes, or just the BBNT client ?

If you dont know - is there a "memory" column for these boxes, or  only the "cpu" column ? bb-memory generates a "memory" column, the standard BBNT client does not.

I suspect it's the BBNT client that is feeding your memory graphs. It has some problems with large-memory systems, but it could also be a bug in Hobbit. Please send me the output from the "cpu" status on one of these boxes.


Regards, Henrik

list Larry Barber · Tue, 19 Jul 2005 15:55:27 -0400 (EDT) ·
Now this is interesting, here's the 'cpu' output for a Windows box that
doesn't have as much memory as most of ours, that is displaying the same
behavior on the trending graphs:

Tue Jul 19 14:54:01 CDT 2005 [BARRSERVER] up: 6:14, 1 users, 32 procs,
load=1%, PhysicalMem: 512MB(32%)


Memory Statistics
Total Physical memory:           536334336 bytes (512.00MB)
Available Physical memory:       365035520 bytes (349.00MB)
Total PageFile size:            1307942912 bytes (1.22GB)
Available PageFile size:        1159303168 bytes (1.08GB)
Total Virtual memory size:      2147352576 bytes (2.00GB)
Available Virtual memory size:  2118647808 bytes (1.97GB)

Most active processes
00.06%	inetinfo (0x2e8 [744])
00.01%	bbnt (0x240 [576])
quoted from Larry Barber


Thanks,
Larry Barber

On Tue, 2005-07-19 at 14:42 -0500, user-ce4a2c883f75@xymon.invalid wrote:
On Tue, Jul 19, 2005 at 03:28:29PM -0400, user-7a6c75d6cc10@xymon.invalid
wrote: > I just noticed that all the memory trending graphs for Windows
machines > are broken. They just show zero's all across the board. Is this a
known > problem, or is something broken in my setup?

Do you have the bb-memory extension installed on your Windows boxes, or just the BBNT client ?

If you dont know - is there a "memory" column for these boxes, or  only the "cpu" column ? bb-memory generates a "memory" column, the standard BBNT client does not.

I suspect it's the BBNT client that is feeding your memory graphs. It has some problems with large-memory systems, but it could also be a bug in Hobbit. Please send me the output from the "cpu" status on one of these boxes.


Regards, Henrik

list Henrik Størner · Tue, 19 Jul 2005 22:43:44 +0200 ·
quoted from Larry Barber
On Tue, Jul 19, 2005 at 03:52:08PM -0400, user-7a6c75d6cc10@xymon.invalid wrote:
We're just running the NT client, I have enough trouble getting the NT
admins to just install that, let alone anything else. It probably is the
memory size that's causing problems. Here's a sample of the return from
the cpu test:
Thanks, testing this clearly shows that it overflows the "unsigned long"
calculations being done by Hobbit. The attached patch should solve this,
hopefully also on those platforms that don't have a built-in strtoll()
routine.

This is for Hobbit 4.0.4 - the next version will have a (slightly
different) version of this included.


Regards,
Henrik

-------------- next part --------------
--- hobbit-4.0.4/hobbitd/larrd/do_la.c.orig	2005-05-08 21:36:09.000000000 +0200
+++ hobbit-4.0.4/hobbitd/larrd/do_la.c	2005-07-19 22:37:33.794305038 +0200
@@ -10,6 +10,26 @@
 
 static char la_rcsid[] = "$Id: do_la.c,v 1.15 2005/05/08 19:35:29 henrik Exp $";
 
+static long long str2ll(char *s, char **errptr)
+{
+	long long result = 0;
+	int negative = 0;
+	char *inp;
• +	inp = s + strspn(s, " \t");
+	if (*inp == '-') { negative = 1; inp++; }
+	while (isdigit((int)*inp)) { 
+		result = 10*result + (*inp - '0'); 
+		inp++;
+	}
• +	if (errptr && (*inp != '\0') && (!isspace((int)*inp))) *errptr = inp;
• +	if (negative) result = -result;
• +	return result;
+}
• int do_la_larrd(char *hostname, char *testname, char *msg, time_t tstamp)
 {
 	static char *la_params[]          = { "rrdcreate", rrdfn, "DS:la:GAUGE:600:0:U", rra1, rra2, rra3, rra4, NULL };
@@ -189,27 +209,27 @@
 	if (memhosts_init && (rbtFind(memhosts, hostname) == rbtEnd(memhosts))) {
 		/* Pick up memory statistics */
 		int found, realuse, swapuse;
-		unsigned long phystotal, physavail, pagetotal, pageavail;
+		long long phystotal, physavail, pagetotal, pageavail;
 
 		found = realuse = swapuse = 0;
 		phystotal = physavail = pagetotal = pageavail = 0;
 
 		p = strstr(msg, "Total Physical memory:");
-		if (p) { found++; phystotal = atol(strchr(p, ':') + 1); }
+		if (p) { found++; phystotal = str2ll(strchr(p, ':') + 1, NULL); }
 
 		if (found == 1) {
 			p = strstr(msg, "Available Physical memory:");
-			if (p) { found++; physavail = atol(strchr(p, ':') + 1); }
+			if (p) { found++; physavail = str2ll(strchr(p, ':') + 1, NULL); }
 		}
 
 		if (found == 2) {
 			p = strstr(msg, "Total PageFile size:"); 
-			if (p) { found++; pagetotal = atol(strchr(p, ':') + 1); }
+			if (p) { found++; pagetotal = str2ll(strchr(p, ':') + 1, NULL); }
 		}
 
 		if (found == 2) {
 			p = strstr(msg, "Available PageFile size:"); 
-			if (p) { found++; pageavail = atol(strchr(p, ':') + 1); }
+			if (p) { found++; pageavail = str2ll(strchr(p, ':') + 1, NULL); }
 		}
 
 		if (found == 4) {
list Henrik Størner · Tue, 19 Jul 2005 22:46:02 +0200 ·
quoted from Henrik Størner
On Tue, Jul 19, 2005 at 10:43:44PM +0200, Henrik Stoerner wrote:
Thanks, testing this clearly shows that it overflows the "unsigned long"
calculations being done by Hobbit. The attached patch should solve this,
For those not familiar with patching, to apply this you must:

  cd hobbit-4.0.4
  patch -p1 </tmp/hobbit-4.0.4-win32mem.patch
  make
  stop hobbit
  as root: "make install"
  start hobbit

Henrik
list Thomas Pedersen · Wed, 20 Jul 2005 15:48:11 +0200 ·
In the 4.0.5RC1 I get overflow errors (Host birn05-apps2 cpu report overflows in memory usage calculation) for windows cpu reports like

Memory Statistics

Total Physical memory:          2415353856 bytes (2.25GB)

Available Physical memory:       966356992 bytes (922.00MB)

Total PageFile size:            4294967295 bytes (4.00GB)

Available PageFile size:        3075772416 bytes (2.87GB)

Total Virtual memory size:      2147352576 bytes (2.00GB)

Available Virtual memory size:  2117836800 bytes (1.97GB)
quoted from Henrik Størner





Henrik Stoerner skrev:
On Tue, Jul 19, 2005 at 10:43:44PM +0200, Henrik Stoerner wrote:

  
Thanks, testing this clearly shows that it overflows the "unsigned long"

calculations being done by Hobbit. The attached patch should solve this,

    

For those not familiar with patching, to apply this you must:



  cd hobbit-4.0.4

  patch -p1 user-095ef1c764a2@xymon.invalid