Cacti (home)ForumsRepositoryDocumentation
Cacti: offical forums and support
It is currently Fri Oct 24, 2014 11:14 pm

All times are UTC - 5 hours




Post new topic Reply to topic  [ 10 posts ] 
Author Message
 Post subject: mySNMP - SNMP-Tools for Cacti
PostPosted: Wed Feb 13, 2008 12:52 pm 
Offline

Joined: Thu Apr 05, 2007 5:33 am
Posts: 36
My first selfmade plugin!

Its a little but useful tool. i'am using it at work to get information from hundreds of routers.
maybe it is useful for you too.

----[ Requirements

Perl, Perl:DBI, Net-SNMP, Cacti >= 0.8.7

----[ Features

- Simple SNMP-GET and SNMP-WALK-Querys per Webinterface
- Host-filter for customized requests
- Export function to Exel (xls)
- Adding own ODIs to Database


please give me feedback...
regards
kyosanim


Attachments:
mySNMP.rar [35.49 KiB]
Downloaded 411 times


Last edited by kyosanim on Fri Feb 22, 2008 2:47 pm, edited 2 times in total.
Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 22, 2008 9:01 am 
Offline

Joined: Thu Apr 05, 2007 5:33 am
Posts: 36
don't be shy -
feedback would be nice ;-)


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 22, 2008 9:09 am 
Offline
Cacti Guru User
User avatar

Joined: Fri Sep 19, 2003 8:36 am
Posts: 2326
Location: Sophia-Antipolis, France
Hi

nice plugin :)

I have an error running it with Cacti 0.8.7b and plugin arch 2.0 :
Code:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/cactiuser/cacti-0.8.7b/plugins/mySNMP/mySNMP.php on line 269

when going to the "mySNMP" tab, and
Code:
Notice: Undefined index: mySNMP.php:actions in /home/cactiuser/cacti-0.8.7b/lib/functions.php on line 1634

when running a walk.

_________________

HOWTOs :
Templates :


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 22, 2008 9:21 am 
Offline
Cacti Guru User
User avatar

Joined: Fri Sep 19, 2003 8:36 am
Posts: 2326
Location: Sophia-Antipolis, France
Oops, I forgot to import database.sql :oops:

But it returns an error :
Code:
$ mysql cacti -p < database.sql
Enter password:
ERROR 1062 (23000) at line 46: Duplicate entry '0' for key 1

_________________

HOWTOs :
Templates :


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 22, 2008 10:41 am 
Offline

Joined: Thu Apr 05, 2007 5:33 am
Posts: 36
thanks for your reply...
i think i have a little mistake in the "insert"-part.

i will correct it and post a working one ;-)


---update ---
here is the fixed database-file


Attachments:
database.sql.txt [2.11 KiB]
Downloaded 315 times
Top
 Profile  
 
 Post subject:
PostPosted: Mon Feb 25, 2008 5:46 am 
Offline
Cacti Guru User
User avatar

Joined: Fri Sep 19, 2003 8:36 am
Posts: 2326
Location: Sophia-Antipolis, France
Thanks, the new .sql file imports correctly.

_________________

HOWTOs :
Templates :


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 13, 2008 6:23 am 
Offline
Cacti User

Joined: Fri Aug 18, 2006 11:22 am
Posts: 103
Location: MSK, RU
I get the follwoing error after clicking "Yes" on the page saying "To start the SNMP-Get, press the "yes" button below."


Notice: Undefined variable: version in C:\cacti\plugins\mySNMP\mySNMP.php on line 166

Warning: Cannot modify header information - headers already sent by (output started at C:\cacti\plugins\mySNMP\mySNMP.php:166) in C:\cacti\plugins\mySNMP\mySNMP.php on line 188

What could be the problem.
Cacti is 0.8.7a
Plugin Arch is 1.4


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 13, 2008 6:35 pm 
Offline

Joined: Fri Mar 17, 2006 11:12 pm
Posts: 26
fmangeant wrote:
Hi

Code:
Notice: Undefined index: mySNMP.php:actions in /home/cactiuser/cacti-0.8.7b/lib/functions.php on line 1634

when running a walk.

I'm getting this same error.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Mar 17, 2008 10:11 am 
Offline

Joined: Thu Apr 05, 2007 5:33 am
Posts: 36
on line 166 the script starts the snmp get/walk.
what snmp version does the device use?
at the moment mySNMP only supports v2c and v1.

please check if snmp version is correct and if community is set correctly.

@dave99 - i have not tested on a cacti 0.8.7b yet. i will check this out.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Apr 30, 2008 8:58 am 
Offline

Joined: Mon Sep 10, 2007 5:21 am
Posts: 23
kyosanim, would be much better, if you'll take all db-related stuff (like password, login etc) from standart include/config.php. It's not such hard, isn't it?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 10 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  

Protected by Anti-Spam ACP Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group