<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:st1="urn:schemas-microsoft-com:office:smarttags" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=Content-Type content="text/html; charset=us-ascii">
<meta name=ProgId content=Word.Document>
<meta name=Generator content="Microsoft Word 10">
<meta name=Originator content="Microsoft Word 10">
<link rel=File-List href="cid:filelist.xml@01C30B46.0FC634D0">
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
name="time"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
name="date"/>
<!--[if gte mso 9]><xml>
<o:OfficeDocumentSettings>
<o:DoNotRelyOnCSS/>
</o:OfficeDocumentSettings>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:WordDocument>
<w:SpellingState>Clean</w:SpellingState>
<w:GrammarState>Clean</w:GrammarState>
<w:DocumentKind>DocumentEmail</w:DocumentKind>
<w:EnvelopeVis/>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
</w:WordDocument>
</xml><![endif]--><!--[if !mso]>
<style>
st1\:*{behavior:url(#default#ieooui) }
</style>
<![endif]-->
<style>
<!--
/* Font Definitions */
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;
mso-font-charset:0;
mso-generic-font-family:swiss;
mso-font-pitch:variable;
mso-font-signature:1627421319 -2147483648 8 0 66047 0;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{mso-style-parent:"";
margin:0in;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:"Times New Roman";
mso-fareast-font-family:"Times New Roman";}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;
text-underline:single;}
a:visited, span.MsoHyperlinkFollowed
{color:purple;
text-decoration:underline;
text-underline:single;}
pre
{margin:0in;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.0pt;
font-family:"Courier New";
mso-fareast-font-family:"Times New Roman";
color:black;}
span.EmailStyle18
{mso-style-type:personal;
mso-style-noshow:yes;
mso-ansi-font-size:10.0pt;
mso-bidi-font-size:10.0pt;
font-family:Arial;
mso-ascii-font-family:Arial;
mso-hansi-font-family:Arial;
mso-bidi-font-family:Arial;
color:windowtext;}
span.EmailStyle19
{mso-style-type:personal-reply;
mso-style-noshow:yes;
mso-ansi-font-size:10.0pt;
mso-bidi-font-size:10.0pt;
font-family:Arial;
mso-ascii-font-family:Arial;
mso-hansi-font-family:Arial;
mso-bidi-font-family:Arial;
color:navy;}
span.SpellE
{mso-style-name:"";
mso-spl-e:yes;}
span.GramE
{mso-style-name:"";
mso-gram-e:yes;}
@page Section1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;
mso-header-margin:.5in;
mso-footer-margin:.5in;
mso-paper-source:0;}
div.Section1
{page:Section1;}
-->
</style>
<!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.0pt;
font-family:"Times New Roman";}
</style>
<![endif]-->
</head>
<body lang=EN-US link=blue vlink=purple style='tab-interval:.5in'>
<div class=Section1>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>Well I seem to have answered my own
question by trying it.<span style='mso-spacerun:yes'> </span>For each
host in my second example… it will pull that $HOSTADDRESS$ from the
respective host definition.<span style='mso-spacerun:yes'> </span>I may
be back with more obvious <span class=SpellE>whizbang</span> questions like
this one when I start implementing custom check commands and try to pass
similar variables.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>--<span class=SpellE><span class=GramE>aaron</span></span><o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Tahoma><span
style='font-size:10.0pt;font-family:Tahoma'>-----Original Message-----<br>
<b><span style='font-weight:bold'>From:</span></b> Aaron Sonntag <br>
<b><span style='font-weight:bold'>Sent:</span></b> </span></font><st1:date
Month="4" Day="25" Year="2003"><font size=2 face=Tahoma><span style='font-size:
10.0pt;font-family:Tahoma'>Friday, April 25, 2003</span></font></st1:date><font
size=2 face=Tahoma><span style='font-size:10.0pt;font-family:Tahoma'> </span></font><st1:time
Hour="15" Minute="24"><font size=2 face=Tahoma><span style='font-size:10.0pt;
font-family:Tahoma'>3:24 PM</span></font></st1:time><font size=2 face=Tahoma><span
style='font-size:10.0pt;font-family:Tahoma'><br>
<b><span style='font-weight:bold'>To:</span></b> nagios-users@lists.sourceforge.net<br>
<b><span style='font-weight:bold'>Subject:</span></b> [Nagios-users]
hostaddress variable use in services file?</span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=3 face="Times New Roman"><span
style='font-size:12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'>I have a group of hosts that are
webservers.<span style='mso-spacerun:yes'> </span>I want to run the
check_http command against multiple hosts.<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'>This is an example from the
documentation of multiple hosts service entry:<o:p></o:p></span></font></p>
<pre style='margin-left:.5in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt'><span style='mso-tab-count:1'> </span>define <i><span
style='font-style:italic'>service</span></i>{<o:p></o:p></span></font></pre><pre
style='margin-left:.5in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt'><span style='mso-tab-count:2'> </span></span></font><font
color=red><span style='color:red'>host_name<span style='mso-tab-count:2'> </span><i><span
style='font-style:italic'>HOST1,HOST2,HOST3,...,HOSTN</span></i></span></font><o:p></o:p></pre><pre
style='margin-left:.5in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt'><span style='mso-tab-count:2'> </span></span></font><font
color=red><span style='color:red'>service_description<span style='mso-tab-count:
1'> </span><i><span style='font-style:italic'>SOMESERVICE</span></i></span></font><o:p></o:p></pre><pre
style='margin-left:.5in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt'><span style='mso-tab-count:2'> </span><i><span
style='font-style:italic'>other service directives</span></i> ....<o:p></o:p></span></font></pre><pre
style='margin-left:.5in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt'><span style='mso-tab-count:2'> </span>}<o:p></o:p></span></font></pre>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'>Many commands like check_http have a
$HOSTADDRESS$ variable.<span style='mso-spacerun:yes'> </span>Is that
somehow pulled from the host definition entry?<span
style='mso-spacerun:yes'> </span>If so then the example below will
work.<span style='mso-spacerun:yes'> </span>If not then I have to make a
service entry for every host because hostaddress is different for every host.<o:p></o:p></span></font></p>
<pre style='margin-left:.5in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt'><span style='mso-tab-count:1'> </span>define <i><span
style='font-style:italic'>service</span></i>{<o:p></o:p></span></font></pre><pre
style='margin-left:.5in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt'><span style='mso-tab-count:2'> </span></span></font><font
color=red><span style='color:red'>host_name<span style='mso-tab-count:2'> </span><i><span
style='font-style:italic'>HOST1,HOST2,HOST3,...,HOSTN</span></i></span></font><o:p></o:p></pre><pre
style='margin-left:.5in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt'><span style='mso-tab-count:2'> </span></span></font><font
color=red><span style='color:red'>service_description<span style='mso-tab-count:
1'> </span>HTTP<o:p></o:p></span></font></pre><pre
style='margin-left:.5in'><font size=2 color=red face="Courier New"><span
style='font-size:10.0pt;color:red'><span style='mso-tab-count:2'> </span>check_command<span
style='mso-tab-count:2'> </span>check_http</span></font><o:p></o:p></pre><pre
style='margin-left:.5in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt'><span style='mso-tab-count:2'> </span><i><span
style='font-style:italic'>other service directives</span></i> ....<o:p></o:p></span></font></pre><pre
style='margin-left:.5in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt'><span style='mso-tab-count:2'> </span>}<o:p></o:p></span></font></pre>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'>Do I have to make a different
service definition for each host because the hostaddress is different?<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'>Thanks<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'>--aaron<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-left:.5in'><font size=2 face=Arial><span
style='font-size:10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
</div>
</body>
</html>