<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Have I properly configured advanced conditional attributes for my alert in savedsearches.conf? in Alerting</title>
    <link>https://community.splunk.com/t5/Alerting/Have-I-properly-configured-advanced-conditional-attributes-for/m-p/233752#M4358</link>
    <description>&lt;P&gt;Hi @KolGr001,&lt;BR /&gt;
"Counttype" should not be specified if you are using an "alert_condition" in savedsearches.conf.&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/6.3.1/Admin/Savedsearchesconf"&gt;http://docs.splunk.com/Documentation/Splunk/6.3.1/Admin/Savedsearchesconf&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;The spec file mentions that, if you include an alert_condition, you should not set counttype, relation, or quantity. I've corrected a discrepancy in older versions of our documentation that stated otherwise. &lt;/P&gt;

&lt;P&gt;Hope this helps! &lt;/P&gt;</description>
    <pubDate>Sat, 14 Nov 2015 01:47:03 GMT</pubDate>
    <dc:creator>frobinson_splun</dc:creator>
    <dc:date>2015-11-14T01:47:03Z</dc:date>
    <item>
      <title>Have I properly configured advanced conditional attributes for my alert in savedsearches.conf?</title>
      <link>https://community.splunk.com/t5/Alerting/Have-I-properly-configured-advanced-conditional-attributes-for/m-p/233751#M4357</link>
      <description>&lt;P&gt;This is the first time I am using an advanced conditional alert in savedsearches.conf.  &lt;/P&gt;

&lt;P&gt;I'd like to get some feedback about current configurations I have around monitoring scheduled jobs.&lt;/P&gt;

&lt;P&gt;If a job is hung for x amount of time, the alert should kick off, however one was manually suspended last night and nothing came out.  Here is a sample of my savedsearches.conf along with a sample of the search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[alert]
action.email.inline = 1
action.script = 1
action.script.filename = email_alert.sh
alert.digest_mode = True
alert.expires = 24h
alert.suppress = 0
alert.track = 1
**alert_condition = | where last_run_ago_seconds&amp;gt;7200
counttype = custom**
cron_schedule = 00 09,10,11,12,13,14,15,16,17,18,19,20,21,22 * * *
displayview = flashtimeline
enableSched = 1
search = index=index earliest=-60m@m latest=@m sourcetype=blah &amp;lt;servicenamehere&amp;gt; | head 100 | stats latest(_time) as last_seen, first(host) as host_start by service | addinfo | eval last_run_ago_seconds=round( info_search_time-last_seen ) | stats min(last_run_ago_seconds) as last_run_ago_seconds, values(host_start) as host_start by service | fillnull value="n/a" host_start  | eval message=if(last_run_ago_seconds&amp;gt;7200, "This Job May Be Hung", "Job Looks OK") | table service,last_run_ago_seconds,host_start,message
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;When I run the search manually things look OK, but I want to make sure my use of alert_condition and counttype are correct.  Or, if there is another way of kicking off a similar alert I am open to suggestions.&lt;/P&gt;

&lt;P&gt;Thanks in advance!&lt;/P&gt;</description>
      <pubDate>Thu, 12 Nov 2015 15:01:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Have-I-properly-configured-advanced-conditional-attributes-for/m-p/233751#M4357</guid>
      <dc:creator>_gkollias</dc:creator>
      <dc:date>2015-11-12T15:01:37Z</dc:date>
    </item>
    <item>
      <title>Re: Have I properly configured advanced conditional attributes for my alert in savedsearches.conf?</title>
      <link>https://community.splunk.com/t5/Alerting/Have-I-properly-configured-advanced-conditional-attributes-for/m-p/233752#M4358</link>
      <description>&lt;P&gt;Hi @KolGr001,&lt;BR /&gt;
"Counttype" should not be specified if you are using an "alert_condition" in savedsearches.conf.&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/6.3.1/Admin/Savedsearchesconf"&gt;http://docs.splunk.com/Documentation/Splunk/6.3.1/Admin/Savedsearchesconf&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;The spec file mentions that, if you include an alert_condition, you should not set counttype, relation, or quantity. I've corrected a discrepancy in older versions of our documentation that stated otherwise. &lt;/P&gt;

&lt;P&gt;Hope this helps! &lt;/P&gt;</description>
      <pubDate>Sat, 14 Nov 2015 01:47:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Have-I-properly-configured-advanced-conditional-attributes-for/m-p/233752#M4358</guid>
      <dc:creator>frobinson_splun</dc:creator>
      <dc:date>2015-11-14T01:47:03Z</dc:date>
    </item>
  </channel>
</rss>

