From 0239acdaa686ed172ee41d0b08b0ad4b61e1f421 Mon Sep 17 00:00:00 2001 From: tbrehm <t.brehm@ispconfig.org> Date: Sun, 15 Mar 2009 06:56:08 -0400 Subject: [PATCH] Fixed: FS#630 - Hard disk has no more space left error is reported with cdrom in cd drive --- server/mods-available/monitor_core_module.inc.php | 12 ++++++++---- 1 files changed, 8 insertions(+), 4 deletions(-) diff --git a/server/mods-available/monitor_core_module.inc.php b/server/mods-available/monitor_core_module.inc.php index 162fd86..b3aed2a 100644 --- a/server/mods-available/monitor_core_module.inc.php +++ b/server/mods-available/monitor_core_module.inc.php @@ -219,10 +219,14 @@ * calculate the state */ $usePercent = floatval($data[$i]['percent']); - if ($usePercent > 75) $state = $this->_setState($state, 'info'); - if ($usePercent > 80) $state = $this->_setState($state, 'warning'); - if ($usePercent > 90) $state = $this->_setState($state, 'critical'); - if ($usePercent > 95) $state = $this->_setState($state, 'error'); + + //* We dont want to check the cdrom drive as a cd / dvd is always 100% full + if($data[$i]['type'] != 'iso9660') { + if ($usePercent > 75) $state = $this->_setState($state, 'info'); + if ($usePercent > 80) $state = $this->_setState($state, 'warning'); + if ($usePercent > 90) $state = $this->_setState($state, 'critical'); + if ($usePercent > 95) $state = $this->_setState($state, 'error'); + } } } -- Gitblit v1.9.1