Hi all,
as I understand Event Background Colors are link with the syslog "level" field.
Actually the syslog page only map Facility and Priority rows.
I'm using the latest cacti 0.8.7i with kiwi syslog custom DB format
How i can send the "level" syslog raw information to mysql DB and get syslog message to be colored in web interface?
See attachement if needed
Thanks for your support
Syslog 1.22 event color
Moderators: Developers, Moderators
Syslog 1.22 event color
Last edited by guitou on Thu Feb 06, 2014 5:32 am, edited 1 time in total.
- TheWitness
- Developer
- Posts: 17061
- Joined: Tue May 14, 2002 5:08 pm
- Location: MI, USA
- Contact:
Re: Syslog 1.22 event color
Sorry, you have to show me some lines from the database, and there are four tables: 1:syslog, 2:syslog_priorities, 3:syslog_facilities, 4:syslog_host_facilities
TheWitness
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?
Re: Syslog 1.22 event color
TheWitness:
here is DATA in table requested (see attachement)
I'm using kiwi syslog daemon in order to push syslog message to mysql DB.
Priority is calculate on the facility and level data => http://www.kiwisyslog.com/kb/info:-sysl ... -priority/
Thanks for your help
here is DATA in table requested (see attachement)
I'm using kiwi syslog daemon in order to push syslog message to mysql DB.
Priority is calculate on the facility and level data => http://www.kiwisyslog.com/kb/info:-sysl ... -priority/
Thanks for your help
- Attachments
-
- syslog_priorities.jpg (35.76 KiB) Viewed 2381 times
-
- syslog_host_facilities.jpg (14.81 KiB) Viewed 2381 times
-
- syslog_facilities.jpg (15.29 KiB) Viewed 2381 times
-
- syslog.jpg (21.21 KiB) Viewed 2381 times
Re: Syslog 1.22 event color
I've the same problem.
I've seen that the css class is empty. I have modified the php (creating manually one class), and I see that the cell have the bgcolor that i've set.
TheWitness, can we help us?
This is my limit
I've seen that the css class is empty. I have modified the php (creating manually one class), and I see that the cell have the bgcolor that i've set.
Code: Select all
function generate_syslog_cssjs() {
global $colors, $config, $syslog_incoming_config;
global $syslog_colors, $syslog_text_colors, $syslog_levels;
/* legacy css for syslog backgrounds */
print "\n\t\t\t<style type='text/css'>\n";
/*if (sizeof($syslog_colors)) {
foreach ($syslog_colors as $type => $color) {
if ((isset($syslog_text_colors[$type]) && $syslog_text_colors[$type] != '')) {
print "\t\t\t.syslog_$type {\n";
if ($color != '') {
print "\t\t\t\tbackground-color:#$color;\n";
}
if (isset($syslog_text_colors[$type]) && $syslog_text_colors[$type] != '') {
print "\t\t\t\tcolor:#" . $syslog_text_colors[$type] . ";\n";
}
print "\t\t\t}\n";
}
}
}*/
//ADDED BY ME ## BEGIN
print ".syslog_debug{\n";
print "background-color:#FF0000;\n";
print "}\n";
print "\t\t\t</style>\n";
//ADDED BY ME ## END
/* this section of javascript keeps nasty calendar popups from
* appearing when you hit return.
*/
?>
This is my limit
Re: Syslog 1.22 event color
I have a """""TEMPORARY""""" solution for my cacti.
This are the default colors
This are the default colors
Code: Select all
print ".syslog_debug{\n";
print "background-color:#ed5394;\n";
print "}\n";
print ".syslog_emerg{\n";
print "background-color:#ff0000;\n";
print "}\n";
print ".syslog_crit{\n";
print "background-color:#da4725;\n";
print "}\n";
print ".syslog_alert{\n";
print "background-color:#ff897c;\n";
print "}\n";
print ".syslog_err{\n";
print "background-color:#ffd660;\n";
print "}\n";
print ".syslog_warn{\n";
print "background-color:#fff200;\n";
print "}\n";
print ".syslog_notice{\n";
print "background-color:#d2d8f9;\n";
print "}\n";
print ".syslog_info{\n";
print "background-color:#caf100;\n";
print "}\n";
print ".syslog_other{\n";
print "background-color:#afeced;\n";
print "}\n";
Who is online
Users browsing this forum: No registered users and 1 guest