On Sat, Jan 15, 2011 at 01:51:49PM +0100, Tobias Oetiker wrote:
> I think I found the issue ...
>
> try this:
>
> Index: rrd_resize.c
> ===================================================================
> --- rrd_resize.c (revision 2168)
> +++ rrd_resize.c (working copy)
> @@ -161,6 +161,12 @@
> default:
> rrd_set_error("Do not know how to handle RRD version %s",
> rrdold.stat_head->version);
> +
> + rrdnew.ds_def = NULL;
> + rrdnew.live_head = NULL;
> + rrdnew.pdp_prep = NULL;
> + rrdnew.cdp_prep = NULL;
> +
> rrd_free(&rrdnew);
> rrd_free(&rrdold);
> rrd_close(rrd_file);
> @@ -282,6 +288,12 @@
> rrd_close(rrd_file);
> rrd_close(rrd_out_file);
> rrd_free(&rrdold);
> +
> + rrdnew.ds_def = NULL;
> + rrdnew.live_head = NULL;
> + rrdnew.pdp_prep = NULL;
> + rrdnew.cdp_prep = NULL;
> +
> rrd_free(&rrdnew);
> return (0);
> }
>
As far I can see, this is already implemented in 2170.
With mmap disabled the error is gone,
but with mmap I still get:
noc@lowrider:~$ /opt/rrdtool-1.4.5.002170/bin/rrdtool create tester.rrd
DS:inet:GAUGE:600:0:U RRA:AVERAGE:0.5:1:600
noc@lowrider:~$ /opt/rrdtool-1.4.5.002170/bin/rrdtool resize tester.rrd 0 GROW
100
ERROR: attempting to write beyond end of file
noc@lowrider:~$
Stefan
_______________________________________________
rrd-users mailing list
[email protected]
https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users