<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" 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 12 (filtered medium)">
<style>
<!--
/* Font Definitions */
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
span.E-MailFormatvorlage17
{mso-style-type:personal-reply;
font-family:"Calibri","sans-serif";
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;}
.MsoPapDefault
{mso-style-type:export-only;
mso-margin-top-alt:auto;
mso-margin-bottom-alt:auto;}
@page Section1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 2.0cm 70.85pt;}
div.Section1
{page:Section1;}
-->
</style>
<!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang=DE link=blue vlink=purple>
<div class=Section1>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:#1F497D'>Try<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal>define command {<br>
command_name
check_s1<br>
command_line
$USER1$/check_http -H <a href="http://www.site1.com">www.site1.com</a> -I
$HOSTADDRESS$ -w "$ARG1$" -c "$ARG2$"<br>
}<br>
<br>
<span style='font-size:10.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p></o:p></span></p>
<p class=MsoNormal><o:p> </o:p></p>
<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'>
<p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>Von:</span></b><span
style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> lance raymond
[mailto:lance.raymond@gmail.com] <br>
<b>Gesendet:</b> Donnerstag, 22. Oktober 2009 15:17<br>
<b>An:</b> nagios-users@lists.sourceforge.net<br>
<b>Betreff:</b> Re: [Nagios-users] 1st post,so naturally the 1st question by
the nagios newb re: socket error<o:p></o:p></span></p>
</div>
<p class=MsoNormal><o:p> </o:p></p>
<p class=MsoNormal style='mso-margin-top-alt:auto;margin-bottom:12.0pt'>I
haven't installed anything on the webservers (yet), but I do wish to via snmp
do load, cpu, etc. or if there is a better way like a client daemon, feel free
to let me know. I am still reading/understanding what each is used for
(service.cfg, commands.cfg, etc.) but I have the following all for that check;<br>
<br>
services.cfg<br>
define service {<br>
service_description
check_s1<br>
use
generic-service<br>
hostgroup_name
s1_WebServers<br>
check_command
check_s1!3!5<br>
}<br>
<br>
check_commands.cfg<br>
define command {<br>
command_name
check_s1<br>
command_line
$USER1$/check_http -H <a href="http://www.site1.com">www.site1.com</a> -w
"$ARG1$" -c "$ARG2$"<br>
}<br>
<br>
command.cfg has;<br>
command[check_s1]=/usr/local/groundwork/nagios/libexec/check_http -H <a
href="http://www.site1.com">www.site1.com</a> -I $HOSTADDRESS$<br>
<br>
As for where the local command was run, yes it was local to the groundwork
(nagios) server from the following location;<br>
<br>
root@groundwork:/usr/local/groundwork/nagios/libexec/check_http -H <a
href="http://www.site1.com">www.site1.com</a> -I 192.168.50.101<br>
HTTP OK HTTP/1.1 200 OK - 14351 bytes in 0.249 seconds
|time=0.249456s;;;0.000000 size=14351B;;;0<br>
<br>
I am not sure what the NRPE plugin is but just looking at the options, it looks
like it's run on the client as there is no spot for IP, when run local it
simply says connection refused by host for the <a href="http://site1.com">site1.com</a>
domain.<br>
<br>
Thanks.<o:p></o:p></p>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'>On
Thu, Oct 22, 2009 at 4:59 AM, Martin Melin <<a href="mailto:mmelin@gmail.com">mmelin@gmail.com</a>>
wrote:<o:p></o:p></p>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'>Hi,<o:p></o:p></p>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'><o:p> </o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'>Where
did you define the check_s1 command? On which host? It looks like an NRPE
config so is this on one of the web servers or on your Nagios host?<o:p></o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'><o:p> </o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'>Where
did you try running the command from the shell? On the Nagios host or the web
server?<o:p></o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'><o:p> </o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'>Please
show the command definition from Nagios for check_s1 as well.<o:p></o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'><o:p> </o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'>Make
sure that you've edited the correct NRPE config file, reloaded nrped if you're
not using inetd. To check that
the check works from the command line, run the check_nrpe command from Nagios, not check_http from Nagios or the webserver.<o:p></o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'><o:p> </o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'>Regards,<o:p></o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'>Martin
Melin<o:p></o:p></p>
</div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'><o:p> </o:p></p>
<div>
<div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'>On
Thu, Oct 22, 2009 at 3:32 AM, lance raymond <<a
href="mailto:lance.raymond@gmail.com" target="_blank">lance.raymond@gmail.com</a>>
wrote:<o:p></o:p></p>
</div>
</div>
<blockquote style='border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;
margin-left:4.8pt;margin-right:0cm'>
<div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;margin-bottom:12.0pt'>Hi all,
well I am running GroundWork open source and really happy with the layout, etc.
and now comes the nagios things. My goal is to setup things neatly,
organized and learn as I go rather than asking stupid q's along the way.
So with that, the 1st task;<br>
<br>
I have 8 webservers all host numerous sites, a few host only select. So I
have created some hostgroups, adding the servers that belong to each, and
wonderfully it works. I can select a server, see the group, click the
group, see the servers (did I mention I'm good) :)<br>
<br>
Anyway, I want to setup 2 seperate checks one for each website, then associate
them with the groups, so for example;<br>
ws1 (site1, site2)<br>
ws2 (site1)<br>
ws3 (site1, site2)<br>
ws4 (site2)<br>
<br>
Pretty simple. So I copied the check_http command where I saw it used and
have the following;<br>
<br>
command[check_http]=/usr/local/groundwork/nagios/libexec/check_http -H
$HOSTADDRESS$ -I $HOSTADDRESS$<br>
command[check_s1]=/usr/local/groundwork/nagios/libexec/check_http -H <a
href="http://www.site1.com" target="_blank">www.site1.com</a> -I $HOSTADDRESS$<br>
command[check_s2]=/usr/local/groundwork/nagios/libexec/check_http -H <a
href="http://www.site2.com" target="_blank">www.site2.com</a> -I $HOSTADDRESS$<br>
<br>
The services.cfg has the following (will only show 1 for space)<br>
<br>
define service {<br>
service_description check_s1<br>
use
generic-service<br>
hostgroup_name
s1_WebServers<br>
check_command check_s1!3!5<br>
}<br>
<br>
Now after the above setup and a restart, I have happy to see the check_s1
listed but it's showing critical with the following error;<br>
CRITICAL - Socket timeout after 10 seconds <br>
<br>
At the command line check it does work;<br>
./check_http -H <a href="http://www.site1.com" target="_blank">www.site1.com</a>
-I 192.168.50.101<br>
HTTP OK HTTP/1.1 200 OK - 14398 bytes in 0.090 seconds
|time=0.089949s;;;0.000000 size=14398B;;;0<br>
<br>
I am looking through where people are increasing the timeout, but the response
time is not even a second, so there must be something else I am missing.
So I am looking forward to learning more, welcome any ideas, suggestions, or
anything else I should know about using nagios under groundwork.<br>
<br>
This is running under ubuntu-8.10 server, Program Version:3.0.6, let me know
what else I can or need to provide on this.<br>
<br>
<o:p></o:p></p>
</div>
</div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'>------------------------------------------------------------------------------<br>
Come build with us! The BlackBerry(R) Developer Conference in SF, CA<br>
is the only developer event you need to attend this year. Jumpstart your<br>
developing skills, take BlackBerry mobile applications to market and stay<br>
ahead of the curve. Join us from November 9 - 12, 2009. Register now!<br>
<a href="http://p.sf.net/sfu/devconference" target="_blank">http://p.sf.net/sfu/devconference</a><br>
_______________________________________________<br>
Nagios-users mailing list<br>
<a href="mailto:Nagios-users@lists.sourceforge.net" target="_blank">Nagios-users@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/nagios-users"
target="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</a><br>
::: Please include Nagios version, plugin version (-v) and OS when reporting any
issue.<br>
::: Messages without supporting info will risk being sent to /dev/null<o:p></o:p></p>
</blockquote>
</div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'><o:p> </o:p></p>
</div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'><br>
------------------------------------------------------------------------------<br>
Come build with us! The BlackBerry(R) Developer Conference in SF, CA<br>
is the only developer event you need to attend this year. Jumpstart your<br>
developing skills, take BlackBerry mobile applications to market and stay<br>
ahead of the curve. Join us from November 9 - 12, 2009. Register now!<br>
<a href="http://p.sf.net/sfu/devconference" target="_blank">http://p.sf.net/sfu/devconference</a><br>
_______________________________________________<br>
Nagios-users mailing list<br>
<a href="mailto:Nagios-users@lists.sourceforge.net">Nagios-users@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/nagios-users"
target="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</a><br>
::: Please include Nagios version, plugin version (-v) and OS when reporting
any issue.<br>
::: Messages without supporting info will risk being sent to /dev/null<o:p></o:p></p>
</div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'><o:p> </o:p></p>
</div>
<br/><br/><br/><br/><span style="font-size:8pt; color:#808080; font-family:Arial">OOe. Gesundheits- und Spitals-AG<br/>Techcenter, Hafenstrasse 47-51, 4020 Linz<br/>DVR 2107870, ATU 51928204, Firmenbuchgericht: Landesgericht Linz, FN 210146 p</span><br/></body>
</html>