Notices 0.1
Moderators: Developers, Moderators
Notices 0.1
Hello,
i tried to build a new plugin which shall add a small textarea for notices next to the graphs.
I haven' that much idea of PHP so i would be happy if someone would look over it and say whether it works as described. I tested it only on a Linux machine.
To get it working you have to enter the path to your cacti folder and reenter your database password in add_notice.php and load.php.
I would be happy about some help^^
i tried to build a new plugin which shall add a small textarea for notices next to the graphs.
I haven' that much idea of PHP so i would be happy if someone would look over it and say whether it works as described. I tested it only on a Linux machine.
To get it working you have to enter the path to your cacti folder and reenter your database password in add_notice.php and load.php.
I would be happy about some help^^
Last edited by brezel on Thu Feb 19, 2009 6:18 am, edited 1 time in total.
- browniebraun
- Developer
- Posts: 791
- Joined: Tue Jun 13, 2006 1:17 am
- Location: Cologne, Germany
Hello Brezel! (Are you from Munich?)
First off.. your plugin "works" under Windows too.
Even though there are several checks missing and a lot of notices will occur if the right permission id has not been set. And another issues if you zoom into a graph.
I like the base idea, but I advise to use Cacti's database functions instead of your own ones.
From my point of view it would also make sense to save the notices user-dependent in a separate table instead of creating some raw files.
If you need help or you've some more questions then send me a pm.
Best regards
-Andreas-
First off.. your plugin "works" under Windows too.
Even though there are several checks missing and a lot of notices will occur if the right permission id has not been set. And another issues if you zoom into a graph.
I like the base idea, but I advise to use Cacti's database functions instead of your own ones.
From my point of view it would also make sense to save the notices user-dependent in a separate table instead of creating some raw files.
If you need help or you've some more questions then send me a pm.
Best regards
-Andreas-
Hat das Blümchen einen Knick, war der Schmetterling zu dick!
reportit v0.7.5a
SNMPAgent v0.2.3
Download ReportIt | Download SNMPAgent | ReportIt SVN | ReportIt Templates | Wish list
reportit v0.7.5a
SNMPAgent v0.2.3
Download ReportIt | Download SNMPAgent | ReportIt SVN | ReportIt Templates | Wish list
mod to Notices
I really like this plugin. It comes in handy for us with temporary port labeling.
I hope you don't mind, but I made some modifications to it
1) created N.JPG
2) repackaged tar with notices directory & Images subdirectory
3) changed "Notizen" to "Notices"
I am not much of a coder, as I have proven many times in this forum
but I am thinking about how to incorporate a mouse-over or use overlib to display previously written notes.
There is a lot of potential with this plugin that I can see:
History of notices, similar to the function in nagios
email notification from notices
html capability within the notes field
resize/properties mod of notices window.
Again, this is a great plugin! Thank you so much for creating it!
I hope you don't mind, but I made some modifications to it
1) created N.JPG
2) repackaged tar with notices directory & Images subdirectory
3) changed "Notizen" to "Notices"
I am not much of a coder, as I have proven many times in this forum
but I am thinking about how to incorporate a mouse-over or use overlib to display previously written notes.
There is a lot of potential with this plugin that I can see:
History of notices, similar to the function in nagios
email notification from notices
html capability within the notes field
resize/properties mod of notices window.
Again, this is a great plugin! Thank you so much for creating it!
- Attachments
-
- notice_mod.tar
- My modded notices plugin
- (30 KiB) Downloaded 3536 times
Cacti1 OS: CentOS 5.6 | 300+ devices
Cacti2 OS: CentOS 5.6 | 300+ devices
King of the Elves
Local Anarchists Union #427
"Anarchism is founded on the observation that since few men are wise enough to rule themselves, even fewer are wise enough to rule others." -Edward Abbey
Cacti2 OS: CentOS 5.6 | 300+ devices
King of the Elves
Local Anarchists Union #427
"Anarchism is founded on the observation that since few men are wise enough to rule themselves, even fewer are wise enough to rule others." -Edward Abbey
-
- Posts: 6
- Joined: Mon Dec 17, 2007 2:39 am
- Location: Terra Firma
Bug in baum.php
I noticed a bug in baum.php:
The path to add_notice.php is hardcoded 2 places to '/cacti/plugins/...'
Which means people who have moved the cacti install to a different directory are out of luck...
Change into this to fix it:
</td></tr><tr><td><form action="'.$config['url_path'].'plugins/notices/add_notice.php? .. etc.
And now I just have to beat my head against a wall, while trying to find out why it still won't work on my box....
The path to add_notice.php is hardcoded 2 places to '/cacti/plugins/...'
Which means people who have moved the cacti install to a different directory are out of luck...
Change into this to fix it:
</td></tr><tr><td><form action="'.$config['url_path'].'plugins/notices/add_notice.php? .. etc.
And now I just have to beat my head against a wall, while trying to find out why it still won't work on my box....
-
- Posts: 6
- Joined: Mon Dec 17, 2007 2:39 am
- Location: Terra Firma
No, just me looking in the wrong place and forgetting to activate the permission under users for the plugin...brezel wrote:What does it say? If you use Opera, it has issues with the display attribute.And now I just have to beat my head against a wall, while trying to find out why it still won't work on my box....
Works alright now!
-
- Cacti User
- Posts: 83
- Joined: Fri Aug 22, 2003 4:33 am
error
Hi,
I am getting the below mentioned error in my httpd logs.... i have installed 0.2 with 8.7d with PA 2.4
[Wed Mar 18 04:16:51 2009] [error] [client 10.1.100.114] PHP Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /var/www/html/cacti_new/plugins/notices/load.php on line 67, referer: http://netmgr.monitor.com:8080/cacti_new/settings.php
[Wed Mar 18 04:16:51 2009] [error] [client 10.1.100.114] PHP Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /var/www/html/cacti_new/plugins/notices/load.php on line 67, referer: http://netmgr.monitor.com:8080/cacti_new/settings.php
Chetan
I am getting the below mentioned error in my httpd logs.... i have installed 0.2 with 8.7d with PA 2.4
[Wed Mar 18 04:16:51 2009] [error] [client 10.1.100.114] PHP Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /var/www/html/cacti_new/plugins/notices/load.php on line 67, referer: http://netmgr.monitor.com:8080/cacti_new/settings.php
[Wed Mar 18 04:16:51 2009] [error] [client 10.1.100.114] PHP Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /var/www/html/cacti_new/plugins/notices/load.php on line 67, referer: http://netmgr.monitor.com:8080/cacti_new/settings.php
Chetan
-
- Cacti User
- Posts: 83
- Joined: Fri Aug 22, 2003 4:33 am
-
- Cacti User
- Posts: 83
- Joined: Fri Aug 22, 2003 4:33 am
worked
Its working now...
Request : Is it possible to make the notice available on the graph or as a description on the graph page so it will make more sense... As of now i think we need to click on notice and look at the comment...
chetan
Request : Is it possible to make the notice available on the graph or as a description on the graph page so it will make more sense... As of now i think we need to click on notice and look at the comment...
chetan
Who is online
Users browsing this forum: No registered users and 0 guests