Martin Sperl | 10 Aug 2011 14:40

rrdcached client and unnecessary lstat syscalls

Hi!

I have made one observation when using rrdtool to update some rrdfiles 
that are updated via rrdcached in my C-Programm.

For an update that essentially would look like this on the command-line:
rrdtool update --daemon /socket \
   /home/msperl/xymon-4.3.4/testdata/servername/ifstat-lo/lo.rrd\
1312899067:5453845452:5372645:0:0:0:0:0:0:5453845452:5372645:0:0:0:0:0

I get an strace output of:
04:42:26.968621 read(3, "0 errors, enqueued 1 value(s).\n", 4096) = 31
04:42:26.968704 lstat("/home", {st_mode=S_IFDIR|0755, st_size=16384, 
...}) = 0
04:42:26.968755 lstat("/home/msperl", {st_mode=S_IFDIR|0755, 
st_size=4096, ...}) = 0
04:42:26.968805 lstat("/home/msperl/xymon-4.3.4", {st_mode=S_IFDIR|0755, 
st_size=4096, ...}) = 0
04:42:26.968857 lstat("/home/msperl/xymon-4.3.4/testdata", 
{st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
04:42:26.968910 lstat("/home/msperl/xymon-4.3.4/testdata/servername", 
{st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
04:42:26.968967 
lstat("/home/msperl/xymon-4.3.4/testdata/servername/ifstat-lo", 
{st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
04:42:26.969027 
lstat("/home/msperl/xymon-4.3.4/testdata/servername/ifstat-lo/lo.rrd", 
{st_mode=S_IFREG|0644, st_size=5755424, ...}) = 0
04:42:26.969092 write(3, "update 
/home/msperl/xymon-4.3.4/testdata/servername/ifstat-lo/lo.rrd 
(Continue reading)

Tobias Oetiker | 15 Aug 2011 00:42
Picon
Gravatar

regarding rrdcached

comments ?

From: rrdtool-fb5e9517 <at> hashmail.org
To: tobi <at> oetiker.ch
Date: Sun, 14 Aug 2011 19:49:59 +0200
X-Spam-Status: No, score=0.0 required=5.0 tests=BAYES_50 autolearn=ham
    version=3.2.4
Subject: regarding rrdcached

good day, sir.

so, i got tired of rrdcached corrupting my rrd files.
and fixing threading race conditions was not on my plan for this sunday.
this leads to cranky.

so, i have to warn you, there is angry ranting in the rest of this mail.
if you dont want to read me being cranky, just look at the patch. :P

two separate issues.
context is using rrdcache under nagiosgrapher.

1. "concurrent flushes". 'nuf said.
nagios grapher issues a flush for each loaded graph.
which means short bursts of 5 flush commands for the same rrd every time a page is loaded.
now combine that with an insanely high update rate on the same rrd.

lets say the first flush finds 10000 outstanding values to be written for the rrd.
the second flush arrives before the first is completed easily. but there are already new outstanding
values for the rrd.
it actualy arrives sometimes before the first one even really went off the ground, probably was still
(Continue reading)

Steve Shipway | 15 Aug 2011 03:31
Picon
Picon
Favicon

Re: regarding rrdcached

Anything that decreases data corruption must be a good thing

Though probably the error messages would need to be standardised before it gets into production:

+        RRDD_LOG (LOG_ERR, "handle_request_update: "
+            "YO DAWG, I HER ... something went wrong (%s)",
+            ci->file);
...
+        RRDD_LOG (LOG_ERR, "handle_request_update: "
+            "YO DAWG, I HERD U LIEK DISCARDING DATA (%s)",
+            ci->file);

Should the second case produce an 'err' message, though?  Since no data will actually be lost, maybe this
should be a LOG_INFO or LOG_WARN instead?

Steve

Steve Shipway
ITS Unix Services Design Lead
University of Auckland, New Zealand
Floor 1, 58 Symonds Street, Auckland
Phone: +64 (0)9 3737599 ext 86487
DDI: +64 (0)9 924 6487
Mobile: +64 (0)21 753 189
Email: s.shipway <at> auckland.ac.nz
 Please consider the environment before printing this e-mail 

Attachment (smime.p7s): application/x-pkcs7-signature, 4928 bytes
(Continue reading)

chetan | 19 Aug 2011 14:09
Picon

why dll are included to rrdtools installation

Why dll are included to rrdtools installation in window ?
Can we use these dll in the projects of c ?
if yes then ho ?

thanks...

--
View this message in context: http://rrd-mailinglists.937164.n2.nabble.com/why-dll-are-included-to-rrdtools-installation-tp6702932p6702932.html
Sent from the RRDtool Developers Mailinglist mailing list archive at Nabble.com.

Gmane