CaMM (Cacti Message Management) plugin v1.6.7 2010-08-26

General discussion about Plugins for Cacti

Moderators: Developers, Moderators

Post Reply
User avatar
gthe
Cacti User
Posts: 410
Joined: Sat Jul 29, 2006 1:23 pm
Location: RU

Post by gthe »

mcutting wrote: Yes, I know :)

However, after around 2-3 days, these settings are discarded ny JSON, and you need to set it again :(
These settings are stored in cookies. I have them stored for months. Perhaps someone / something to clean your cookies?

sini wrote: So i really like to see event filters (on new tab for example) and a corresponding narrower event list views which shows maching events.
If I understand you correctly, it is already implemented (perhaps just not fully). For example, I want to have quick access to all the events on the successful login to the switches. This necessary:
1. Create a rule that would explicitly select the required messages and this rule should add a mark to these reports - see camm_marker_0.png.
2. In settings tabs of camm set parameter [2. camm General settings] - [Create tree menu for markers] = true.
3. Or forced to start of this rule, or wait for the poller start.
4. In syslog menu press Recreate button.
After that you can see like camm_marker_1.png.
And now the message will get there automatically.

This is what you mean?

In any case, I'm always glad to new proposals to improve camm :D
Attachments
camm_marker_1.PNG
camm_marker_1.PNG (163.34 KiB) Viewed 4574 times
camm_marker_0.PNG
camm_marker_0.PNG (44.01 KiB) Viewed 4574 times
My cacti plugin -[url=http://forums.cacti.net/viewtopic.php?p=156769#156769]CaMM[/url]
[size=75]Sorry for my English. [/size]
galerien
Posts: 33
Joined: Wed Feb 11, 2009 12:16 pm
Location: Geneva

SQL filter when edit rules isn't working

Post by galerien »

When I edit a new rule, the field "SQL filter" is showing "1=1" ...

I have selected "SQL filter" then the field "syslog - message" then I put operator "=" and value "GigabitEthernet1/0/2" :

- When I test it return nothing, and when i click on "done" the rule is showing "message is null" ...

if I select "SQL filter" then the field "syslog - message" then I put operator "contains" and value "GigabitEthernet1/0/2" :
- When I test : it return nothing, and when i click on "done" the rule is showing SQL filter : "1=1" ...


could someone please help me ???
Attachments
SQLfilter-contains.PNG
SQLfilter-contains.PNG (47.5 KiB) Viewed 4484 times
mcutting
Cacti Guru User
Posts: 1884
Joined: Mon Oct 16, 2006 5:57 am
Location: United Kingdom
Contact:

Post by mcutting »

gthe wrote:
mcutting wrote: Yes, I know :)

However, after around 2-3 days, these settings are discarded ny JSON, and you need to set it again :(
These settings are stored in cookies. I have them stored for months. Perhaps someone / something to clean your cookies?
My cookes are being stored for 90 days !
Cacti Version 0.8.8b
Cacti OS Ubuntu LTS
RRDTool Version RRDTool 1.4.7
Poller Information
Type SPINE 0.8.8b
sini
Cacti User
Posts: 91
Joined: Mon Nov 24, 2003 10:22 am
Location: Hungary

Post by sini »

gthe wrote: If I understand you correctly, it is already implemented (perhaps just not fully). For example, I want to have quick access to all the events on the successful login to the switches. This necessary:
1. Create a rule that would explicitly select the required messages and this rule should add a mark to these reports - see camm_marker_0.png.
2. In settings tabs of camm set parameter [2. camm General settings] - [Create tree menu for markers] = true.
3. Or forced to start of this rule, or wait for the poller start.
4. In syslog menu press Recreate button.
After that you can see like camm_marker_1.png.
And now the message will get there automatically.

This is what you mean?
Thanks i tired your suggestion!

Looks good but in sql query i can`t use OR logical operator.
To be more specific for example if i would like to see some of my core routers` interface UPDOWN changes than
1. I have to create a core_routers host template and create all of my core routers with it.

2. I have to create a marker rule || filter view :)
As you wrote i can use host_type to filter out hosts which interesting for this point of view, but what if i don`t want to include all the routers which linked to core_routers host template?

for example i have 3 routers created with core_routers template
router1.domain.net
router2.domain.net
router3.domain.net
but just 1,2 are important for me for alerting. Can i create a filter rule like this?
select message from plugin_camm_syslog where (host like "router1%") or (host like "router2%");

Few other question:
How often does the tree view updates? I set it to 1 min in Settings Utils > 6.CaMM Startup Settings > Tree update interval but i not noticed a Loading sign like in the main view.

What if i set an e-mail alert for an interface to send mail when its change state to down and this interface starts bouncing? I get a hundreds of mail?
gthe wrote: In any case, I'm always glad to new proposals to improve camm :D
So what do you think about a filter view tab :) ? In NPC plugin there is a dasboard view. Something like that would be nice if we can see all the created filter with last 5-10 (or as many you set) syslog messages and a statistic count and a filter name in the title field. In a NOC center it will be more informative to see the new syslog alarms not just the increasing counts of events like in tree view.
And i have more ideas :)

Thank you for all your efforts! It is really great plugin!
Sini
User avatar
gthe
Cacti User
Posts: 410
Joined: Sat Jul 29, 2006 1:23 pm
Location: RU

Post by gthe »

sini wrote:Can i create a filter rule like this?
select message from plugin_camm_syslog where (host like "router1%") or (host like "router2%");
At the moment - no. But you can create a query:

Code: Select all

select message from plugin_camm_syslog where (host_type = "core_routers") AND (host NOT like "router3%");
sini wrote: Few other question:
How often does the tree view updates? I set it to 1 min in Settings Utils > 6.CaMM Startup Settings > Tree update interval but i not noticed a Loading sign like in the main view.
This settings is for update data in db.
sini wrote: What if i set an e-mail alert for an interface to send mail when its change state to down and this interface starts bouncing? I get a hundreds of mail?
It depends on the parameter in rule - E-mail settings - Email Mode = [all records in one email / each record in separate mail]
sini wrote:
gthe wrote: In any case, I'm always glad to new proposals to improve camm :D
So what do you think about a filter view tab :) ? In NPC plugin there is a dasboard view. Something like that would be nice if we can see all the created filter with last 5-10 (or as many you set) syslog messages and a statistic count and a filter name in the title field. In a NOC center it will be more informative to see the new syslog alarms not just the increasing counts of events like in tree view.
And i have more ideas :)

Thank you for all your efforts! It is really great plugin!
I.e. independent windows for each filter/sql ? Now that's interesting...
My cacti plugin -[url=http://forums.cacti.net/viewtopic.php?p=156769#156769]CaMM[/url]
[size=75]Sorry for my English. [/size]
User avatar
smlick
Cacti User
Posts: 267
Joined: Tue May 20, 2008 4:09 am
Location: Italy, Rome

Post by smlick »

Hi Gthe, is it possible in the next release to specify an automatic delete of the db data by a self pre-set period (like 6 month in my case).
So I think is useful to have 2 input boxes one with day, month, year and the other one with number so you can easily specify any period.

Regards
Alessio
Cacti Version 0.8.8c production / 0.8.8c test W2008 -- Plugin:Weathermap - Monitor - CAMM 1.6.7 :) - Nectar - GPS Map
User avatar
gthe
Cacti User
Posts: 410
Joined: Sat Jul 29, 2006 1:23 pm
Location: RU

Post by gthe »

I find it easier to me at once to create 10 or 20 or 30 options to choose :D
My cacti plugin -[url=http://forums.cacti.net/viewtopic.php?p=156769#156769]CaMM[/url]
[size=75]Sorry for my English. [/size]
sini
Cacti User
Posts: 91
Joined: Mon Nov 24, 2003 10:22 am
Location: Hungary

Post by sini »

gthe wrote: I.e. independent windows for each filter/sql ? Now that's interesting...
Yes, for example that would be nice.
Thank you for your answers!
Sini
User avatar
smlick
Cacti User
Posts: 267
Joined: Tue May 20, 2008 4:09 am
Location: Italy, Rome

Post by smlick »

Frequently I get a DB Exec Failed like this one:


12/22/2009 03:16:49 PM - SYSTEM camm General STATS: AllTime:61.3884 PurgeTime:0.0009 RuleTime:0.0847 TreeTime:61.3028
12/22/2009 03:16:49 PM - CMDPHP: Poller[0] ERROR: A DB Exec Failed!, Error:'1364', SQL:"INSERT INTO `plugin_camm_tree2` (`device_id`,`description`, `hostname`,`gr_f`,`gr_v`,`agentip`,`agentip_source` ,`type` ,`period`,`_is_type`,`_is_device`,`_parent` ,`count` ,`dev_count` ,`online` ,`_is_leaf`,`_lvl`) SELECT `t0`.`device_id`,`t0`.`description`,`t0`.`hostname`,`t0`.`gr_f`,`t0`.`gr_v`,`t0`.`agentip`,`t0`.`agentip_source`,'syslog',`t0`.`period` ,'0' ,'0' ,t1.id ,t0.`count` ,`t0`.`dev_count`,'1' ,'1' ,'5' FROM plugin_camm_temp as t0 join plugin_camm_tree2 as t1 on (t0.type=t1.type and t0.hostname=t1.hostname and t0.period=t1.period and t0.gr_f=t1.gr_f) WHERE `t0`.`type`='syslog' and `t1`.`online`='1' and `_is_marker`='0' group by hostname,period,`t0`.gr_f,gr_v ON DUPLICATE KEY UPDATE `plugin_camm_tree2`.`dev_count` = values(`dev_count`), `plugin_camm_tree2`.`_parent` = values(`_parent`), `plugin_camm_tree2`.`count` = values(`count`), `plugin_camm_tree2`.`online` = '1' ;'
12/22/2009 03:16:49 PM - CMDPHP: Poller[0] ERROR: A DB Exec Failed!, Error:'1364', SQL:"INSERT INTO `plugin_camm_tree2` (`device_id`,`description`, `hostname`,`gr_f`,`gr_v`,`agentip`,`agentip_source` ,`type` ,`period`,`_is_type`,`_is_device`,`_parent` ,`count` ,`dev_count` ,`online` ,`_is_leaf`,`_lvl`) SELECT `t0`.`device_id`,`t0`.`description`,`t0`.`hostname`,`t0`.`gr_f`,`t0`.`gr_v`,`t0`.`agentip`,`t0`.`agentip_source`,'syslog',`t0`.`period` ,'0' ,'0' ,t1.id ,t0.`count` ,`t0`.`dev_count`,'1' ,'0' ,'4' FROM plugin_camm_temp as t0 join plugin_camm_tree2 as t1 on (t0.type=t1.type and t0.hostname=t1.hostname and t0.period=t1.period) WHERE `t0`.`type`='syslog' and `t1`.`online`='1' and `_is_marker`='0' group by hostname,period,gr_f ON DUPLICATE KEY UPDATE `plugin_camm_tree2`.`dev_count` = values(`dev_count`), `plugin_camm_tree2`.`_parent` = values(`_parent`), `plugin_camm_tree2`.`count` = values(`count`), `plugin_camm_tree2`.`online` = '1' ;'
12/22/2009 03:16:23 PM - SPINE: Poller[0] ERROR: An internal Net-Snmp error condition detected in Cacti snmp_get


I think that this happen because the treetime exceed 60 sec (I have a cron interval of 1 minute).

Usually the treetime is over 1 sec:

12/22/2009 03:07:26 PM - SYSTEM camm General STATS: AllTime:0.0835 PurgeTime:0.0173 RuleTime:0.0645 TreeTime:0.0016

Why sometimes the treetime goes over 50/60 sec?


Regards
Alessio
Cacti Version 0.8.8c production / 0.8.8c test W2008 -- Plugin:Weathermap - Monitor - CAMM 1.6.7 :) - Nectar - GPS Map
User avatar
gthe
Cacti User
Posts: 410
Joined: Sat Jul 29, 2006 1:23 pm
Location: RU

Post by gthe »

Perhaps there is some interval between these slow pollers ?
try

Code: Select all

grep TreeTime /var/www/html/cacti/log/cacti.log 
and pm me the results for last 2-3 days...
My cacti plugin -[url=http://forums.cacti.net/viewtopic.php?p=156769#156769]CaMM[/url]
[size=75]Sorry for my English. [/size]
User avatar
smlick
Cacti User
Posts: 267
Joined: Tue May 20, 2008 4:09 am
Location: Italy, Rome

Post by smlick »

gthe wrote:Perhaps there is some interval between these slow pollers ?
try

Code: Select all

grep TreeTime /var/www/html/cacti/log/cacti.log 
and pm me the results for last 2-3 days...
I looked at the log file and the problem seems to be every 6 minutes, even though in some cases even 14 minutes have passed.
I remind you that I have cacti version 0.8.7b on Windows and use the latest version of your plugin.
I'll send you by PM the Cacti log.
I wish you a Merry Christmas and thanks again for your work on this plugin and your precious support.

Regards
Alessio
Cacti Version 0.8.8c production / 0.8.8c test W2008 -- Plugin:Weathermap - Monitor - CAMM 1.6.7 :) - Nectar - GPS Map
User avatar
gthe
Cacti User
Posts: 410
Joined: Sat Jul 29, 2006 1:23 pm
Location: RU

Post by gthe »

Smlick,

First of all - almost always errors in camm appear after the message:
12/21/2009 12:13:00 AM - POLLER: Poller[0] WARNING: Scheduled Task is out of sync with the Poller Interval! The Poller Interval is '300' seconds, with a maximum of a '300' second Scheduled Task, but 120 seconds have passed since the last poll!
So I think what you need first to correct this error.

Secondly, after this in the settings tab's of camm set [debug mode] to enable and after that PM me log again.


smlick wrote: I wish you a Merry Christmas and thanks again for your work on this plugin and your precious support.

Regards
Alessio
Thanks, but in Russia Christmas celebrate on January 7 :)

So I wish you a Merry Christmas.
My cacti plugin -[url=http://forums.cacti.net/viewtopic.php?p=156769#156769]CaMM[/url]
[size=75]Sorry for my English. [/size]
uhtred
Cacti User
Posts: 121
Joined: Fri Oct 09, 2009 8:59 am
Location: Germany

Post by uhtred »

Hi,

I have problems with the snmptrap-daemon.
Its a new ubuntu system without gui.
in the syslog file i got i.e.:

snmptrapd[29787]: 2009-12-28 13:38:22 xxx.domain.lokal [UDP: [172.20.1.1]:161]: DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (1652730244) 191 days, 6:55:02.44^ISNMPv2-MIB::snmpTrapOID.0 = OID: SNMPv2-SMI::enterprises.3607.6.10.30.0.5070^ISNMPv2-SMI::enterprises.3607.6.10.100.10.20.0 = STRING: "20091228133807S"^ISNMPv2-SMI::enterprises.3607.6.10.20.30.20.1.80.1.5070 = INTEGER: 31^ISNMPv2-SMI::enterprises.3607.6.10.20.30.20.1.20.1.5070 = INTEGER: 10^ISNMPv2-SMI::enterprises.3607.6.10.20.30.20.1.60.1.5070 = INTEGER: 1^ISNMPv2-SMI::enterprises.3607.6.10.20.30.20.1.30.1.5070 = INTEGER: 0^ISNMPv2-SMI::enterprises.3607.6.10.20.30.20.1.40.1.5070 = INTEGER: 1^ISNMPv2-SMI::enterprises.3607.6.10.20.30.20.1.50.1.5070 = INTEGER: 0^ISNMPv2-SMI::enterprises.3607.6.10.20.30.20.1.100.1.5070 = STRING: "SYSTEM"^ISNMPv2-SMI::enterprises.3607.6.10.20.30.20.1.120.1.5070 = INTEGER: 20^ISNMPv2-SMI::enterprises.3607.6.10.20.30.20.1.130.1.5070 = INTEGER: 30^ISNMPv2-SMI::enterprises.3607.6.10.20.30.20.1.140

the problem: instead of a tab character i have ^I
the result is, the snmptt daemon misinterpret the trap.

Does anybody know whats going on here?
uhtred
Cacti User
Posts: 121
Joined: Fri Oct 09, 2009 8:59 am
Location: Germany

Post by uhtred »

problem solved :lol:

It was a problem of ubuntu package dependencies.
I installed libsnmp-perl and libsnmp-dev. On the old system i could see, libsnmp-perl will be installed with installation of libsnmp-dev.
matexoman
Posts: 5
Joined: Mon Mar 23, 2009 11:07 am

problem with traptime

Post by matexoman »

A few days ago we opened a separate topic because of a problem in the visualization of traptime in camm. (http://forums.cacti.net/viewtopic.php?t=35601)

Now I have noticed that this plugin makes the questions usually within the theme of the publication of the latest version.

Should restate the question in this thread? You could look at the thread there if you think of a solution?
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests