Package: mpt-status
Version: 1.2.0-4.2
Severity: minor

Hi,

mpt-statusd keeps sending to syslog "detected non-optimal RAID status", but my 
RAID array is OPTIMAL :

$ sudo mpt-status -i 4                                         
ioc0 vol_id 4 type IM, 2 phy, 698 GB, state OPTIMAL, flags ENABLEDioc0 phy 1 
scsi_id 6 ATA      Hitachi HDS72107 AB0A, 698 GB, state ONLINE, flags NONE
ioc0 phy 0 scsi_id 5 ATA      Hitachi HDS72107 AB0A, 698 GB, state ONLINE, 
flags NONE

and in syslog :
Jul 30 11:11:48 ulithi mpt-statusd: detected non-optimal RAID status


I've added the right ID in /etc/default/mpt-statusd (which should be created by 
default by the way)

If I output the line "mpt-status -i $ID" to syslog, I get nothing (no text).

I've modified the init.d script, and for an unknow reason, I have to explicitly 
tell the path to mpt-status :

--- mpt-statusd 2009-07-30 11:35:21.000000000 +0200
+++ /etc/init.d/mpt-statusd     2009-07-30 11:14:09.000000000 +0200
@@ -55,11 +55,12 @@
         # Check ever $PERIOD seconds, send email on every status
         # change and repeat ever $REMIND seconds if the raid is still
         # bad.
-        if (mpt-status -i $ID) |grep -q 'state OPTIMAL' ; then
+        if (/usr/sbin/mpt-status -i $ID) |grep -q 'state OPTIMAL' ; then
             BADRAID=false
         else
             BADRAID=true
-            logger -t mpt-statusd "detected non-optimal RAID status"
+           OUTPUT=$(/usr/sbin/mpt-status -i $ID)
+            logger -t mpt-statusd "detected non-optimal RAID status ($OUTPUT)"
         fi
         STATUSCHANGE=false
         if [ true = "$BADRAID" ] ; then

and now I don't get any error in syslog.

Thanks
Philippe

-- System Information:
Debian Release: 5.0.2
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.26-2-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_GB, LC_CTYPE=en_GB (charmap=ISO-8859-1)
Shell: /bin/sh linked to /bin/bash

Versions of packages mpt-status depends on:
ii  bsd-mailx [mailx]  8.1.2-0.20071201cvs-3 A simple mail user agent
ii  daemon             0.6.3-1               turns other processes into daemons
ii  libc6              2.7-18                GNU C Library: Shared libraries
ii  lsb-base           3.2-20                Linux Standard Base 3.2 init scrip
ii  mailx              1:20071201-3          Transitional package for mailx ren

mpt-status recommends no packages.

mpt-status suggests no packages.

-- no debconf information



-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to