more fixes to discovery

git-svn-id: http://www.observium.org/svn/observer/trunk@841 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Adam Amstrong
2010-02-15 01:53:00 +00:00
parent 2491186697
commit 01da6907e5
4 changed files with 9 additions and 4 deletions

View File

@@ -88,4 +88,5 @@ ALTER TABLE `temperature` CHANGE `temp_host` `device_id` INT( 11 ) NOT NULL D
ALTER TABLE `fanspeed` CHANGE `fan_host` `device_id` INT( 11 ) NOT NULL DEFAULT '0'
ALTER TABLE `voltage` CHANGE `volt_host` `device_id` INT( 11 ) NOT NULL DEFAULT '0'
CREATE TABLE IF NOT EXISTS `processors` ( `processor_id` int(11) NOT NULL AUTO_INCREMENT, `entPhysicalIndex` int(11) NOT NULL, `device_id` int(11) NOT NULL, `processor_oid` int(11) NOT NULL, `processor_type` int(11) NOT NULL, `processor_usage` int(11) NOT NULL, `processor_description` varchar(64) NOT NULL, PRIMARY KEY (`processor_id`), KEY `cpuCPU_id` (`processor_id`,`device_id`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;
ALTER TABLE `processors` ADD `hrDeviceIndex` int(11) NOT NULL AFTER `entPhysicalIndex`
ALTER TABLE `processors` ADD `hrDeviceIndex` int(11) NULL AFTER `entPhysicalIndex`
ALTER TABLE `temperature` CHANGE `temp_current` `temp_current` FLOAT( 4 ) NOT NULL DEFAULT '0'

View File

@@ -4,6 +4,7 @@
include("config.php");
include("includes/functions.php");
include("includes/functions-poller.inc.php");
include("includes/discovery/functions.inc.php");
$start = utime();

View File

@@ -68,6 +68,11 @@ $config['allow_entity_sensor']['watts'] = 1;
$config['allow_entity_sensor']['truthvalue'] = 1;
$config['allow_entity_sensor']['specialEnum'] = 1;
# Set default alert limits for various sensors and metrics
$config['limit']['fan'] = "1000";
$config['limit']['temp'] = "60";
# Filesystems
$config['ignore_mount'] = array("/kern", "/mnt/cdrom", "/proc");
@@ -76,6 +81,4 @@ $config['ignore_mount_regexp'] = array();
$config['ignore_mount_removable'] = 1; # Ignore removable disk storage
$config['ignore_mount_network'] = 1; # Ignore network mounted storage
?>

View File

@@ -14,7 +14,7 @@ while($fanspeed = mysql_fetch_array($fan_data)) {
$fanrrd = $config['rrd_dir'] . "/" . $device['hostname'] . "/" . safename("fan-" . $fanspeed['fan_descr'] . ".rrd");
if (!is_file($fanrrd)) {
`rrdtool create $fanrrd \
`rrdtool create $fanrrd \
--step 300 \
DS:fan:GAUGE:600:0:20000 \
RRA:AVERAGE:0.5:1:1200 \