<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<style>
<!--
/* Font Definitions */
@font-face
{font-family:Wingdings;
panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
{font-family:"MS Shell Dlg";
panose-1:2 11 6 4 2 2 2 2 2 4;}
@font-face
{font-family:Verdana;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman";}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{color:purple;
text-decoration:underline;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:Arial;
color:windowtext;}
@page Section1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
{page:Section1;}
-->
</style>
</head>
<body lang=EN-US link=blue vlink=purple>
<div class=Section1>
<table class=MsoNormalTable border=0 cellspacing=0 cellpadding=0 width="100%"
style='width:100.0%'>
<tr>
<td width="85%" valign=top style='width:85.0%;padding:3.75pt 3.75pt 3.75pt 3.75pt'>
<p class=MsoNormal style='margin-bottom:12.0pt;line-height:15.6pt'><font
size=3 color=black face=Verdana><span style='font-size:12.0pt;font-family:
Verdana;color:black'>I am getting some strange results from the check_disk
plugin in Nagios. The first code section contains my command as set in
Nagios. If I run the command independent of Nagios, I get what appears
to be the correct info (see second code section). If the plugin is run
in Nagios, I get the result with the partition name but the numbers are not
correct for the space (see third code section).<br>
<br>
If anyone has any suggestions, they would be greatly appreciated.<o:p></o:p></span></font></p>
<p class=MsoNormal style='line-height:14.4pt'><b><font size=2 color=black
face=Verdana><span style='font-size:10.0pt;font-family:Verdana;color:black;
font-weight:bold'>Code:<o:p></o:p></span></font></b></p>
<p class=MsoNormal style='line-height:15.6pt;background:#DDDDDD'><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:black'>define command{<br>
command_name check_remote_disk<br>
command_line $USER1$/check_by_ssh -l
nagios -H $HOSTADDRESS$ -C "$USER1$/check_disk -p $ARG1$ -c $ARG2$ -w
$ARG3$"<br>
<br>
Called by:<br>
<br>
service_description DISK
- /var<br>
check_command
check_remote_disk!/var!10!25<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-bottom:12.0pt;line-height:15.6pt'><font
size=3 color=black face=Verdana><span style='font-size:12.0pt;font-family:
Verdana;color:black'><br>
<br>
<o:p></o:p></span></font></p>
<p class=MsoNormal style='line-height:14.4pt'><b><font size=2 color=black
face=Verdana><span style='font-size:10.0pt;font-family:Verdana;color:black;
font-weight:bold'>Code:<o:p></o:p></span></font></b></p>
<p class=MsoNormal style='line-height:15.6pt;background:#DDDDDD'><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:black'>ssh -l nagios nst-scriptsource-2
/usr/local/nagios/libexec/check_disk -p /var -w 30 -c 35<br>
DISK OK - free space: /var 680182 MB (70%);|
/var=288499MB;968651;968646;0;968681<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-bottom:12.0pt;line-height:15.6pt'><font
size=3 color=black face=Verdana><span style='font-size:12.0pt;font-family:
Verdana;color:black'><br>
<br>
<br>
<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-bottom:12.0pt;line-height:15.6pt'><font
size=3 color=black face=Verdana><span style='font-size:12.0pt;font-family:
Verdana;color:black'>The below is taken from my grapher log and matches what
appears on my webpage for space.<br>
</span></font><b><font size=2 color=black face=Verdana><span
style='font-size:10.0pt;font-family:Verdana;color:black;font-weight:bold'>Code:<o:p></o:p></span></font></b></p>
<p class=MsoNormal style='line-height:15.6pt;background:#DDDDDD'><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:black'>DISK - ROOT DISK OK
- free space: / 385903 MB (94%): <br>
DISK - /var DISK OK - free space: /var 914360 MB (94%):<o:p></o:p></span></font></p>
</td>
</tr>
<tr>
<td width="85%" valign=bottom style='width:85.0%;padding:3.75pt 3.75pt 3.75pt 3.75pt'>
<table class=MsoNormalTable border=0 cellpadding=0 width="100%"
style='width:100.0%'>
<tr>
<td width="100%" style='width:100.0%;padding:.75pt .75pt .75pt .75pt'>
<p class=MsoNormal><font size=2 color=black face=Verdana><span
style='font-size:10.0pt;font-family:Verdana;color:black'><o:p> </o:p></span></font></p>
</td>
</tr>
</table>
<p class=MsoNormal><font size=2 color=black face=Verdana><span
style='font-size:10.0pt;font-family:Verdana;color:black'><o:p></o:p></span></font></p>
</td>
</tr>
</table>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=4 face="Times New Roman"><span style='font-size:
14.0pt'>Scott Medaugh<o:p></o:p></span></font></p>
<p class=MsoNormal><b><font size=3 color=red face="Times New Roman"><span
style='font-size:12.0pt;color:red;font-weight:bold'>CNN</span></font></b><font
color=red><span style='color:red'> </span></font>News Systems<font color=red><span
style='color:red'><o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 color=silver face=Wingdings><span
style='font-size:10.0pt;font-family:Wingdings;color:silver'>+</span></font><font
size=2 face=Arial><span style='font-size:10.0pt;font-family:Arial'> <a
href="mailto:scott.medaugh@cnn.com">scott.medaugh@cnn.com</a></span></font><font
size=2 face="MS Shell Dlg"><span style='font-size:10.0pt;font-family:"MS Shell Dlg"'><o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 color=red face=Wingdings><span
style='font-size:10.0pt;font-family:Wingdings;color:red'>(</span></font><font
size=2 face=Arial><span style='font-size:10.0pt;font-family:Arial'>
404-827-1802 </span></font><font size=2 color=red face=Wingdings><span
style='font-size:10.0pt;font-family:Wingdings;color:red'>Q</span></font><font
size=2 face=Arial><span style='font-size:10.0pt;font-family:Arial'>404-433-9624</span></font><font
size=2 face=Wingdings><span style='font-size:10.0pt;font-family:Wingdings'><o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
</div>
</body>
</html>