<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Apache check plugin for Nagios</title>
	<atom:link href="http://www.matejunkie.com/apache2-check-plugin-for-nagios/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.matejunkie.com/apache2-check-plugin-for-nagios/</link>
	<description>&#34;Look behind you, a Three-Headed Monkey!&#34;</description>
	<lastBuildDate>Sat, 17 Jul 2010 22:58:13 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
	<item>
		<title>By: nima0102</title>
		<link>http://www.matejunkie.com/apache2-check-plugin-for-nagios/comment-page-1/#comment-4061</link>
		<dc:creator>nima0102</dc:creator>
		<pubDate>Wed, 08 Jul 2009 20:50:27 +0000</pubDate>
		<guid isPermaLink="false">http://www.matejunkie.com/?p=826#comment-4061</guid>
		<description>thanks a lot for your script :)</description>
		<content:encoded><![CDATA[<p>thanks a lot for your script :)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mike</title>
		<link>http://www.matejunkie.com/apache2-check-plugin-for-nagios/comment-page-1/#comment-3403</link>
		<dc:creator>Mike</dc:creator>
		<pubDate>Tue, 17 Mar 2009 20:20:21 +0000</pubDate>
		<guid isPermaLink="false">http://www.matejunkie.com/?p=826#comment-3403</guid>
		<description>Thanks Hendrik for the changes you&#039;ve made. I&#039;ll integrate them as soon as I&#039;ve updated the script. I&#039;m currently working on the integration of different warning levels and will let you know when it&#039;s finished through a new post and an update at nagiosforge as well.</description>
		<content:encoded><![CDATA[<p>Thanks Hendrik for the changes you&#8217;ve made. I&#8217;ll integrate them as soon as I&#8217;ve updated the script. I&#8217;m currently working on the integration of different warning levels and will let you know when it&#8217;s finished through a new post and an update at nagiosforge as well.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Hendrik Frenzel</title>
		<link>http://www.matejunkie.com/apache2-check-plugin-for-nagios/comment-page-1/#comment-3402</link>
		<dc:creator>Hendrik Frenzel</dc:creator>
		<pubDate>Tue, 17 Mar 2009 00:26:25 +0000</pubDate>
		<guid isPermaLink="false">http://www.matejunkie.com/?p=826#comment-3402</guid>
		<description>&lt;pre lang=&quot;bash&quot;&gt;# Hi,
# 
# thanks for your script.
# i made the following changes to hide some useless values from 
# the performance data (for graphs) and for cosmetical reasons.
# you can apply it with
#  patch -p0 &lt; check_apache2.sh.diff
#
# bye
# BeeEmm
#
--- check_apache2.sh.orig       2009-03-16 22:53:09.000000000 +0100
+++ check_apache2.sh    2009-03-17 01:16:19.000000000 +0100
@@ -147,10 +147,10 @@
 }

 get_cpu_load() {
-    cpu_load=&quot;$(cpu_load=0; ps -Ao pcpu,args &#124; grep &#039;/usr/sbin/apache2&#039; &#124; awk &#039;{print $1}&#039; &#124; while read line
+    cpu_load=&quot;$(cpu_load=0; ps -Ao pcpu,args &#124; grep &#039;/usr/sbin/apache2&#039; &#124; awk &#039;{print $1}&#039; &#124; while read line;
     do
-        cpu_load=`echo &quot;scale=3; $cpu_load + $line&quot; &#124; bc -l`
-    echo $cpu_load
+        cpu_load=`echo &quot;scale=3; $cpu_load + $line&quot; &#124; bc -l`;
+    echo $cpu_load;
     done)&quot;
     cpu_load=`echo $cpu_load &#124; awk &#039;{print $NF}&#039; &#124; sed &#039;s/^\./0./&#039;`
 }
@@ -203,12 +203,14 @@
 case $ext_info in
     1)  
         get_req_psec; get_cpu_load; get_uptime; get_wkrs_busy; get_wkrs_idle;
-        get_total_req; get_total_kb; get_bytes_psec; get_bytes_preq;
-        perfdata=&quot;&#039;req_psec&#039;=$req_psec &#039;cpu_load&#039;=$cpu_load &#039;uptime&#039;=$uptime &#039;workers_busy&#039;=$wkrs_busy &#039;workers_idle&#039;=$wkrs_idle &#039;total_req&#039;=$total_req &#039;total_kb&#039;=$total_kb &#039;bytes_psec&#039;=$bytes_psec &#039;bytes_preq&#039;=$bytes_preq&quot;
+        #get_total_req; get_total_kb;
+        get_bytes_psec; get_bytes_preq;
+        perfdata=&quot;req_psec=$req_psec cpu_load=$cpu_load workers_busy=$wkrs_busy workers_idle=$wkrs_idle bytes_psec=$bytes_psec bytes_preq=$bytes_preq&quot;
+       # total_req=$total_req total_kb=$total_kb
         ;;
     *)  
         get_req_psec; get_cpu_load; get_uptime; get_wkrs_busy; get_wkrs_idle;
-        perfdata=&quot;&#039;req_psec&#039;=$req_psec &#039;cpu_load&#039;=$cpu_load &#039;uptime&#039;=$uptime &#039;workers_busy&#039;=$wkrs_busy &#039;workers_idle&#039;=$wkrs_idle&quot;
+        perfdata=&quot;req_psec=$req_psec cpu_load=$cpu_load workers_busy=$wkrs_busy workers_idle=$wkrs_idle&quot;
         ;;
 esac&lt;/pre&gt;</description>
		<content:encoded><![CDATA[
<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># Hi,</span>
<span style="color: #666666; font-style: italic;"># </span>
<span style="color: #666666; font-style: italic;"># thanks for your script.</span>
<span style="color: #666666; font-style: italic;"># i made the following changes to hide some useless values from </span>
<span style="color: #666666; font-style: italic;"># the performance data (for graphs) and for cosmetical reasons.</span>
<span style="color: #666666; font-style: italic;"># you can apply it with</span>
<span style="color: #666666; font-style: italic;">#  patch -p0 &amp;lt; check_apache2.sh.diff</span>
<span style="color: #666666; font-style: italic;">#</span>
<span style="color: #666666; font-style: italic;"># bye</span>
<span style="color: #666666; font-style: italic;"># BeeEmm</span>
<span style="color: #666666; font-style: italic;">#</span>
<span style="color: #660033;">---</span> check_apache2.sh.orig       <span style="color: #000000;">2009</span>-03-<span style="color: #000000;">16</span> <span style="color: #000000;">22</span>:<span style="color: #000000;">53</span>:<span style="color: #000000;">09.000000000</span> +0100
+++ check_apache2.sh    <span style="color: #000000;">2009</span>-03-<span style="color: #000000;">17</span> 01:<span style="color: #000000;">16</span>:<span style="color: #000000;">19.000000000</span> +0100
<span style="color: #000000; font-weight: bold;">@@</span> -<span style="color: #000000;">147</span>,<span style="color: #000000;">10</span> +<span style="color: #000000;">147</span>,<span style="color: #000000;">10</span> <span style="color: #000000; font-weight: bold;">@@</span>
 <span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
 get_cpu_load<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span>
-    <span style="color: #007800;">cpu_load</span>=<span style="color: #ff0000;">&quot;$(cpu_load=0; ps -Ao pcpu,args | grep '/usr/sbin/apache2' | awk '{print $1}' | while read line
+    cpu_load=&quot;</span>$<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #007800;">cpu_load</span>=<span style="color: #000000;">0</span>; <span style="color: #c20cb9; font-weight: bold;">ps</span> <span style="color: #660033;">-Ao</span> pcpu,args <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #ff0000;">'/usr/sbin/apache2'</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">awk</span> <span style="color: #ff0000;">'{print $1}'</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #000000; font-weight: bold;">while</span> <span style="color: #c20cb9; font-weight: bold;">read</span> line;
     <span style="color: #000000; font-weight: bold;">do</span>
-        <span style="color: #007800;">cpu_load</span>=<span style="color: #000000; font-weight: bold;">`</span><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;scale=3; <span style="color: #007800;">$cpu_load</span> + <span style="color: #007800;">$line</span>&quot;</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">bc</span> -l<span style="color: #000000; font-weight: bold;">`</span>
-    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #007800;">$cpu_load</span>
+        <span style="color: #007800;">cpu_load</span>=<span style="color: #000000; font-weight: bold;">`</span><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;scale=3; <span style="color: #007800;">$cpu_load</span> + <span style="color: #007800;">$line</span>&quot;</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">bc</span> -l<span style="color: #000000; font-weight: bold;">`</span>;
+    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #007800;">$cpu_load</span>;
     <span style="color: #000000; font-weight: bold;">done</span><span style="color: #7a0874; font-weight: bold;">&#41;</span><span style="color: #ff0000;">&quot;
     cpu_load=<span style="color: #780078;">`echo $cpu_load | awk '{print $NF}' | sed 's/^\./0./'`</span>
 }
@@ -203,12 +203,14 @@
 case <span style="color: #007800;">$ext_info</span> in
     1)  
         get_req_psec; get_cpu_load; get_uptime; get_wkrs_busy; get_wkrs_idle;
-        get_total_req; get_total_kb; get_bytes_psec; get_bytes_preq;
-        perfdata=&quot;</span><span style="color: #ff0000;">'req_psec'</span>=<span style="color: #007800;">$req_psec</span> <span style="color: #ff0000;">'cpu_load'</span>=<span style="color: #007800;">$cpu_load</span> <span style="color: #ff0000;">'uptime'</span>=<span style="color: #007800;">$uptime</span> <span style="color: #ff0000;">'workers_busy'</span>=<span style="color: #007800;">$wkrs_busy</span> <span style="color: #ff0000;">'workers_idle'</span>=<span style="color: #007800;">$wkrs_idle</span> <span style="color: #ff0000;">'total_req'</span>=<span style="color: #007800;">$total_req</span> <span style="color: #ff0000;">'total_kb'</span>=<span style="color: #007800;">$total_kb</span> <span style="color: #ff0000;">'bytes_psec'</span>=<span style="color: #007800;">$bytes_psec</span> <span style="color: #ff0000;">'bytes_preq'</span>=<span style="color: #007800;">$bytes_preq</span><span style="color: #ff0000;">&quot;
+        #get_total_req; get_total_kb;
+        get_bytes_psec; get_bytes_preq;
+        perfdata=&quot;</span><span style="color: #007800;">req_psec</span>=<span style="color: #007800;">$req_psec</span> <span style="color: #007800;">cpu_load</span>=<span style="color: #007800;">$cpu_load</span> <span style="color: #007800;">workers_busy</span>=<span style="color: #007800;">$wkrs_busy</span> <span style="color: #007800;">workers_idle</span>=<span style="color: #007800;">$wkrs_idle</span> <span style="color: #007800;">bytes_psec</span>=<span style="color: #007800;">$bytes_psec</span> <span style="color: #007800;">bytes_preq</span>=<span style="color: #007800;">$bytes_preq</span><span style="color: #ff0000;">&quot;
+       # total_req=<span style="color: #007800;">$total_req</span> total_kb=<span style="color: #007800;">$total_kb</span>
         ;;
     *)  
         get_req_psec; get_cpu_load; get_uptime; get_wkrs_busy; get_wkrs_idle;
-        perfdata=&quot;</span><span style="color: #ff0000;">'req_psec'</span>=<span style="color: #007800;">$req_psec</span> <span style="color: #ff0000;">'cpu_load'</span>=<span style="color: #007800;">$cpu_load</span> <span style="color: #ff0000;">'uptime'</span>=<span style="color: #007800;">$uptime</span> <span style="color: #ff0000;">'workers_busy'</span>=<span style="color: #007800;">$wkrs_busy</span> <span style="color: #ff0000;">'workers_idle'</span>=<span style="color: #007800;">$wkrs_idle</span><span style="color: #ff0000;">&quot;
+        perfdata=&quot;</span><span style="color: #007800;">req_psec</span>=<span style="color: #007800;">$req_psec</span> <span style="color: #007800;">cpu_load</span>=<span style="color: #007800;">$cpu_load</span> <span style="color: #007800;">workers_busy</span>=<span style="color: #007800;">$wkrs_busy</span> <span style="color: #007800;">workers_idle</span>=<span style="color: #007800;">$wkrs_idle</span><span style="color: #ff0000;">&quot;
         ;;
 esac</span></pre></div></div>

]]></content:encoded>
	</item>
</channel>
</rss>
