Patching check_smartmon plugin


#1

Hi all!!!

I need monitoring SMART HEALTH with nagios.
I found on nagiosexchange.com cneck_smartmon plugin.
But when I try to use this plugin with SCSI drives I have this
error, where I say check_smartmon -d device

“Traceback (most recent call last):
File “./check_smartmon”, line 254, in ?
(healthStatus, temperature) = parseOutput(healthStatusOutput,
temperatureOutput) File “./check_smartmon”, line 163, in parseOutput
healthStatus = parts-1]
IndexError: list index out of range”

I found the patch “patch for using sudo, devicetype as parameter and performance output (bems!, 27.03.2007 11:35:17)” on nagiosexchange.org, but I could not apply this patch both on FreeBSD and Linux. I use the unix patch command and where i try apply this patch with that:
#patch < patch_nagiosexchange.org I have this error:

Hmm… Looks like a new-style context diff to me…
The text leading up to this was:

|*** check_smartmon 2007-03-27 08:38:39.000000000 +0200

— check_smartmon_ata.pyt 2007-03-27 11:34:13.000000000 +0200

Patching file check_smartmon using Plan A…
patch: **** malformed patch at line 6: _smartctlPath = “/usr/sbin/smartctl”

Anybody try apply this patch???
Please, tell me decision, how I can apply it???