<div dir="ltr"><div><div><div>From what I can tell, after trying it, the query string appended to the splunk_url parameter referneces Nagios specific things...<br><br></div>e.g.  https://<b>splunk_url</b>/?q=search?%20<b>hostname</b>%20<b>Nagios_command_description<br>
<br></b></div>So, the implication is that somehow splunk has data about nagios checks, by name.<br><br>For my environment, splunk uses short names.  We set this up to avoid having a mix of both short names and fqdns in the host field since most of our splunk data is sourced from syslog which doesn't provide fqdn.  Because of this clicking the link for this in Nagios would result in splunk on the FQDN and producing no results.<br>
<br></div>The other issue is that at this point, splunk has no data about nagios checks, so searching the check name, also does nothing for us.  So I hope you can see why I'm confused about the purpose of this integration.<br>
</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Sep 10, 2013 at 3:12 PM, Frost, Mark {BIS} <span dir="ltr"><<a href="mailto:mark.frost1@pepsico.com" target="_blank">mark.frost1@pepsico.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">





<div link="blue" vlink="purple" lang="EN-US">
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Huh.   Where did those new options come from?  They weren’t in the cgi.cfg docs the last time I looked
</span><span style="font-size:11.0pt;font-family:Wingdings;color:#1f497d">J</span><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">I agree, it’s not terribly clear to me what that option does, but it does reference “Splunk IT” which is a special Splunk package that you can use for Splunk
 benchmarking.   That still doesn’t make it clear what it’s used for.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">I see a second parameter, “splunk_url” that lets you specify the URL for your Splunk server.<u></u><u></u></span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Maybe it just somehow says to pepper the logs with your Splunk URL in appropriate places.<u></u><u></u></span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Mark<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal" style="margin-left:.5in"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> Sean Alderman [mailto:<a href="mailto:salderman1@udayton.edu" target="_blank">salderman1@udayton.edu</a>]
<br>
<b>Sent:</b> Tuesday, September 10, 2013 1:34 PM<br>
<b>To:</b> Nagios Users List</span></p><div class="im"><br>
<b>Subject:</b> Re: [Nagios-users] Splunk Integration Question...<u></u><u></u></div><p></p>
<p class="MsoNormal" style="margin-left:.5in"><u></u> <u></u></p>
<p style="margin-left:.5in">Just what's in the nagios doc on CGI.cfg. The doc is lacking about what it does, so I guess I'm a little curious what that config is about.<u></u><u></u></p><div><div class="h5">
<p style="margin-left:.5in">- Sean Alderman <br>
Senior Engineer, UDit Systems Integration<u></u><u></u></p>
<p style="margin-left:.5in">This message had been brought to you by Android Bionic.<u></u><u></u></p>
<div>
<p class="MsoNormal" style="margin-left:.5in">On Sep 10, 2013 1:10 PM, "Frost, Mark {BIS}" <<a href="mailto:mark.frost1@pepsico.com" target="_blank">mark.frost1@pepsico.com</a>> wrote:<u></u><u></u></p>
<div>
<div>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Sean,</span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Can you describe what you’re doing for Splunk integration with Nagios?   I’ve used Splunk with Nagios in a couple different ways, but I’m not aware of any single standard for doing
 so.</span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Originally, I just had Splunk run a scheduled search, which would trigger a script which sent a passive check result back to a Nagios service via NSCA.   That way – having Nagios
 process passive check results from Splunk – was the only way I could see to do that.</span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Recently, I played around a bit with writing scripts that made use of Splunk’s REST API so the checks could be run as active checks from Nagios.  (I always prefer active checks).  
 I set this up for only one check, but once I got it working it worked pretty well.</span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">As a side note, I’m still a little on the fence about whether or not I really want to have Nagios find problems through Splunk and then alert on them or have Splunk find an alert
 on them directly without using Nagios at all…</span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Are you referring to another way of making Splunk and Nagios talk together?</span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Mark</span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:.5in">
<span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:1.0in">
<b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> Sean Alderman [mailto:<a href="mailto:salderman1@udayton.edu" target="_blank">salderman1@udayton.edu</a>]
<br>
<b>Sent:</b> Monday, September 09, 2013 1:12 PM<br>
<b>To:</b> <a href="mailto:nagios-users@lists.sourceforge.net" target="_blank">nagios-users@lists.sourceforge.net</a><br>
<b>Subject:</b> [Nagios-users] Splunk Integration Question...</span><u></u><u></u></p>
<p class="MsoNormal" style="margin-left:1.0in">
 <u></u><u></u></p>
<div>
<div>
<div>
<div>
<p class="MsoNormal" style="margin-left:1.0in">
Greetings,<u></u><u></u></p>
</div>
<p class="MsoNormal" style="margin-bottom:12.0pt;margin-left:1.0in">
  I was hoping I might find someone who's got the splunk integration actively working.  I'm running Nagios Core (via EPEL) and Splunk 5.0.3 on OracleLinux 6.4.<u></u><u></u></p>
</div>
<p class="MsoNormal" style="margin-left:1.0in">
   When I edit cgi.cfg and enable splunk integration, then set the splunk URL to <a href="https://%3cmysplunkserver%3e:8000/en-US/app/search/flastimeline" target="_blank">
https://<mysplunkserver>:8000/en-US/app/search/flastimeline</a>, I notice the nagios URLs look like: https://<mysplunkserver>:8000/en-US/app/flashtimeline?q=search%<a href="http://20test1.udayton.edu" target="_blank">20test1.udayton.edu</a>%20<nagios plugin
 check>.  I have two questions...<u></u><u></u></p>
<p class="MsoNormal" style="margin-left:1.5in">
<span style="font-size:10.0pt;font-family:Symbol">·</span><span style="font-size:7.0pt">        
</span>Is there a way I can make nagios use the hostname only, not the FQDN?  We use short names in splunk so we don't a mix of fqdn and short names since we use both forwarders and syslog as input.<u></u><u></u></p>

<p class="MsoNormal" style="margin-left:1.5in">
<span style="font-size:10.0pt;font-family:Symbol">·</span><span style="font-size:7.0pt">        
</span>What data is this query looking for, is it expected that I should have my nagios log in splunk?  The <nagios plugin check> in the query doesn't seem useful to me, unless there's splunk data specifically tied to that check, and I'm hoping someone could
 provide an example.<br clear="all">
<u></u><u></u></p>
</div>
<div>
<div>
<div>
<div>
<p class="MsoNormal" style="margin-left:1.0in">
Kind regards,<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:1.0in">
-- <u></u><u></u></p>
<div>
<p class="MsoNormal" style="margin-bottom:12.0pt;margin-left:1.0in">
Sean M. Alderman<br>
Senior Engineer, UDit Systems Integration and Engineering<br>
University of Dayton<u></u><u></u></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<p class="MsoNormal" style="margin-left:.5in"><br>
------------------------------------------------------------------------------<br>
How ServiceNow helps IT people transform IT departments:<br>
1. Consolidate legacy IT systems to a single system of record for IT<br>
2. Standardize and globalize service processes across IT<br>
3. Implement zero-touch automation to replace manual, redundant tasks<br>
<a href="http://pubads.g.doubleclick.net/gampad/clk?id=51271111&iu=/4140/ostg.clktrk" target="_blank">http://pubads.g.doubleclick.net/gampad/clk?id=51271111&iu=/4140/ostg.clktrk</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<u></u><u></u></p>
</div>
</div></div></div>
</div>

<br>------------------------------------------------------------------------------<br>
How ServiceNow helps IT people transform IT departments:<br>
1. Consolidate legacy IT systems to a single system of record for IT<br>
2. Standardize and globalize service processes across IT<br>
3. Implement zero-touch automation to replace manual, redundant tasks<br>
<a href="http://pubads.g.doubleclick.net/gampad/clk?id=51271111&iu=/4140/ostg.clktrk" target="_blank">http://pubads.g.doubleclick.net/gampad/clk?id=51271111&iu=/4140/ostg.clktrk</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<br></blockquote></div><br><br clear="all"><br>-- <br><div dir="ltr">Sean M. Alderman<br>Senior Engineer, UDit Systems Integration and Engineering<br>
University of Dayton<br>300 College Park<br>Dayton, Ohio 45469-1530<br><a>(937) 229-5088</a><br><a href="mailto:salderman1@udayton.edu" target="_blank">salderman1@udayton.edu</a><br><br><i>"We are not some casual and meaningless product of evolution. Each 
of us is the result of a thought of God. Each of us is willed. Each of 
us is loved. Each of us is necessary."</i>  - BXVI<br><br></div>
</div>