<?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: What do other users think of our retention policy solution using a nightly scheduled report to search and delete events older than 180 days? in Reporting</title>
    <link>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174072#M3815</link>
    <description>&lt;P&gt;@MuS - respectfully disagree, because you can set &lt;CODE&gt;maxHotSpanSecs&lt;/CODE&gt; to overcome that problem.&lt;/P&gt;</description>
    <pubDate>Wed, 24 Jun 2015 23:08:47 GMT</pubDate>
    <dc:creator>lguinn2</dc:creator>
    <dc:date>2015-06-24T23:08:47Z</dc:date>
    <item>
      <title>What do other users think of our retention policy solution using a nightly scheduled report to search and delete events older than 180 days?</title>
      <link>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174067#M3810</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;We have been using Splunk for a couple of years and to build up our retention policy, we created a report which was scheduled every night.&lt;BR /&gt;
The report was executed by a special user account that will only be used to schedule this report. This user has the permission to delete events from Splunk.&lt;/P&gt;

&lt;P&gt;The search string looks like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=* NOT (index=_* OR index=history OR index=main OR index=os OR index=splunklogger OR index=summary) latest=-180d@ | delete
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;So far we have no problems with this solution. You have to know that we have more than 200 indexes defined on our indexer and it is very important that there are no events in there which are older than 180 days. &lt;/P&gt;

&lt;P&gt;I'd like to discuss this solution with you. What do you think about it? Is this a proper way to delete all events with a specific Age?&lt;/P&gt;

&lt;P&gt;Thanks for ideas and answers.&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jun 2015 13:07:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174067#M3810</guid>
      <dc:creator>krusty</dc:creator>
      <dc:date>2015-06-24T13:07:03Z</dc:date>
    </item>
    <item>
      <title>Re: What do other users think of our retention policy solution using a nightly scheduled report to search and delete events older than 180 days?</title>
      <link>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174068#M3811</link>
      <description>&lt;P&gt;why can't you set frozenTimePeriodInSecs in indexes.conf for each index? just curious.&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jun 2015 21:21:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174068#M3811</guid>
      <dc:creator>sk314</dc:creator>
      <dc:date>2015-06-24T21:21:26Z</dc:date>
    </item>
    <item>
      <title>Re: What do other users think of our retention policy solution using a nightly scheduled report to search and delete events older than 180 days?</title>
      <link>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174069#M3812</link>
      <description>&lt;P&gt;Because with &lt;CODE&gt;frozenTimePeriodInSecs&lt;/CODE&gt; you can have older events in your buckets, because &lt;CODE&gt;Every event in the DB must be older than frozenTimePeriodInSecs before it will roll&lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jun 2015 21:24:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174069#M3812</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2015-06-24T21:24:19Z</dc:date>
    </item>
    <item>
      <title>Re: What do other users think of our retention policy solution using a nightly scheduled report to search and delete events older than 180 days?</title>
      <link>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174070#M3813</link>
      <description>&lt;P&gt;TIL. Thanks. &lt;/P&gt;</description>
      <pubDate>Wed, 24 Jun 2015 21:25:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174070#M3813</guid>
      <dc:creator>sk314</dc:creator>
      <dc:date>2015-06-24T21:25:44Z</dc:date>
    </item>
    <item>
      <title>Re: What do other users think of our retention policy solution using a nightly scheduled report to search and delete events older than 180 days?</title>
      <link>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174071#M3814</link>
      <description>&lt;P&gt;If you set these two settings in &lt;CODE&gt;indexes.conf&lt;/CODE&gt; for each index&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;maxHotSpanSecs = 86400
frozenTimePeriodInSecs = 15552000
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Each bucket will contact exactly 1 day's data, and buckets will roll at midnight. The &lt;CODE&gt;frozenTimePeriod&lt;/CODE&gt; in seconds will roll the buckets after 180 days. This combination of settings will guarantee that there is no data in the index older than 180 days.&lt;/P&gt;

&lt;P&gt;This will solve the problem mentioned by @MuS, where a bucket could contain data from different days.&lt;/P&gt;

&lt;P&gt;Your solution does not recover the disk space and is not the best practice. (Although eventually it will recover the disk space, as the buckets finally age.) Also, if the script fails to run for any reason, you will have excess data in your indexes. If you set the parameters in &lt;CODE&gt;indexes.conf&lt;/CODE&gt;, even if Splunk has been down, when it starts up again, it will immediately follow the &lt;CODE&gt;indexes.conf&lt;/CODE&gt; policy and age out the data over 180 days.&lt;/P&gt;

&lt;P&gt;And, using &lt;CODE&gt;frozenTimePeriodInSecs&lt;/CODE&gt; allows you to set different retentions for different indexes. At some future point, you may want to do this. &lt;/P&gt;

&lt;P&gt;FYI, please remember that Splunk will &lt;STRONG&gt;never&lt;/STRONG&gt; consume more disk space than is allocated for an index. So it is possible that you could have an index with &lt;STRONG&gt;fewer&lt;/STRONG&gt; than 180 days of data if insufficient disk space is allocated for the events. So be sure to check the index size, too - this is also set in indexes.conf as &lt;CODE&gt;maxTotalDataSizeMB&lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jun 2015 22:58:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174071#M3814</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-06-24T22:58:17Z</dc:date>
    </item>
    <item>
      <title>Re: What do other users think of our retention policy solution using a nightly scheduled report to search and delete events older than 180 days?</title>
      <link>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174072#M3815</link>
      <description>&lt;P&gt;@MuS - respectfully disagree, because you can set &lt;CODE&gt;maxHotSpanSecs&lt;/CODE&gt; to overcome that problem.&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jun 2015 23:08:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174072#M3815</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-06-24T23:08:47Z</dc:date>
    </item>
    <item>
      <title>Re: What do other users think of our retention policy solution using a nightly scheduled report to search and delete events older than 180 days?</title>
      <link>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174073#M3816</link>
      <description>&lt;P&gt;@lguinn, no problem at all and thanks for my TIL as well because your answer and the combination of the two options is brilliant !&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jun 2015 23:16:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174073#M3816</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2015-06-24T23:16:50Z</dc:date>
    </item>
    <item>
      <title>Re: What do other users think of our retention policy solution using a nightly scheduled report to search and delete events older than 180 days?</title>
      <link>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174074#M3817</link>
      <description>&lt;P&gt;@Iguinn, thanks for your answer. That's exactly what I'm searching for. &lt;BR /&gt;
Unfortunately I didn't completly understood the manual with these settings in the indexes.conf section.&lt;/P&gt;

&lt;P&gt;One short question about the &lt;CODE&gt;maxTotalDataSizeMB&lt;/CODE&gt; setting. If I set it to &lt;CODE&gt;auto&lt;/CODE&gt;, I should be on the safe side? So the index can grow like it wants and with the other two settings you described, I should be safe that each day the bucket will be rolled.&lt;BR /&gt;
My problem is, that the amount of data input for the differnt indexes are not the same each day. So I could count how many MB is right for the indexes. In that case it makes sense to me to set the value to auto. &lt;BR /&gt;
For your information, the disk space for the indexer is big enough, so we should not get trouble with it.&lt;/P&gt;

&lt;P&gt;Kind regards, and once again thanks for your reply.&lt;/P&gt;</description>
      <pubDate>Sat, 27 Jun 2015 07:27:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174074#M3817</guid>
      <dc:creator>krusty</dc:creator>
      <dc:date>2015-06-27T07:27:21Z</dc:date>
    </item>
    <item>
      <title>Re: What do other users think of our retention policy solution using a nightly scheduled report to search and delete events older than 180 days?</title>
      <link>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174075#M3818</link>
      <description>&lt;P&gt;No, &lt;CODE&gt;auto&lt;/CODE&gt; is only used for the size of a single bucket - not the size of the index overall. You must set an actual value for &lt;CODE&gt;maxTotalDataSizeMB&lt;/CODE&gt;; if you don't, the default size is 500000 (500GB). You will need to monitor your indexes to make sure that they don't exceed their maximum size allocation.&lt;/P&gt;

&lt;P&gt;For the size of a bucket, use &lt;CODE&gt;maxDataSize&lt;/CODE&gt;. If set to &lt;CODE&gt;auto&lt;/CODE&gt;, then the maximum size of a single bucket will be 750MB. The &lt;CODE&gt;auto_high_volume&lt;/CODE&gt; setting is 10GB. I suggest that you set this to a size that approximates the amount (on disk) of data that is added to the index each day, or less. However I would never set a bucket size lower than 750MB.&lt;/P&gt;</description>
      <pubDate>Wed, 01 Jul 2015 21:07:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/What-do-other-users-think-of-our-retention-policy-solution-using/m-p/174075#M3818</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-07-01T21:07:51Z</dc:date>
    </item>
  </channel>
</rss>

