<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Jean - 记录成长历程 &#187; nagios</title>
	<atom:link href="http://www.zhangyiqun.net/tag/nagios/feed" rel="self" type="application/rss+xml" />
	<link>http://www.zhangyiqun.net</link>
	<description>让世界更美好一点儿</description>
	<lastBuildDate>Wed, 07 Dec 2011 14:04:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Nagios报错</title>
		<link>http://www.zhangyiqun.net/809.html</link>
		<comments>http://www.zhangyiqun.net/809.html#comments</comments>
		<pubDate>Thu, 03 Dec 2009 12:19:21 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[工作笔记]]></category>
		<category><![CDATA[nagios]]></category>

		<guid isPermaLink="false">http://www.zhangyiqun.cn/?p=809</guid>
		<description><![CDATA[当执行Host Commands时报错 you have chosen to not use the authentication functionality of the CGIs. I don&#8217;t want to be personally responsible for what may happen as a result of allowing unauthorized users to issue commands to Nagios,so you&#8217;ll have to disable this safeguard if you are really stubborn and want to invite trouble. Read the [...]<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios机器分组批量检测</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">自建nagios命令</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios和cacti排错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">实践证明xampp有点肾阳虚……</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p>当执行Host Commands时报错</p>
<blockquote><p>you have chosen to not use the authentication<br />
functionality of the CGIs.<br />
I don&#8217;t want to be personally responsible for what may happen as a<br />
result of allowing unauthorized users to issue commands to Nagios,so<br />
you&#8217;ll have to disable this safeguard if you are really stubborn and<br />
want to invite trouble.<br />
Read the section on CGI authentication in the HTML documentation to<br />
learn how you can enable authentication and why you should want to.</p></blockquote>
<p>解决办法为在cgi.nfg中<br />
use_authentication=1</p>
<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios机器分组批量检测</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">自建nagios命令</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios和cacti排错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">实践证明xampp有点肾阳虚……</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></content:encoded>
			<wfw:commentRss>http://www.zhangyiqun.net/809.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>nagios机器分组批量检测</title>
		<link>http://www.zhangyiqun.net/680.html</link>
		<comments>http://www.zhangyiqun.net/680.html#comments</comments>
		<pubDate>Fri, 11 Sep 2009 12:21:40 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux系统]]></category>
		<category><![CDATA[nagios]]></category>

		<guid isPermaLink="false">http://www.zhangyiqun.cn/?p=680</guid>
		<description><![CDATA[我一直不太喜欢用nagios，主要原因是配置太过复杂，有些时候可能自己写几行脚本就能搞定的事情却要修改一堆配置，太麻烦了。插件虽然很多但也会常常需要二次开发，实在没有那个精力。 这里说说今天改配置文件时候发现的一些技巧，在监控大量服务器时会更省力一些 一。在nagios.cfg中加入 ?View Code CONFIG#groupfile cfg_file=/usr/local/nagios/etc/objects/hostsgroup.cfg cfg_file=/usr/local/nagios/etc/objects/groupservers.cfg &#60;pre&#62; &#160; 二。监控组模板配置，这个模板写好以后，可以在需要时调用，非常的方便。 &#160; /nagios/etc/objectsgroupservers.cfg &#160; &#60;pre lang=&#34;CONFIG&#34;&#62; define service{ use local-service ; Name of service template to use hostgroup_name Webserver service_description PING check_command check_ping!100.0,20%!500.0,60% } &#160; # Define a service to check SSH on the local machine. # Disable notifications for this service by default, as [...]<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Nagios报错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">自建nagios命令</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios和cacti排错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">实践证明xampp有点肾阳虚……</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p>我一直不太喜欢用nagios，主要原因是配置太过复杂，有些时候可能自己写几行脚本就能搞定的事情却要修改一堆配置，太麻烦了。插件虽然很多但也会常常需要二次开发，实在没有那个精力。</p>
<p>这里说说今天改配置文件时候发现的一些技巧，在监控大量服务器时会更省力一些</p>
<p><span id="more-680"></span></p>
<p>一。在nagios.cfg中加入</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p680code3'); return false;">View Code</a> CONFIG</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p6803"><td class="code" id="p680code3"><pre class="config" style="font-family:monospace;">#groupfile
cfg_file=/usr/local/nagios/etc/objects/hostsgroup.cfg
cfg_file=/usr/local/nagios/etc/objects/groupservers.cfg
&lt;pre&gt;
&nbsp;
二。监控组模板配置，这个模板写好以后，可以在需要时调用，非常的方便。
&nbsp;
/nagios/etc/objectsgroupservers.cfg
&nbsp;
&lt;pre lang=&quot;CONFIG&quot;&gt;
define service{
use local-service ; Name of service template to use
hostgroup_name   Webserver
service_description PING
check_command check_ping!100.0,20%!500.0,60%
}
&nbsp;
# Define a service to check SSH on the local machine.
# Disable notifications for this service by default, as not all users may have SSH enabled.
&nbsp;
define service{
        use                             local-service         ; Name of service template to use
        hostgroup_name   Webserver
        service_description             SSH
        check_command                   check_ssh
        notifications_enabled           1
        }
&nbsp;
&nbsp;
&nbsp;
# Define a service to check HTTP on the local machine.
# Disable notifications for this service by default, as not all users may have HTTP enabled.
&nbsp;
define service{
        use                             local-service         ; Name of service template to use
        hostgroup_name   Webserver
        service_description             HTTP
        check_command                   check_http
#       notifications_enabled           0
        }
#Define a service to check squid on the local machine
define service{
        use                             local-service         ; Name of service template to use
        hostgroup_name   Webserver
        service_description             SQUID
        check_command                   check_squid
        }
&nbsp;
#CPU Load
define service{
          use                 local-service
          hostgroup_name   Webserver
          service_description CPU Load
          check_command       check_nrpe!check_load
    }
#User Login
define service{
          use                 local-service
          hostgroup_name   Webserver
          service_description Current user
          check_command       check_nrpe!check_users
    }
#Total Processes
define service{
          use                 local-service
          hostgroup_name   Webserver
          service_description Total Processes
          check_command       check_nrpe!check_total_procs
    }</pre></td></tr></table></div>

<p>三。调用。在此处调用的机器，在hosts.cfg中一定要声明过，否则nagios将无法启动</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p680code4'); return false;">View Code</a> CONFIG</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p6804"><td class="code" id="p680code4"><pre class="config" style="font-family:monospace;">define hostgroup{
       hostgroup_name   Webserver
       alias            Webserver     ;在web界面显示的名字
       members    web1
}</pre></td></tr></table></div>

<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Nagios报错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">自建nagios命令</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios和cacti排错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">实践证明xampp有点肾阳虚……</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></content:encoded>
			<wfw:commentRss>http://www.zhangyiqun.net/680.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>自建nagios命令</title>
		<link>http://www.zhangyiqun.net/575.html</link>
		<comments>http://www.zhangyiqun.net/575.html#comments</comments>
		<pubDate>Tue, 04 Aug 2009 12:13:51 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[工作笔记]]></category>
		<category><![CDATA[nagios]]></category>

		<guid isPermaLink="false">http://www.zhangyiqun.cn/?p=575</guid>
		<description><![CDATA[将nagios迁移过后又陆续添加了一些机器进去，这时候遇到一个麻烦，使用check_http无法验证网站，提示失败。 但是我直接使用libexec下的文件时却能够探测的到，因为公司的check_http是根据squid改写的，所以在参数上可能有一些问题。 于是开启了debug看了一下，反馈信息如下 [1249004934.093195] [2048.1] [pid=30677] Done. Final output: &#8216;/usr/local/nagios/libexec/check_http -H 58.83.184.47 -p 8080 &#8216; 显然最终输出的命令跟我想的不一样。复制了一份check_http为check_host 现在对services.cfg中进行相应的修改。 check_command check_host 重试后依然无法启动，debug提示无法找到命令。可能需要对commands进行定义。 一个典型的commands.cfg配置文件如下 # &#8216;check_snmp&#8217; command definition define command{ command_name check_snmp command_line $USER1$/check_snmp -H $HOSTADDRESS$ $ARG1$ } # &#8216;check_http&#8217; command definition define command{ command_name check_http command_line $USER1$/check_http -H $HOSTADDRESS$ -p 8080 $ARG1$ } # &#8216;check_host&#8217; command definition [...]<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios机器分组批量检测</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios和cacti排错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Nagios报错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">实践证明xampp有点肾阳虚……</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p>将nagios迁移过后又陆续添加了一些机器进去，这时候遇到一个麻烦，使用check_http无法验证网站，提示失败。<br />
但是我直接使用libexec下的文件时却能够探测的到，因为公司的check_http是根据squid改写的，所以在参数上可能有一些问题。</p>
<p><span id="more-575"></span></p>
<p>于是开启了debug看了一下，反馈信息如下</p>
<blockquote><p>[1249004934.093195] [2048.1] [pid=30677]   Done.  Final output: &#8216;/usr/local/nagios/libexec/check_http -H 58.83.184.47 -p 8080 &#8216;
</p></blockquote>
<p>显然最终输出的命令跟我想的不一样。复制了一份check_http为check_host<br />
现在对services.cfg中进行相应的修改。<br />
check_command                   check_host</p>
<p>重试后依然无法启动，debug提示无法找到命令。可能需要对commands进行定义。</p>
<p>一个典型的commands.cfg配置文件如下</p>
<blockquote><p># &#8216;check_snmp&#8217; command definition<br />
define command{<br />
        command_name    check_snmp<br />
        command_line    $USER1$/check_snmp -H $HOSTADDRESS$ $ARG1$<br />
        }</p>
<p># &#8216;check_http&#8217; command definition<br />
define command{<br />
        command_name    check_http<br />
        command_line    $USER1$/check_http -H $HOSTADDRESS$ -p 8080 $ARG1$<br />
        }</p>
<p># &#8216;check_host&#8217; command definition<br />
define command{<br />
        command_name    check_host<br />
        command_line    $USER1$/check_http -H $HOSTADDRESS$ $ARG1$<br />
        }</p></blockquote>
<p>将check_host加入后完美解决问题～！</p>
<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios机器分组批量检测</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios和cacti排错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Nagios报错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">实践证明xampp有点肾阳虚……</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></content:encoded>
			<wfw:commentRss>http://www.zhangyiqun.net/575.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>nagios和cacti排错</title>
		<link>http://www.zhangyiqun.net/514.html</link>
		<comments>http://www.zhangyiqun.net/514.html#comments</comments>
		<pubDate>Fri, 24 Jul 2009 12:02:29 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux系统]]></category>
		<category><![CDATA[cacti]]></category>
		<category><![CDATA[nagios]]></category>

		<guid isPermaLink="false">http://www.zhangyiqun.cn/?p=514</guid>
		<description><![CDATA[这几天负责迁移公司原来的nagios并在新环境重新部署cacti(原来的cacti随着raid一起死了)，服务器都是64位系统，解决lib和丢失文件的问题废了不少时间,现在把遇到的问题总结一下. 感谢深夜排错时在身边陪伴着的女友,没有你恐怕我的肩膀又要难受了. nagios迁移问题————————————————————————————————————————————— 1.启动时出现缺少/lib64/libssl.so.4时 ln -s /lib64/libssl.so.0.9.7a /lib64/libssl.so.4 ./check_mysql: error while loading shared libraries: libmysqlclient.so.15: cannot open shared object file: No such file or directory 检查/lib64和/lib vi /etc/ld.so.conf 查看链接位置是否有mysql的lib文件，编辑后需要使用ldconfig重新加载。 ln -s libmysqlclient.so.15.0.0 libmysqlclient.so.15 ln -s libmysqlclient_r.so.15.0.0 libmysqlclient_r.so.15 2.当出现Can&#8217;t locate DBI.pm perl -MCPAN -e &#8216;install DBI&#8217; That fixed it for me. And then you might need [...]<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F569.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">cacti监控错误解决</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F579.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">cacti 0.8.7e安装插件排错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Nagios报错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios机器分组批量检测</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p>这几天负责迁移公司原来的nagios并在新环境重新部署cacti(原来的cacti随着raid一起死了)，服务器都是64位系统，解决lib和丢失文件的问题废了不少时间,现在把遇到的问题总结一下.<br />
<em>感谢深夜排错时在身边陪伴着的女友,没有你恐怕我的肩膀又要难受了.</em></p>
<h3>nagios迁移问题—————————————————————————————————————————————</h3>
<p>1.启动时出现缺少/lib64/libssl.so.4时</p>
<blockquote><p>ln -s /lib64/libssl.so.0.9.7a /lib64/libssl.so.4</p>
<p>./check_mysql: error while loading shared libraries: libmysqlclient.so.15: cannot open shared object file: No such file or directory<br />
检查/lib64和/lib<br />
vi /etc/ld.so.conf 查看链接位置是否有mysql的lib文件，编辑后需要使用ldconfig重新加载。<br />
ln -s libmysqlclient.so.15.0.0 libmysqlclient.so.15<br />
ln -s libmysqlclient_r.so.15.0.0 libmysqlclient_r.so.15</p></blockquote>
<p><span id="more-514"></span><br />
2.当出现Can&#8217;t locate DBI.pm</p>
<blockquote><p>perl -MCPAN -e &#8216;install DBI&#8217;</p>
<p>That fixed it for me. And then you might need to install drivers like this (for Postgres):</p>
<p>perl -MCPAN -e &#8216;install DBD::Pg&#8217;</p>
<p>复制/usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi</p></blockquote>
<p>#当遇到perl问题最彻底的解决办法是cp原机目录</p>
<h3>nrpe自动化—————————————————————————————————————————————</h3>
<p>遇到的问题是,40台服务器配置各异,因此无法用脚本实现完全自动化(实在要写的话比较浪费时间,需要不少判断,特殊字符处理起来也比较麻烦).我下面的语句原来是写在expect中,但是执行到su 时总会报错,无奈只能一个个手工复制上去.</p>
<blockquote><p>备份原nrpe,添加新许可最后重启nrpe</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p514code9'); return false;">View Code</a> SHELL</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p5149"><td class="code" id="p514code9"><pre class="shell" style="font-family:monospace;">bak /usr/local/nagios/etc/nrpe.cfg &amp;amp;&amp;amp; sed -i &quot;s#allowed_hosts=#allowed_hosts=192.168.8.5,#g&quot; /usr/local/nagios/etc/nrpe.cfg
kill -9 `ps aux | awk '$11 ~ /nrpe/{print $2}'` &amp;amp;&amp;amp; /usr/local/nagios/bin/nrpe -c /usr/local/nagios/etc/nrpe.cfg -d</pre></td></tr></table></div>

<p>上个shell中使用bak是自己写的,如下</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p514code10'); return false;">View Code</a> SHELL</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p51410"><td class="code" id="p514code10"><pre class="shell" style="font-family:monospace;">#bak
cp -rv $1 $1.`date +%Y%m%d%H`</pre></td></tr></table></div>

</blockquote>
<h3>cacti安装问题—————————————————————————————————————————————</h3>
<p>1.检查MySQL, PHP, RRDTool, net-snmp是否安装</p>
<blockquote><p>注意，安装mysql时不可以直接./mysql_install_db ，否则无法安装。(需要bin/mysql_install_db)<br />
改组的命令usermod -G groupname user</p></blockquote>
<p>2.当进入cacti时出现The following PHP extensions are missing:<br />
* sockets</p>
<blockquote><p>Please install those PHP extensions and retry<br />
&#8211;enable-sockets<br />
在这我遇到了个很牛逼的事,把php rm 了以后php info函数居然还能用，而且还能跑应用，我彻底折服了。</p></blockquote>
<p>3.重新编译php遇到[libphp5.la] Error 1</p>
<blockquote><p>重新解压tar包即可.<br />
make过程中遇到<br />
/home/okooo/src/php-5.2.6/ext/iconv/iconv.c:2491: undefined reference to `libiconv_open</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p514code11'); return false;">View Code</a> SHELL</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p51411"><td class="code" id="p514code11"><pre class="shell" style="font-family:monospace;">sed -i 's#-lz -lm -lxml2 -lz -lm -lxml2 -lz -lm -lcrypt#&amp;amp; -liconv#' Makefile</pre></td></tr></table></div>

</blockquote>
<p>4.安装spine</p>
<blockquote><p>./configure &#8211;with-mysql=/home/okooo/apps/mysql</p></blockquote>
<p>5.cacti密码丢失</p>
<blockquote><p>mysql&gt; show databases;<br />
mysql&gt; use cacti;<br />
mysql&gt; show tables;<br />
mysql&gt; update user_auth set password=md5(&#8220;newpassword&#8221;) where id=&#8217;1&#8242;;</p></blockquote>
<p>其他:<br />
cacti里的监控脚本http://www.php-oa.com/2008/03/15/cacti.html<br />
0.8.7中自带ad ping 的脚本。http://blog.wangxianjin.cn/?p=106</p>
<h3>snmp配置————————————————————————————————————————————</h3>
<p>被监控的linux机器配置snmp<br />
/etc/snmp/snmpd.conf文件<br />
vi /etc/snmp/snmpd.conf</p>
<blockquote><p>#       sec.name  source          community<br />
com2sec notConfigUser  default       public<br />
将&#8221;comunity&#8221;字段改为你要设置的密码.比如&#8221;public&#8221;.<br />
将“default”改为“安装了cacti机器的IP”，可以看到你的snmp信息,如10.10.10.10。</p>
<p>####<br />
# Finally, grant the group read-only access to the systemview view.</p>
<p>#       group          context sec.model sec.level prefix read   write  notif<br />
access  notConfigGroup &#8220;&#8221;      any       noauth    exact  all none none<br />
将&#8221;read&#8221;字段改为all.</p>
<p>##           incl/excl subtree                          mask<br />
#view all    included  .1                               80<br />
将该行前面的&#8221;#&#8221;去掉.</p>
<p>重启<br />
service snmpd restart<br />
查看snmp的端口号<br />
[root@localhost snmp]# netstat -ln|grep 161<br />
udp        0      0 0.0.0.0:161             0.0.0.0:*</p></blockquote>
<p>测试snmp可用性</p>
<blockquote><p>snmpwalk -c public -v 2c localhost .1.3.6.1.2.1.4.20 取得IP信息</p></blockquote>
<p>这个shell用于客户机修改snmp配置并重启服务</p>
<blockquote>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p514code12'); return false;">View Code</a> SHELL</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p51412"><td class="code" id="p514code12"><pre class="shell" style="font-family:monospace;">yum -y install net-snmp &amp;amp;&amp;amp; sed -i &quot;s#agentaddress 192.168.8.34#agentaddress `ifconfig eth1 | awk '$1 ~ /inet/{print $2}' | sed -n 's#addr:##p'`#&quot; /etc/snmp/snmpd.conf &amp;amp;&amp;amp; service snmpd restart</pre></td></tr></table></div>

</blockquote>
<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F569.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">cacti监控错误解决</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F579.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">cacti 0.8.7e安装插件排错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Nagios报错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios机器分组批量检测</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></content:encoded>
			<wfw:commentRss>http://www.zhangyiqun.net/514.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>实践证明xampp有点肾阳虚……</title>
		<link>http://www.zhangyiqun.net/230.html</link>
		<comments>http://www.zhangyiqun.net/230.html#comments</comments>
		<pubDate>Mon, 20 Apr 2009 16:12:02 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux系统]]></category>
		<category><![CDATA[nagios]]></category>
		<category><![CDATA[nrpe]]></category>
		<category><![CDATA[xampp]]></category>

		<guid isPermaLink="false">http://www.zhangyiqun.cn/?p=230</guid>
		<description><![CDATA[xampp是www.apachefriends.org出的一个工具，用来快速搭建AMP的实验环境。各个平台的版本都有，深受广大人民群众的喜爱。 装nrpe的时候报错了 checking for SSL headers&#8230; configure: error: Cannot find ssl headers 从nrpe的configure中截取一段代码来说明这个问题 echo $ECHO_N &#8220;checking for SSL headers&#8230; $ECHO_C&#8221; &#62;&#38;6         found_ssl=no         for dir in $ssl_inc_dir $ssl_dir /usr/local/openssl /usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr /usr/freeware/lib/openssl; do                 ssldir=&#8221;$dir&#8221;            [...]<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Nagios报错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">自建nagios命令</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios和cacti排错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios机器分组批量检测</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p>xampp是www.apachefriends.org出的一个工具，用来快速搭建AMP的实验环境。各个平台的版本都有，深受广大人民群众的喜爱。</p>
<p>装nrpe的时候报错了</p>
<blockquote><p>checking for SSL headers&#8230; configure: error: Cannot find ssl headers</p></blockquote>
<p>从nrpe的configure中截取一段代码来说明这个问题<br />
<span id="more-230"></span></p>
<blockquote><p>echo $ECHO_N &#8220;checking for SSL headers&#8230; $ECHO_C&#8221; &gt;&amp;6</p>
<p>        found_ssl=no</p>
<p>        for dir in $ssl_inc_dir $ssl_dir /usr/local/openssl /usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr /usr/freeware/lib/openssl; do</p>
<p>                ssldir=&#8221;$dir&#8221;</p>
<p>                if test -f &#8220;$dir/include/openssl/ssl.h&#8221;; then</p>
<p>                        found_ssl=yes</p>
<p>                        CFLAGS=&#8221;$CFLAGS -I$dir/include/openssl -I$ssldir/include&#8221;</p>
<p>                        sslincdir=&#8221;$dir/include/openssl&#8221;</p>
<p>                        break</p>
<p>                fi</p>
<p>                if test -f &#8220;$dir/include/ssl.h&#8221;; then</p>
<p>                        found_ssl=yes</p>
<p>                        CFLAGS=&#8221;$CFLAGS -I$dir/include&#8221;</p>
<p>                        sslincdir=&#8221;$dir/include&#8221;</p>
<p>                        break</p>
<p>                fi</p>
<p>                if test -f &#8220;$dir/ssl.h&#8221;; then</p>
<p>                        found_ssl=yes</p>
<p>                        CFLAGS=&#8221;$CFLAGS -I$dir&#8221;</p>
<p>                        sslincdir=&#8221;$dir&#8221;</p>
<p>                        ssldir=&#8221;$dir/..&#8221;</p>
<p>                        break</p>
<p>                fi</p>
<p>                if test -f &#8220;$dir/openssl/ssl.h&#8221;; then</p>
<p>                        found_ssl=yes</p>
<p>                        CFLAGS=&#8221;$CFLAGS -I$dir/openssl&#8221;</p>
<p>                        sslincdir=&#8221;$dir/openssl&#8221;</p>
<p>                        ssldir=&#8221;$dir/..&#8221;</p>
<p>                        break</p>
<p>                fi</p>
<p>        done</p>
<p> </p>
<p>        if test x_$found_ssl != x_yes; then</p>
<p>                { { echo &#8220;$as_me:$LINENO: error: Cannot find ssl headers&#8221; &gt;&amp;5</p></blockquote>
<p>主要看test -f后面的内容，发现全是openssl-devel中的玩意，所以解决方法就是</p>
<p>yum install openssl-devel</p>
<p>期待xampp出个十全大补丸补丁，方面懒人使用，哈哈哈。</p>
<p class="MsoNormal"><span>1、除特别说明外，本博客内容皆为原创，可以自由转载传播，但请署名及注明出处，不尊重别人劳动成果的不欢迎；</span></p>
<p><span>2、本博客内容遵守“</span><a href="http://creativecommons.org/licenses/by-nc-nd/2.5/cn/" target="_blank"><span>署名-非商业性使用-禁止演绎 2.5 中国大陆</span></a><span>”协议；</span></p>
<p style="margin:0;padding:0;height:1px;overflow:hidden;">
    <script type="text/javascript"><!--
        var wumiiSitePrefix = "http://www.zhangyiqun.net";
        var wumiiEnableCustomPos = false;
        var wumiiParams = "&#038;num=4&#038;mode=3&#038;displayInFeed=1&#038;version=1.0.5.5&#038;pf=WordPress3.2.1";
    //--></script><script type="text/javascript" src="http://widget.wumii.com/ext/relatedItemsWidget.htm"></script><a href="http://www.wumii.com/widget/relatedItems.htm" style="border:0;"><img src="http://static.wumii.com/images/pixel.png" alt="无觅相关文章插件，快速提升流量" style="border:0;padding:0;margin:0;" /></a></p>
<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F809.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Nagios报错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F575.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">自建nagios命令</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F514.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios和cacti排错</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F680.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F230.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">nagios机器分组批量检测</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></content:encoded>
			<wfw:commentRss>http://www.zhangyiqun.net/230.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Page Caching using disk: enhanced

Served from: www.zhangyiqun.net @ 2012-02-07 22:47:50 -->
