Hi Emily,<br><br>you should reply to the list :)<br>a lot of nice people subscribed to it and it's a good chance somebody would help you out.<br><br>take a look at this class,<br><a href="http://www.goldb.org/rrdpython.html">http://www.goldb.org/rrdpython.html</a><br>
it implements calling rrdtool as shell executable.<br><br>i would suggest that you strip everything unnecessary like creating a rrd <br><i>(which you can do using the binary rrdtool <create>, and following one example @ rrdtool website - data transferred on a network interface or any example that suits you) <br>
</i>and focus on understanding the update process.<br><br>further on you can try installing any of the following rrdtool modules available to python:<br><br><a href="http://www.nongnu.org/py-rrdtool/">http://www.nongnu.org/py-rrdtool/</a><br>
<a href="http://code.google.com/p/rrdpy/">http://code.google.com/p/rrdpy/</a> (it's the same author for the class in the first link, <a href="http://goldb.org">goldb.org</a>)<br><a href="http://coreygoldberg.blogspot.com/2008/05/python-rrdpy-round-robin-databases.html">http://coreygoldberg.blogspot.com/2008/05/python-rrdpy-round-robin-databases.html</a><br>
<br>Have fun.<br><br><div class="gmail_quote">On Fri, Jun 6, 2008 at 5:13 PM, Emily Chouinard <<a href="mailto:cousin17@msu.edu">cousin17@msu.edu</a>> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Yeah it just seems that the downloads.rrd was missing, I though the example on the website was a real one you could try and do yourself but now I realize it wasn't, silly me. I am still looking for an example of python-rrdtool. I would like it if someone would let me see a piece of python code where they used rrdtool, because as I said before I am a beginner and I'm trying to get this all figured out but I learn better through example. Thanks for all your help!!!<br>
<br>
Marius Rugan wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="Ih2E3d">
Hi Emily,<br>
<br>
Please let us know what you are trying to achieve and how your code snippet looks like.<br>
<br>
On the error:<br>
obviously, the script cannot find the rrd database file.<br>
I would suggest that you play around with rrdtool in its binary form, e.g. rrdtool create, rrdtool update, rrdtool graph<br>
and than start porting the command line switches to the python script.<br>
Copy paste code doesn't actually work unless you understand every switch's meaning ( for example '--imgformat', 'PNG' )<br>
and replace variables accordingly to your environment (path for example)<br>
<br>
<br></div><div><div></div><div class="Wj3C7c">
On Thu, Jun 5, 2008 at 10:53 PM, Emily Chouinard <<a href="mailto:cousin17@msu.edu" target="_blank">cousin17@msu.edu</a> <mailto:<a href="mailto:cousin17@msu.edu" target="_blank">cousin17@msu.edu</a>>> wrote:<br>
<br>
I am a newbie and I am having difficulty running the example on<br>
python-<br>
rrdtool. I have followed it word for word off the website<br>
>>> rrdtool.graph(path,<br>
'--imgformat', 'PNG',<br>
'--width', '540',<br>
'--height', '100',<br>
'--start', "-%i" % YEAR,<br>
'--end', "-1",<br>
'--vertical-label','Downloads/Day',<br>
'--title', 'Annual Downloads',<br>
'--lower-limit', '0',<br>
DEF:downloads=downloads.rrd:downloads:AVERAGE',<br>
'AREA:downloads#990033:Downloads')<br>
<br>
and getting getting this error<br>
<br>
Traceback (most recent call last): File "<stdin>", line 1, in ?<br>
rrdtool.error: opening 'downloads.rrd': No such file or directory<br>
<br>
I'm just lost and confused and really need a step by step. I'm a very<br>
green programmer so if anyone can guide me towards tutorials and what<br>
not I would really appreciate it because I need more information that<br>
what I can find on the RRDtool website but I haven't been able to find<br>
any.<br>
<br>
Thanks, Emily<br>
<br>
<br>
_______________________________________________<br>
rrd-users mailing list<br></div></div>
<a href="mailto:rrd-users@lists.oetiker.ch" target="_blank">rrd-users@lists.oetiker.ch</a> <mailto:<a href="mailto:rrd-users@lists.oetiker.ch" target="_blank">rrd-users@lists.oetiker.ch</a>><div class="Ih2E3d">
<br>
<a href="https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users" target="_blank">https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users</a><br>
<br>
<br></div>
------------------------------------------------------------------------<div class="Ih2E3d"><br>
<br>
_______________________________________________<br>
rrd-users mailing list<br>
<a href="mailto:rrd-users@lists.oetiker.ch" target="_blank">rrd-users@lists.oetiker.ch</a><br>
<a href="https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users" target="_blank">https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users</a><br>
<br>
</div></blockquote>
<br>
<br>
<br>
</blockquote></div><br>