<?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: syslog - main db - archive on daily basis in Deployment Architecture</title>
    <link>https://community.splunk.com/t5/Deployment-Architecture/syslog-main-db-archive-on-daily-basis/m-p/48642#M1480</link>
    <description>&lt;P&gt;I'm not sure that's what you want to do.  the &lt;CODE&gt;frozenTimePeriodInSecs&lt;/CODE&gt; governs when data is moved to FROZEN not cold.  Unless you have also configured a &lt;CODE&gt;coldToFrozenScript&lt;/CODE&gt; this means you've told Splunk to DELETE any index buckets where the newest event is more than 24 hours old.&lt;/P&gt;

&lt;P&gt;If your goal is to keep the data both inside and outside of splunk, maybe you'd be better off to let rsyslog or syslog-ng listen on udp/514 and then let Splunk read their flat files (which you then keep)&lt;/P&gt;</description>
    <pubDate>Tue, 26 Jul 2011 17:21:25 GMT</pubDate>
    <dc:creator>dwaddle</dc:creator>
    <dc:date>2011-07-26T17:21:25Z</dc:date>
    <item>
      <title>syslog - main db - archive on daily basis</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/syslog-main-db-archive-on-daily-basis/m-p/48641#M1479</link>
      <description>&lt;P&gt;Greeting,&lt;BR /&gt;
My Splunk installation is simply configured to collect syslog messages (udp 514) and nothing fancy... and I would like to create a copy of every event at a 24 hours interval, how do I do that?&lt;/P&gt;

&lt;P&gt;The closest I can figure out to accomplish this is to mark the information as "cold"&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[main]
coldPath = /opt/splunk-archive
frozenTimePeriodInSecs = 86400  

    {{By the way... this isn't working. After 24 hours I don't see my data... and yes, I restart the service}}
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Is there a better way to do this? I am not too comfortable freezing the information like this but will if I cannot figure out a better way... which would be to simply look at all the events in the last 24 hours and create a zip file of the data (perhaps via a script.)&lt;/P&gt;

&lt;P&gt;What is optimal way to do this?&lt;BR /&gt;
Thanks in advance,&lt;BR /&gt;
~Jaga&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jul 2011 13:44:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/syslog-main-db-archive-on-daily-basis/m-p/48641#M1479</guid>
      <dc:creator>hellou</dc:creator>
      <dc:date>2011-07-26T13:44:44Z</dc:date>
    </item>
    <item>
      <title>Re: syslog - main db - archive on daily basis</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/syslog-main-db-archive-on-daily-basis/m-p/48642#M1480</link>
      <description>&lt;P&gt;I'm not sure that's what you want to do.  the &lt;CODE&gt;frozenTimePeriodInSecs&lt;/CODE&gt; governs when data is moved to FROZEN not cold.  Unless you have also configured a &lt;CODE&gt;coldToFrozenScript&lt;/CODE&gt; this means you've told Splunk to DELETE any index buckets where the newest event is more than 24 hours old.&lt;/P&gt;

&lt;P&gt;If your goal is to keep the data both inside and outside of splunk, maybe you'd be better off to let rsyslog or syslog-ng listen on udp/514 and then let Splunk read their flat files (which you then keep)&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jul 2011 17:21:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/syslog-main-db-archive-on-daily-basis/m-p/48642#M1480</guid>
      <dc:creator>dwaddle</dc:creator>
      <dc:date>2011-07-26T17:21:25Z</dc:date>
    </item>
    <item>
      <title>Re: syslog - main db - archive on daily basis</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/syslog-main-db-archive-on-daily-basis/m-p/48643#M1481</link>
      <description>&lt;P&gt;Thank you for the response! I do see your point and will make the adjustment to not have my splunk data delete prematurely.&lt;/P&gt;

&lt;P&gt;In the end my answer was to write a script. My script looks at all the events within a day and pipe it to a file. I then compress that file, move it off the server, and archive it.&lt;/P&gt;

&lt;P&gt;The script basically runs this command:&lt;BR /&gt;
./splunk search 'earliest=7/25/2011 latest=7/26/2011' -maxout 0 -auth $username:$password &amp;gt; /some/location&lt;/P&gt;

&lt;P&gt;the trickiest part was to figureout the "-maxout" option because without it the search would only return 10000 items.&lt;/P&gt;

&lt;P&gt;I tried to do this with python but could not figure out the "-maxout" equivalent (I think it's &lt;BR /&gt;
maxresults=0 but that didn't work) also I needed to figure out the "earliest" and "latest" equivalent to establish the correct range.&lt;/P&gt;

&lt;P&gt;In any case the command line above works fine and I'll revisit this and do it in python.&lt;/P&gt;

&lt;P&gt;thanks again,&lt;BR /&gt;
~Jaga&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jul 2011 18:02:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/syslog-main-db-archive-on-daily-basis/m-p/48643#M1481</guid>
      <dc:creator>hellou</dc:creator>
      <dc:date>2011-07-26T18:02:29Z</dc:date>
    </item>
    <item>
      <title>Re: syslog - main db - archive on daily basis</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/syslog-main-db-archive-on-daily-basis/m-p/48644#M1482</link>
      <description>&lt;P&gt;excellent.  Be sure to click the "accept answer" checkbox so it'll show as answered.   Also, you might find your search to work a little easier if you use "earliest=-1d@d latest=@d" -- this is a relative indicator for "yesterday" without having to specifically figure work it out.&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jul 2011 19:39:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/syslog-main-db-archive-on-daily-basis/m-p/48644#M1482</guid>
      <dc:creator>dwaddle</dc:creator>
      <dc:date>2011-07-26T19:39:38Z</dc:date>
    </item>
  </channel>
</rss>

