Home‎ > ‎unix/linux‎ > ‎Monitoring / Internet Based Tools‎ > ‎Cacti‎ > ‎Custom Monitoring‎ > ‎

Simple Script output to graph

Overview: 

This quickly goes over the steps needed to take the single output of a script and graph it over time. 

Steps: 



1. Console :: Collection Methods :: Data Input Methods :: <add>
2. Name = random-script  (the name of the input method)
3. input string = perl <path_cacti>/scripts/random2.pl  (the location of the perl script)
4. Output Fields :: <add> script does not need any arguments, but will produce one output)


5. Field Output = random_number (define the variable name for the output)
5. Friendly Name = Random Number (a description to the variable name) 
5. <save> 


6. Console :: Management :: Data Sources :: <add>  
7. <create>  


8. Name = random2ds (name for this data source)
9. Data Input Method = random-script (select from the pulldown the data-input-method: step#1)
10 Internal Data Source Name = random_number (variable name for rrd file)
11. <save> 



12. Console :: Management :: Graph Management :: <add>
12. <create> (leave two variables blank, and just select create button)
13. Title = RANDOM NUMBERS (title of the graph)
14. Vertical Label: Random Number (add a title for the graph)
15. <create>  


16. Graph Items :: <add> (create a graph item)


17. Data Source = random2ds (select name of data source, step #8)
18. Color = {something} (pick a nice color for the lines of your graph)
19. Graph Item Type = line1 (this kind of graph would look best as a line)
20. <create> 


Then you will see your graph being plotted.  


After this, add your graph to your tree under
Console :: Management :: Graph Trees  






Reference: 

Comments