<?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: Interval not working on script in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75002#M15324</link>
    <description>&lt;P&gt;Did you pay attention to the indentation level when you modified the script? Python interprets different indentation levels differently. The &lt;CODE&gt;time.sleep&lt;/CODE&gt; line should be one level "up" (= less indentation) than the &lt;CODE&gt;ipsLogger.info&lt;/CODE&gt; line. This should make the script sleep for 300 seconds after each run of its main loop.&lt;/P&gt;

&lt;P&gt;You don't need to restart Splunk, scripts are called directly each time they're run rather than being kept in memory.&lt;/P&gt;</description>
    <pubDate>Fri, 15 Jun 2012 10:48:56 GMT</pubDate>
    <dc:creator>Ayn</dc:creator>
    <dc:date>2012-06-15T10:48:56Z</dc:date>
    <item>
      <title>Why is interval not working on script?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/74998#M15320</link>
      <description>&lt;P&gt;We're running a script that's used in the CiscoIPS app to pull event data from our IPS. Initially the interval was set at 1 (should be every 1 second) which was hitting our IPS more than we'd like. We then changed it to 300 (should be every 5 minutes), however after restarting both splunk services, it's still hitting the IPS every second. Any ideas?&lt;/P&gt;</description>
      <pubDate>Mon, 05 Jun 2023 14:10:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/74998#M15320</guid>
      <dc:creator>hortonew</dc:creator>
      <dc:date>2023-06-05T14:10:25Z</dc:date>
    </item>
    <item>
      <title>Re: Interval not working on script</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/74999#M15321</link>
      <description>&lt;P&gt;The script used by the Cisco IPS addon is actually running indefinitely once it's been started, so it won't matter what interval you will set for it to run. The timing is performed internally instead. I had a quick look at the script (&lt;CODE&gt;get_ips_feed.py&lt;/CODE&gt;) and it seems there is no pause between its requests at all - once it's done with one connection it just keeps hammering away with the next.&lt;/P&gt;

&lt;P&gt;You could modify the script to sleep at the end of its while loop, one suggestion would be to add a &lt;CODE&gt;time.sleep(300)&lt;/CODE&gt; after &lt;CODE&gt;ipsLogger.info(syslog_msg)&lt;/CODE&gt; (line 231).&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jun 2012 11:44:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/74999#M15321</guid>
      <dc:creator>Ayn</dc:creator>
      <dc:date>2012-06-14T11:44:07Z</dc:date>
    </item>
    <item>
      <title>Re: Interval not working on script</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75000#M15322</link>
      <description>&lt;P&gt;Thanks for the reply.  I'll give it a shot and let you know how it goes.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jun 2012 11:58:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75000#M15322</guid>
      <dc:creator>hortonew</dc:creator>
      <dc:date>2012-06-14T11:58:51Z</dc:date>
    </item>
    <item>
      <title>Re: Interval not working on script</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75001#M15323</link>
      <description>&lt;P&gt;It didn't affect the script at all. I tried restarting the entire server after implementing it, in case it was still running in memory, but no luck. Any other ideas?&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jun 2012 10:36:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75001#M15323</guid>
      <dc:creator>hortonew</dc:creator>
      <dc:date>2012-06-15T10:36:22Z</dc:date>
    </item>
    <item>
      <title>Re: Interval not working on script</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75002#M15324</link>
      <description>&lt;P&gt;Did you pay attention to the indentation level when you modified the script? Python interprets different indentation levels differently. The &lt;CODE&gt;time.sleep&lt;/CODE&gt; line should be one level "up" (= less indentation) than the &lt;CODE&gt;ipsLogger.info&lt;/CODE&gt; line. This should make the script sleep for 300 seconds after each run of its main loop.&lt;/P&gt;

&lt;P&gt;You don't need to restart Splunk, scripts are called directly each time they're run rather than being kept in memory.&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jun 2012 10:48:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75002#M15324</guid>
      <dc:creator>Ayn</dc:creator>
      <dc:date>2012-06-15T10:48:56Z</dc:date>
    </item>
    <item>
      <title>Re: Interval not working on script</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75003#M15325</link>
      <description>&lt;P&gt;With the release of version 1.1.1 of the Cisco IPS app, you can now specify a polling interval in the inputs.conf. Below is an example that causes the script to wait 30 seconds in between polls of the Cisco IPS appliance. You must be running version 1.1.1 or higher to use this additional option at the end of the script. Changing the "interval" underneath the script command will not affect the polling of the IPS.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[script://$SPLUNK_HOME\etc\apps\Splunk_CiscoIPS\bin\get_ips_feed.py "username" "password" "IPS_IP" "30"]
disabled = 0
index = main
interval = 1
source = SDEE
sourcetype = cisco_ips_syslog
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 14 Jul 2012 00:10:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75003#M15325</guid>
      <dc:creator>andrew_garvin</dc:creator>
      <dc:date>2012-07-14T00:10:13Z</dc:date>
    </item>
    <item>
      <title>Re: Interval not working on script</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75004#M15326</link>
      <description>&lt;P&gt;Thanks!  I'll be sure to upgrade and give it a shot.&lt;/P&gt;</description>
      <pubDate>Sat, 14 Jul 2012 14:19:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75004#M15326</guid>
      <dc:creator>hortonew</dc:creator>
      <dc:date>2012-07-14T14:19:44Z</dc:date>
    </item>
    <item>
      <title>Re: Interval not working on script</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75005#M15327</link>
      <description>&lt;P&gt;Worked like a champ - thanks for the update.&lt;/P&gt;</description>
      <pubDate>Sun, 15 Jul 2012 02:44:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/75005#M15327</guid>
      <dc:creator>hortonew</dc:creator>
      <dc:date>2012-07-15T02:44:45Z</dc:date>
    </item>
    <item>
      <title>Re: Interval not working on script</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/645759#M109868</link>
      <description>&lt;P class="lia-indent-padding-left-30px"&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/206225"&gt;@andrew_garvin&lt;/a&gt;&amp;nbsp;I am facing same issue where I have 2 data poller script in add on. One is getting triggered by interval but other not. I have tried correcting the order of my local/input.conf still not working expected. Can you please suggest what could be wrong ?&amp;nbsp; Below is my config for the script which is having issue.&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[digital_shadows_threat_intelligence://tes_IOC]
global_account = vitthal
interval = 90
ingesting_iocs = 1
since = 2023-06-05T05:42:56Z
threat_intelligence_updates = 0
disabled = 1&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 05 Jun 2023 12:14:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-is-interval-not-working-on-script/m-p/645759#M109868</guid>
      <dc:creator>vsarode</dc:creator>
      <dc:date>2023-06-05T12:14:16Z</dc:date>
    </item>
  </channel>
</rss>

