General configuration of cacti
Moderators: Developers, Moderators
General configuration of cacti
Hi there,
im german so please excuse my bad english ; )
I have a big problem, searched here in the forum mit not
found the answers for a noob like me. Just little pieces.
I have a .pl file uses the randome.rrd. If i execute that,
theres just a line goes up to 300 in about 12 Hours.
I will combine that with ServerLogfiles in the future. But that doesn't
matter i think. My Problem is, to link the pl file with the
cacti frontend.
I read a lot about SNMP, 2 days later, i recognized that i don't need
that so, wasted time.
And now i want you to help me, to configure the cacti, if u don't mind.
I really have problems with this, i can't get my head around that.
All of the Data Sources an Graphic Templates, what of these thinks
are important to me in my case?
Description of my ???doings??? <- don't know if that is right
I have created a graph, i would convert it to use it afterwards for
my graphics for the logs. After that, i created a new graphic.
Uses the Template i created.
erm, now i created a Data Source. What Data Input Method should
i choose?
I thought Get Script Data can be good.
and what Data Source Type?
GAUGE? COUNTER?
After that, i converted it, as the graphic template and made a new
Data Source with the Template, works with the RRD File i typed in.
In this case randome.rrd.
That's what i have reached in one week -_- just tried again and again.
But where can i put the PL file in?
In the graph monitor there's just the description and no graphic.
I don't know what to do, I need help, please.
IMurDOOM
im german so please excuse my bad english ; )
I have a big problem, searched here in the forum mit not
found the answers for a noob like me. Just little pieces.
I have a .pl file uses the randome.rrd. If i execute that,
theres just a line goes up to 300 in about 12 Hours.
I will combine that with ServerLogfiles in the future. But that doesn't
matter i think. My Problem is, to link the pl file with the
cacti frontend.
I read a lot about SNMP, 2 days later, i recognized that i don't need
that so, wasted time.
And now i want you to help me, to configure the cacti, if u don't mind.
I really have problems with this, i can't get my head around that.
All of the Data Sources an Graphic Templates, what of these thinks
are important to me in my case?
Description of my ???doings??? <- don't know if that is right
I have created a graph, i would convert it to use it afterwards for
my graphics for the logs. After that, i created a new graphic.
Uses the Template i created.
erm, now i created a Data Source. What Data Input Method should
i choose?
I thought Get Script Data can be good.
and what Data Source Type?
GAUGE? COUNTER?
After that, i converted it, as the graphic template and made a new
Data Source with the Template, works with the RRD File i typed in.
In this case randome.rrd.
That's what i have reached in one week -_- just tried again and again.
But where can i put the PL file in?
In the graph monitor there's just the description and no graphic.
I don't know what to do, I need help, please.
IMurDOOM
Last edited by IMurDOOM on Mon Nov 07, 2005 7:40 am, edited 6 times in total.
- TheWitness
- Developer
- Posts: 17007
- Joined: Tue May 14, 2002 5:08 pm
- Location: MI, USA
- Contact:
We have several active germanic users, so you might even be able to get support in German. You need to do some reading first on RRD. Goto:
http://www.rrdtool.org
Then, you need to understand SNMP. For that I used the famous Google tool. The main commands you need to know about are:
snmpget
snmpwalk
snmpbulkwalk
You also need to know what purpose MIB files provide. They provide translation from the numeric format of an object to it's text name.
Lastly, you need to know how to configure Cacti. There is a pretty good manual right here in the cacti.net site. Good luck!!
TheWitness
http://www.rrdtool.org
Then, you need to understand SNMP. For that I used the famous Google tool. The main commands you need to know about are:
snmpget
snmpwalk
snmpbulkwalk
You also need to know what purpose MIB files provide. They provide translation from the numeric format of an object to it's text name.
Lastly, you need to know how to configure Cacti. There is a pretty good manual right here in the cacti.net site. Good luck!!
TheWitness
True understanding begins only when we realize how little we truly understand...
Life is an adventure, let yours begin with Cacti!
Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages
For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Life is an adventure, let yours begin with Cacti!
Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages
For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Thanks for your replys, both.
Joeb, i wrote you an email.
But whether i have the logs on my computer as TXT
files, why do i need the snmp?
My examples included in the RRD are working and creates
an image with a line, my problem is the visualisati9on of this
PERL script.
I will look @ that you wrote. Thanks, thanks, thanks.
I have been rescued from hell
IMurDOOM
Joeb, i wrote you an email.
But whether i have the logs on my computer as TXT
files, why do i need the snmp?
My examples included in the RRD are working and creates
an image with a line, my problem is the visualisati9on of this
PERL script.
I will look @ that you wrote. Thanks, thanks, thanks.
I have been rescued from hell
IMurDOOM
My last question for the next few hours/days ;D
I heard again that i have to use SNMP, is there a way
to leave that outside?
The Logfiles are local on myy PC. So i just have cacti
to exec the perl skript and inserting the outputs.
For example:
The Logfile has the MBytes traffic for one minute in one row.
The Perl Skript will read that and have to give it to cacti.
just isolate the Mbs first case "2" and then send it to cacti which
is on the same PC!
Cacti has to insert the infos.
No more.
And my question: Why do i have to use SNMP for this? Does cacti just
listen on the SNMP Ports and i have to send it with Perl via SNMP?
Theres no other way to reach the same result? <- Don't know if that's right ;D
Thanks for ur help again.
EDIT: I have a graphic already. That works but the Database is empty.
So, we solved the problem with the graphics. And i have read the html
doc as well.
IMurDOOM
I heard again that i have to use SNMP, is there a way
to leave that outside?
The Logfiles are local on myy PC. So i just have cacti
to exec the perl skript and inserting the outputs.
For example:
The Logfile has the MBytes traffic for one minute in one row.
Code: Select all
12:01 2 Mb
12:02 0 Mb
12:03 1,5 Mb
just isolate the Mbs first case "2" and then send it to cacti which
is on the same PC!
Cacti has to insert the infos.
No more.
And my question: Why do i have to use SNMP for this? Does cacti just
listen on the SNMP Ports and i have to send it with Perl via SNMP?
Theres no other way to reach the same result? <- Don't know if that's right ;D
Thanks for ur help again.
EDIT: I have a graphic already. That works but the Database is empty.
So, we solved the problem with the graphics. And i have read the html
doc as well.
IMurDOOM
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
As long as you're only reading data from your local host, there's no need for snmp. But when it comes to read data from a remote host, you have to introduce some "transport method" for the readings. Networkers usually take SNMP, as this already provides lots of data. For custom scripts, you may as well use http, telnet, ssh but you have to do some coding.IMurDOOM wrote:I heard again that i have to use SNMP, is there a way
to leave that outside?
To parse your log, you'll have to have some script (sh/perl/php or the like) that simply prints your value, see http://www.cacti.net/downloads/docs/htm ... thods.html for details. It is possible to print not only a single value.
You'll define a Data Input Method that relates to that script (e.g. provides input/output parms). Then a Data Template is needed, that one will define string the data in rrd files. Last, a Graph Template will define the properties of the graph for your data. You'll find all of this in the docs (see link).
Reinhard
Yeah thanks a lot,
i was right with no need of SNMP that makes me happy because
i tried 2 days with that and it won't work ^^
The data will be transfered over FTP or sth like that.
The first problem is not the transport of the logfile, but, as i said, the
filling of the databse because i dont get along with the arguments
given from the script to cacti.
I read that, and for a noob who never saw sth like this program
before its a torture. Normaly i wrote my programs for myself and
know how to use them ;D
In my input method there is the input string:
/home/IMurDOOM/sources/my.pl <variable1>
the my.pl:
that is nearly that, described in the manuel. Or that way, i understood that.
Hope that is right.
Last thing to config are the input fields and output fields. I confed them
with the help.
But there must be an error somewhere. The DB is empty
IMurDOOM
i was right with no need of SNMP that makes me happy because
i tried 2 days with that and it won't work ^^
The data will be transfered over FTP or sth like that.
The first problem is not the transport of the logfile, but, as i said, the
filling of the databse because i dont get along with the arguments
given from the script to cacti.
I read that, and for a noob who never saw sth like this program
before its a torture. Normaly i wrote my programs for myself and
know how to use them ;D
In my input method there is the input string:
/home/IMurDOOM/sources/my.pl <variable1>
the my.pl:
Code: Select all
#!usr/bin/perl
print "variable1: "+rand(100);
Hope that is right.
Last thing to config are the input fields and output fields. I confed them
with the help.
But there must be an error somewhere. The DB is empty
IMurDOOM
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
Well, for this time this may be well done. But if you want to get data every 5 Minutes, ftp-ing them sounds a bit ugly for me. Review the features of net-snmp (pass or exec option), but not yet.IMurDOOM wrote:Yeah thanks a lot,
i was right with no need of SNMP that makes me happy because
i tried 2 days with that and it won't work ^^
The data will be transfered over FTP or sth like that.
Well done, so far. <variable1> seems to be an output var, no input var present. Am I right? Well, and a mistake is in there: Please NO blanks between variable name and value!In my input method there is the input string:
/home/IMurDOOM/sources/my.pl <variable1>
the my.pl:Code: Select all
#!usr/bin/perl print "variable1: "+rand(100);
Please post a screenshot of your Data Input Method or describe what you did to build this.But there must be an error somewhere. The DB is empty
We'll get it, for sure!
Reinhard
Thanks thank,
My Data Input Method:
Name: Data Input Method Template
Input Type: Script/Command
Input String: /root/Desktop/sources/my.pl <var1>
(The root mode will be changed if i install it on another PC)
Input Variables:
Name: var1
Field order: 1
Friendly Name: Input_Script_Data
No Regular expression math
Allow Empty Input = false
Special Type Code = nothing
Output fields
Field [Output]: var1
Friendly Name: Output_Script_Data
Update RRD File: False
Hope that helps you
IMurDOOM
My Data Input Method:
Name: Data Input Method Template
Input Type: Script/Command
Input String: /root/Desktop/sources/my.pl <var1>
(The root mode will be changed if i install it on another PC)
Input Variables:
Name: var1
Field order: 1
Friendly Name: Input_Script_Data
No Regular expression math
Allow Empty Input = false
Special Type Code = nothing
Output fields
Field [Output]: var1
Friendly Name: Output_Script_Data
Update RRD File: False
Hope that helps you
IMurDOOM
here i am again, i have just read this example:
http://www.cacti.net/downloads/docs/htm ... graph.html
It describes that, what i want to do.
I works BUT (^^) rrd says, the rrdfile in my case localhost_random_numbers.rrd or sth like that does not exist.
How can i use cacti to create this rrd? I heard that cacti can do this.
After that, it should work. I can't use another rrd file, theres just
a text sayin permissions denied.
IMurDOOM
http://www.cacti.net/downloads/docs/htm ... graph.html
It describes that, what i want to do.
I works BUT (^^) rrd says, the rrdfile in my case localhost_random_numbers.rrd or sth like that does not exist.
How can i use cacti to create this rrd? I heard that cacti can do this.
After that, it should work. I can't use another rrd file, theres just
a text sayin permissions denied.
IMurDOOM
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
I'd like to give the output var not the same name as the input var. Don't know whether this works with cacti; just for clarity.
As to the permissions: You did modify the crontab to implement the 5 min polling using a special "cactiuser". Did you change the ownership of <path_cacti>/log and ./rra/ to this user as described in the installation steps?
To verify this one, please "su - cactiuser" and run the poller from here: "php /some/path/to/cacti/poller.php". Look for permission errors.
Reinhard
As to the permissions: You did modify the crontab to implement the 5 min polling using a special "cactiuser". Did you change the ownership of <path_cacti>/log and ./rra/ to this user as described in the installation steps?
To verify this one, please "su - cactiuser" and run the poller from here: "php /some/path/to/cacti/poller.php". Look for permission errors.
Reinhard
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
There is a Downed Host Detection. If that fails, cacti will not even try to get values from that host. Activate DEBUG logging level and have a look at <path_cacti>/log/cacti.log for that error. You will even see the cacti poller executing your script, if and only if Host Detection shows the host is up! And you will see the value fetched from that script as well as the rrdtool update.
To deactive Host Detection, please clear the SNMP Community String for that very host (see Device for that).
Reinhard
To deactive Host Detection, please clear the SNMP Community String for that very host (see Device for that).
Reinhard
Who is online
Users browsing this forum: takeatr1p and 0 guests