Hi Steve

Thanks for getting back to me. That command doesn't work for me, (as I'm a 
Windows user) even using Windows Powershell.

PS F:\apache2\htdocs\cacti\rra> ls pavfr2-s200-*_traffic_*_*.rrd | xargs -I '{}'
 rrdtool tune {} --maximum traffic_in:1000000000 --maximum traffic_out:100000000
0
The term 'xargs' is not recognized as the name of a cmdlet, function, script fi
le, or operable program. Check the spelling of the name, or if a path was inclu
ded, verify that the path is correct and try again.
At line:1 char:41
+ ls pavfr2-s200-*_traffic_*_*.rrd | xargs <<<<  -I '{}' rrdtool tune {} --maxi
mum traffic_in:1000000000 --maximum traffic_out:1000000000
    + CategoryInfo          : ObjectNotFound: (xargs:String) [], CommandNotFou
   ndException
    + FullyQualifiedErrorId : CommandNotFoundException


It has given me food for thought and I will be working with one of our server 
team members to try and do what I want using the FOR command. I'll post if I 
have any success so others can benefit, unless you know a way using Windows.

Cheers

Jamie

From: Steve Shipway [mailto:[email protected]]
Sent: 03 November 2010 03:44
To: Jamie Bedford; '[email protected]'
Subject: RE: Update multiple .rrd files

The rrdtool tune command doesn't take multiple rrd files as arguments.

However, what's wrong with something like this:

ls pavfr2-s200-*_traffic_*_*.rrd | xargs -I '{}' rrdtool tune {} --maximum 
traffic_in:1000000000 --maximum traffic_out:1000000000

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: [email protected]<mailto:[email protected]>
P Please consider the environment before printing this e-mail


From: [email protected] 
[mailto:[email protected]] On Behalf 
Of Jamie Bedford
Sent: Tuesday, 2 November 2010 11:27 p.m.
To: '[email protected]'
Subject: [rrd-users] Update multiple .rrd files

Hi

This is my first post to the forum.

I want to know if its possible to update multiple .rrd files at once. I want to 
be able to change the maximum ds value in all traffic rrd files

I have tried using the following syntax

rrdtool tune pavfr2-s200-*_traffic_*_*.rrd --maximum traffic_in:1000000000 
--maximum traffic_out:1000000000

rrdtool tune pavfr2*_traffic*.rrd --maximum traffic_in:1000000000 --maximum 
traffic_out:1000000000

and combinations of the above.

It just doesn't seem to work.

F:\apache2\htdocs\cacti\rra>rrdtool info pavfr2-s200-1_traffic_in_765.rrd
filename = "pavfr2-s200-1_traffic_in_765.rrd"
rrd_version = "0003"
step = 60
last_update = 1288109947
ds[traffic_in].type = "COUNTER"
ds[traffic_in].minimal_heartbeat = 120
ds[traffic_in].min = 0.0000000000e+000
ds[traffic_in].max = NaN
ds[traffic_in].last_ds = "590039818712"
ds[traffic_in].value = 6.6679704918e+004
ds[traffic_in].unknown_sec = 0
ds[traffic_out].type = "COUNTER"
ds[traffic_out].minimal_heartbeat = 120

I would like to be able to update the files in blocks by using a portion of the 
hostname and the word traffic. I'm a bit wary about updating all rrd files with 
the word traffic in

The reason I want to do this is because I have just changed the max ds value in 
my interface traffic data templates. This is because I have been seeing some 
massive spikes in my graphs. I have used spikekill to remove these spikes. Now 
I need to update rrd files so I don't get these Petabyte spikes again.

I'm using RRDTool 1.2.30 on a Windows server running Cacti. I posted this issue 
on the Cacti forums but they directed me here as it's a more to do with rrdtool 
than Cacti.

I'm not a script expert :o(

Cheers

Jamie
Jamie Bedford
Computershare
Data Comminucations Engineer - Technology Services
[email protected]




Computershare Technology Services (UK) Limited is registered in England & Wales 
Company No. 3199675. Registered Office: The Pavilions, Bridgwater Road, Bristol 
BS13 8AE



Please visit the following website to read the Computershare legal notice: 
http://www.computershare.com/disclaimer/emea



Computershare Technology Services (UK) Limited is registered in England & Wales 
Company No. 3199675. Registered Office: The Pavilions, Bridgwater Road, Bristol 
BS13 8AE

Please visit the following website to read the Computershare legal notice: 
http://www.computershare.com/disclaimer/emea

_______________________________________________
rrd-users mailing list
[email protected]
https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users

Reply via email to