Xymon Mailing List Archive search

No graph for negative clock offset

4 messages in this thread

list David Stuffle · Mon, 28 Jul 2008 09:27:52 -0400 ·
Hi all,
None of my clock offset graphs graph anything when the clock offset from 
a host is a negative number.  Only positive number work.  Anyone having 
the same thing happen or know how to fix?

I'm running a snapshot 4.3.0-0.20080103

Thanks
David
list Martin Ward · Mon, 28 Jul 2008 15:24:18 +0100 ·
Funnily enough I am looking at the Hobbit code that deals with RRD data
at the moment. If you are using the NCV capabilities then it looks like
you can't have negative numbers. The generic NCV (Number, Colon, Value)
code looks for numbers only, no signs (somewhere near line 70 in
hobbitd/rrd/do_ncv.c):

                        val = l + strspn(l, " \t");
                        l = val + strspn(val, "0123456789.");
 
I have no idea if RRD is able to accept/store negative values, but if it
is, it should be a simple case of adding the + and - characters to the
last line listed above to make what you want possible.

|\/|artin
quoted from David Stuffle

-----Original Message-----
From: David Stuffle [mailto:user-bf7eff98fdba@xymon.invalid] 
Sent: 28 July 2008 14:28
To: user-ae9b8668bcde@xymon.invalid
Subject: [hobbit] No graph for negative clock offset


Hi all,
None of my clock offset graphs graph anything when the clock offset from

a host is a negative number.  Only positive number work.  Anyone having 
the same thing happen or know how to fix?

I'm running a snapshot 4.3.0-0.20080103

Thanks
David


*************************************************************************************

The message is intended for the named addressee only and may not be disclosed to or used by anyone else, nor may it be copied in any way. 

The contents of this message and its attachments are confidential and may also be subject to legal privilege.  If you are not the named addressee and/or have received this message in error, please advise us by e-mailing user-61c7f445d564@xymon.invalid and delete the message and any attachments without retaining any copies. 

Internet communications are not secure and COLT does not accept responsibility for this message, its contents nor responsibility for any viruses. 

No contracts can be created or varied on behalf of COLT Telecommunications, its subsidiaries or affiliates ("COLT") and any other party by email Communications unless expressly agreed in writing with such other party.  

Please note that incoming emails will be automatically scanned to eliminate potential viruses and unsolicited promotional emails. For more information refer to www.colt.net or contact us on +44(0)20 7390 3900.
list Ralph Mitchell · Mon, 28 Jul 2008 10:18:21 -0500 ·
Judging by the man page, negative values are OK.  The first entry in the
EXAMPLE section of "man rrdcreate" reads:

          rrdtool create temperature.rrd --step 300 \
             DS:temp:GAUGE:600:-273:5000 \
             RRA:AVERAGE:0.5:1:1200 \
             RRA:MIN:0.5:12:2400 \
             RRA:MAX:0.5:12:2400 \
             RRA:AVERAGE:0.5:12:2400

         This sets up an RRD called temperature.rrd which accepts one
tempera-
         ture value every 300 seconds. If no new data is supplied for more
than
         600 seconds, the temperature becomes *UNKNOWN*.  The minimum
acceptable
         value is -273 and the maximum is 5'000.

Ralph Mitchell
quoted from Martin Ward


On Mon, Jul 28, 2008 at 9:24 AM, Ward, Martin <user-2d33a6eb6a05@xymon.invalid> wrote:
Funnily enough I am looking at the Hobbit code that deals with RRD data
at the moment. If you are using the NCV capabilities then it looks like
you can't have negative numbers. The generic NCV (Number, Colon, Value)
code looks for numbers only, no signs (somewhere near line 70 in
hobbitd/rrd/do_ncv.c):

                       val = l + strspn(l, " \t");
                       l = val + strspn(val, "0123456789.");

I have no idea if RRD is able to accept/store negative values, but if it
is, it should be a simple case of adding the + and - characters to the
last line listed above to make what you want possible.

|\/|artin

-----Original Message-----
From: David Stuffle [mailto:user-bf7eff98fdba@xymon.invalid]
Sent: 28 July 2008 14:28
To: user-ae9b8668bcde@xymon.invalid
Subject: [hobbit] No graph for negative clock offset


Hi all,
None of my clock offset graphs graph anything when the clock offset from

a host is a negative number.  Only positive number work.  Anyone having
the same thing happen or know how to fix?

I'm running a snapshot 4.3.0-0.20080103

Thanks
David


*************************************************************************************
The message is intended for the named addressee only and may not be
disclosed to or used by anyone else, nor may it be copied in any way.

The contents of this message and its attachments are confidential and may
also be subject to legal privilege.  If you are not the named addressee
and/or have received this message in error, please advise us by e-mailing
user-61c7f445d564@xymon.invalid and delete the message and any attachments without
retaining any copies.

Internet communications are not secure and COLT does not accept
responsibility for this message, its contents nor responsibility for any
viruses.

No contracts can be created or varied on behalf of COLT Telecommunications,
its subsidiaries or affiliates ("COLT") and any other party by email
Communications unless expressly agreed in writing with such other party.

Please note that incoming emails will be automatically scanned to eliminate
potential viruses and unsolicited promotional emails. For more information
refer to www.colt.net or contact us on +44(0)20 7390 3900.

list Martin Ward · Mon, 28 Jul 2008 17:17:06 +0100 ·
The code I referred to is the Hobbit code not the RRD stuff. Whilst RRD
may well allow negative numbers it looks like Hobbit is not coded
correctly to allow it, at least not the source code I am looking at. I
know that there is an unofficial patch for Hobbit but have no idea
whether the code I am looking at is this version or not, not if that
code has this same bug.
 
If you compiled your own Hobbit then you can follow these instructions
to modify the source:
----
Change to the Hobbit source directory.
Edit the hobbitd/rrd/do_ncv.c file.
Go to line 54, which looks like this:
                        l = val + strspn(val, "0123456789.");

Add a - after the . so it looks like this:
                        l = val + strspn(val, "0123456789.-");

Compile and install as per standard instructions.
----
 
|\/|artin
quoted from Ralph Mitchell

	-----Original Message-----
	From: Ralph Mitchell [mailto:user-00a5e44c48c0@xymon.invalid] 
	Sent: 28 July 2008 16:18
	To: user-ae9b8668bcde@xymon.invalid
	Subject: Re: [hobbit] No graph for negative clock offset
	
	
	Judging by the man page, negative values are OK.  The first
entry in the EXAMPLE section of "man rrdcreate" reads:
	
	          rrdtool create temperature.rrd --step 300 \
	             DS:temp:GAUGE:600:-273:5000 \
	             RRA:AVERAGE:0.5:1:1200 \
	             RRA:MIN:0.5:12:2400 \
	             RRA:MAX:0.5:12:2400 \
	             RRA:AVERAGE:0.5:12:2400
	
	         This sets up an RRD called temperature.rrd which
accepts one tempera-
	         ture value every 300 seconds. If no new data is
supplied for more than
	         600 seconds, the temperature becomes *UNKNOWN*.  The
minimum acceptable
	         value is -273 and the maximum is 5'000.
	
	Ralph Mitchell
	
	
	On Mon, Jul 28, 2008 at 9:24 AM, Ward, Martin
<user-2d33a6eb6a05@xymon.invalid> wrote:
	

		Funnily enough I am looking at the Hobbit code that
deals with RRD data
		at the moment. If you are using the NCV capabilities
then it looks like
		you can't have negative numbers. The generic NCV
(Number, Colon, Value)
		code looks for numbers only, no signs (somewhere near
line 70 in
		hobbitd/rrd/do_ncv.c):
		
		                       val = l + strspn(l, " \t");
		                       l = val + strspn(val,
"0123456789.");
		
		I have no idea if RRD is able to accept/store negative
values, but if it
		is, it should be a simple case of adding the + and -
characters to the
		last line listed above to make what you want possible.
		
		|\/|artin
		

		-----Original Message-----
		From: David Stuffle [mailto:user-bf7eff98fdba@xymon.invalid]
		Sent: 28 July 2008 14:28
		To: user-ae9b8668bcde@xymon.invalid
		Subject: [hobbit] No graph for negative clock offset
		
		
		Hi all,
		None of my clock offset graphs graph anything when the
clock offset from
		
		a host is a negative number.  Only positive number work.
Anyone having
		the same thing happen or know how to fix?
		
		I'm running a snapshot 4.3.0-0.20080103
		
		Thanks
		David
		
		
************************************************************************
*************
		The message is intended for the named addressee only and
may not be disclosed to or used by anyone else, nor may it be copied in
any way.
		
		The contents of this message and its attachments are
confidential and may also be subject to legal privilege.  If you are not
the named addressee and/or have received this message in error, please
advise us by e-mailing user-61c7f445d564@xymon.invalid and delete the message and any
attachments without retaining any copies.
		
		Internet communications are not secure and COLT does not
accept responsibility for this message, its contents nor responsibility
for any viruses.
		
		No contracts can be created or varied on behalf of COLT
Telecommunications, its subsidiaries or affiliates ("COLT") and any
other party by email Communications unless expressly agreed in writing
with such other party.
		
		Please note that incoming emails will be automatically
scanned to eliminate potential viruses and unsolicited promotional
emails. For more information refer to www.colt.net or contact us on
+44(0)20 7390 3900.
		

*************************************************************************************
The message is intended for the named addressee only and may not be disclosed to or used by anyone else, nor may it be copied in any way. 

The contents of this message and its attachments are confidential and may also be subject to legal privilege.  If you are not the named addressee and/or have received this message in error, please advise us by e-mailing user-61c7f445d564@xymon.invalid and delete the message and any attachments without retaining any copies. 

Internet communications are not secure and COLT does not accept responsibility for this message, its contents nor responsibility for any viruses. 

No contracts can be created or varied on behalf of COLT Telecommunications, its subsidiaries or affiliates ("COLT") and any other party by email Communications unless expressly agreed in writing with such other party.  

Please note that incoming emails will be automatically scanned to eliminate potential viruses and unsolicited promotional emails. For more information refer to www.colt.net or contact us on +44(0)20 7390 3900.