Cacti (home)ForumsRepositoryDocumentation
Cacti: offical forums and support  

 FAQFAQ   SearchSearch   MemberlistMemberlist    RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in    


BIND 9 Statistics for Cacti
Goto page Previous  1, 2, 3 ... 9, 10, 11, 12  Next
 
Post new topic   Reply to topic    Cacti Forum Index -> Scripts and Templates
Author Message
Maillon



Joined: 04 Jul 2007
Posts: 16
Location: Paris

PostPosted: Thu Jul 19, 2007 4:52 am    Post subject: Reply with quote

Hi Rossco ^^


About the associated graph query i believe why i had something : in fact i had created a new "Host Template" and i had associated the "Bind SNMP Request" and this graph (see the screen shot)

http://img223.imageshack.us/img223/5343/cactihosttemplateia4.jpg

Now i have deleted the "associated graph templates".

When i'm going to "Collection Methods" -> "Data Input Methods" -> "Bind9 SNMP Request" (i have created it) i have :

http://img408.imageshack.us/img408/5212/cactidatainputmethodpf7.jpg


In fact when i launch this command i have this :

Code:

poseidon:/data/www/cacti# php poller.php |grep cerbere

07/19/2007 11:25:56 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_proc_1064.rrd --template proc 1184837145:74
07/19/2007 11:25:56 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_traffic_in_1065.rrd --template traffic_in:traffic_out 1184837145:352990849:4185376659
07/19/2007 11:25:59 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_mem_buffers_1057.rrd --template mem_buffers 1184837158:3492
07/19/2007 11:25:59 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_mem_swap_1058.rrd --template mem_swap 1184837158:539380
07/19/2007 11:25:59 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_cpu_nice_1059.rrd --template cpu_nice 1184837158:17562
07/19/2007 11:26:00 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_cpu_system_1060.rrd --template cpu_system 1184837158:3173018
07/19/2007 11:26:00 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_cpu_user_1061.rrd --template cpu_user 1184837158:2199267
07/19/2007 11:26:00 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_load_1min_1062.rrd --template load_1min:load_5min:load_15min 1184837158:1.21:0.41:0.19
07/19/2007 11:26:00 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_users_1063.rrd --template users 1184837158:1
07/19/2007 11:26:00 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_proc_1064.rrd --template proc 1184837158:72
07/19/2007 11:26:00 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /data/www/cacti/rra/cerbere_traffic_in_1065.rrd --template traffic_in:traffic_out 1184837158:352997568:4185382647



I don't have my .rrd file (it's normally cerbere_snmp_ ...). So the poller doesn't work with the new host... but why ?
Where the poller see to create or update his .rrd file ?


And when i going to "System"->"System Utilities"->"Rebuild poller cache" i don't have my host.

http://img256.imageshack.us/img256/6671/cactipollercachemu2.jpg


This can help you ?

PS : when I check /var/log/apache2/error.log getting :
ERROR: opening '/data/www/cacti/rra/cerbere_snmp_referral_1120.rrd': No such file or directory


Thank you.
Back to top
Maillon



Joined: 04 Jul 2007
Posts: 16
Location: Paris

PostPosted: Thu Jul 19, 2007 7:46 am    Post subject: Reply with quote

Hi Rossco ^^,

So i progress ^^

I have launched /data/www/cacti/rebuild_poller.cache.php and now when i going to "System"->"System Utilities"->"Rebuild poller cache" i have :

http://img225.imageshack.us/img225/9136/cactipollercachecompletvr0.jpg

And I have graphs but it looks like that :

http://img341.imageshack.us/img341/9619/cactigraphnannm3.jpg

In my cacti log on website i have lines seems that :

Code:

 07/19/2007 02:53:17 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "delete from poller_output where local_data_id='1121' and rrd_name='success' and time='2007-07-19 14:53:14'"
07/19/2007 02:53:17 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "delete from poller_output where local_data_id='1121' and rrd_name='referral' and time='2007-07-19 14:53:14'"
07/19/2007 02:53:17 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "delete from poller_output where local_data_id='1121' and rrd_name='recursion' and time='2007-07-19 14:53:14'"
07/19/2007 02:53:17 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "delete from poller_output where local_data_id='1121' and rrd_name='nxrrset' and time='2007-07-19 14:53:14'"
07/19/2007 02:53:17 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "delete from poller_output where local_data_id='1121' and rrd_name='nxdomain' and time='2007-07-19 14:53:14'"
07/19/2007 02:53:17 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "delete from poller_output where local_data_id='1121' and rrd_name='failure' and time='2007-07-19 14:53:14'"



It's normal that which are a "Delete" ? If yes, i understand why in my graphs i have "NAN" but why poller delete it ?

This can help you ?

Thank you
Back to top
Maillon



Joined: 04 Jul 2007
Posts: 16
Location: Paris

PostPosted: Thu Jul 19, 2007 8:39 am    Post subject: Reply with quote

Hi All ^^,

So apparently my graphs are working I have value. I don't know why i had "nan" value and after few minutes i had true values.... Do you know when the value "nan" become a numeric value ??

Thank you very very much Rossco and Gandalf ^^
Back to top
Rossco
Cacti User


Joined: 15 Jan 2005
Posts: 72
Location: London, England

PostPosted: Thu Jul 19, 2007 9:06 am    Post subject: Reply with quote

Hi Maillon

Apologies for not replying sooner, work has been a nightmare today.

I'm very glad to see you've gotten it working. In answer to your nan question, I believe it usually takes two full poller cycles to go from nan to meaningful results, although it depends on whether the snmp value you are querying is a gauge or a counter.

Anyhows, well done on fixing

Rossco
Back to top
Rossco
Cacti User


Joined: 15 Jan 2005
Posts: 72
Location: London, England

PostPosted: Thu Jul 19, 2007 12:03 pm    Post subject: Reply with quote

Hi Gaansch/Tarpat.

Apologies for not replying sooner.

Could both of you confirm that your snmpd daemon accounts have the correct permissions for the .pl script? I'm not an expert on file system perms, but a chmod 777 /my/path/bind9-stats-snmpd.pl may help (tighten them afterwards, if you need to).

I'm presuming they already have execute permission as you've both run them.

cheers

Rossco
Back to top
gaansch



Joined: 18 Jul 2007
Posts: 7

PostPosted: Thu Jul 19, 2007 1:10 pm    Post subject: Reply with quote

Hi Rpssco,

Rossco wrote:

Could both of you confirm that your snmpd daemon accounts have the correct permissions for the .pl script? I'm not an expert on file system perms, but a chmod 777 /my/path/bind9-stats-snmpd.pl may help (tighten them afterwards, if you need to).


chmod 755 should work but 777 doesn't work eather. It doesn't seem to be the problem.

The funny thing is, on another Debian Etch server with all the same software versions, but with a different script the pass command works fine.

Sebastian
Back to top
Rossco
Cacti User


Joined: 15 Jan 2005
Posts: 72
Location: London, England

PostPosted: Thu Jul 19, 2007 1:45 pm    Post subject: Reply with quote

Hi Gaansch

Yup, 755 may well work, as I said, I'm not an expert on the file perms, I just tinker

This really is bizarre. Not sure if I asked this before, but are you running snmpwalk locally or remotely? Maybe you have setup some snmp permissions in the config files?

Alternatively, how about we ignore the DNS script for the moment. If you replace the snmpd config line with something like (not tested, but sure I did something similar before):

"pass .1.3.6.1.4.1.2021.55 /usr/bin/logger SNMPD Script Called!"
or
"exec .1.3.6.1.4.1.2021.55 /usr/bin/logger SNMPD Script Called!"

Do you get any lines in your syslog? Obviously the snmpwalk will timeout, but the initial execution should have happened. You will need to restart the snmpd daemon when you do this.

If even that doesnt work, then perhaps you have multiple copies of the snmpd.conf on your system and snmpd is reading a different one?

Sorry, you can tell I'm running out of good ideas now...

Cheers

Rossco
Back to top
Maillon



Joined: 04 Jul 2007
Posts: 16
Location: Paris

PostPosted: Fri Jul 20, 2007 2:48 am    Post subject: Reply with quote

Hi Gaansch ^^,

Have you verify owner file ? And change if necessary with the command chown ?
Back to top
gaansch



Joined: 18 Jul 2007
Posts: 7

PostPosted: Fri Jul 20, 2007 3:36 am    Post subject: Reply with quote

Hi,

the owner of the file is snmp. The snmp daemon also runs as user snmp.

Code:

-rwxrwxrwx  1 snmp staff 7364 2007-07-19 09:35 bind9-stats-snmpd.pl


The Problem is, the pass command won't execute other files eather. For example: /usr/bin/touch or /usr/bin/logger.

Sebastian
Back to top
Rossco
Cacti User


Joined: 15 Jan 2005
Posts: 72
Location: London, England

PostPosted: Fri Jul 20, 2007 3:54 am    Post subject: Reply with quote

Hi Gaansch

Is it worthwhile confirming the snmpd service is definitely reading *this* file? Maybe stick some junk in your snmpd.conf and restart the service. It should either fail to start or complain loudly, indicating whether it is definitely reading the file?

Cheers

Rossco
Back to top
gaansch



Joined: 18 Jul 2007
Posts: 7

PostPosted: Fri Jul 20, 2007 4:02 am    Post subject: Reply with quote

Hi,

okay, I've put the following line into /etc/snmp/snmpd.conf and the snmpd hasn't complained but started.

Code:

asdfasdf asdf asdaf sddsf adfasdfa


Sebastian
Back to top
Rossco
Cacti User


Joined: 15 Jan 2005
Posts: 72
Location: London, England

PostPosted: Fri Jul 20, 2007 5:04 am    Post subject: Reply with quote

Hi Gaansch

Check your snmpd.log

I get the following in mine:

Quote:

/usr/local/share/snmp/snmpd.conf: line 23: Error: Blank line following sdfsdfsdfsdfsadfdsfdfds token.
net-snmp: 1 error(s) in config file(s)
NET-SNMP version 5.3.1


Cheers

Rossco
Back to top
gaansch



Joined: 18 Jul 2007
Posts: 7

PostPosted: Fri Jul 20, 2007 5:23 am    Post subject: Reply with quote

Hi Rossco,

Code:

Jul 20 11:01:06 lena snmpd[19660]: /etc/snmp/snmpd.conf: line 7: Warning: Unknown token: asdfasdf.
Jul 20 11:01:06 lena snmpd[19660]: NET-SNMP version 5.2.3


it seems to be the config file, which is used

okay, now we know, snmp is using the right config file, what's been clear for me, because the disk and processes I'm monitoring are working fine.

Sebastian
Back to top
Rossco
Cacti User


Joined: 15 Jan 2005
Posts: 72
Location: London, England

PostPosted: Mon Jul 23, 2007 7:59 am    Post subject: Reply with quote

Hi Gaansch

Sorry, I'm out of ideas at this point. Maybe running smnpd in debug mode may help give you some insight?

Good luck.

Cheers

Rossco
Back to top
chris.rolves
Cacti User


Joined: 01 Mar 2006
Posts: 52

PostPosted: Thu Apr 03, 2008 5:39 pm    Post subject: Reply with quote

I got this script to work via SNMP to my DNS servers with no issues per say. It was getting info and cacti started populating graphs but then the next Day i reallized that it was no longer working and i was getting gaps on all my graphs on cacti. I checked into it and found that it was timing out getting the info via snmp from the name servers. Any ideas as to why this would be. I do know when I have graphing enabled the name server's cpu times go from .02, 015, 031 up to 1.57, 1.68, 1.07
Back to top
Display posts from previous:   
Post new topic   Reply to topic    Cacti Forum Index -> Scripts and Templates All times are GMT - 5 Hours
Goto page Previous  1, 2, 3 ... 9, 10, 11, 12  Next
Page 10 of 12

 



Powered by phpBB © 2001, 2005 phpBB Group