2

I'm currently looking at my Nagios metrics, and especially on my WebServers and I suddently noticed that sometimes, I've a negative amount of Request per second and other metrics, how it is possible??

I though that Request per second or Connection per second could only be positive or equal zero.

What's going on there? Is that negative value mean that the webserver reuse an existing connection throught keepalive or use cache data?

If someone could explain me those metrics, it would be great.

Negative requests Oo

Dr I
  • 955
  • 17
  • 33

1 Answers1

1

Non constant time? Assuming the clock moves backward (can happen with espcialyl virtual hosts) and a crappy programming this could mean a negative time slice. SImple maths.... positive divided by negative is negative.

TomTom
  • 51,649
  • 7
  • 54
  • 136
  • I'm using NTP Protocol through Chronyd service and it working perfectly, so I don't think it's a clock related issue, plus I already those kind of graph with negative rate over the internet, just don't understand what it mean ^^ Thanks for your help! – Dr I Oct 08 '13 at 10:07
  • 1
    NTP can correct the clock negative, you know. Unless you run super high speed correction (which I do on some machines, 100 corrections per second, freezing the clock where needed) it MAY move negative. – TomTom Oct 08 '13 at 10:38
  • ow, yeah, I understand what you mean. I didn't know that a clock could have a negative value Oo, I mean, physically and mathematically (except certain highly improbable circumstances) time is always incrementing isn't it? – Dr I Oct 08 '13 at 14:56
  • 1
    Except when the clock runs too fast and the NNTP daemon turns it back to the real time. Then if a program makes timestamp differences the next timestamp can be before the last one ;) – TomTom Oct 08 '13 at 20:27
  • Hell yeah, you're right, I didn't thought about this kind of situation, I just enabled the Precision Time Protocol option to see if its most relevant and just check the HW clock of the server to be sure nothing weird coming from it. – Dr I Oct 09 '13 at 09:17
  • Yeah. Expeciall on a virtual platform the clock is REALLY unstable, depending on processor and technology. I have some software adjusting the clock more than 40 times per second (based on incoming packets carrying financial data) and man, on a VM I get a warning about clock skew every second in the event logs ;) On non-virtual you still have a LOT of correction - the clocks are not exactly high quality / priority. Any wearable digitl clock would b quite ashamed.... but then it would not have time sync ;) – TomTom Oct 09 '13 at 09:37