<?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: How to set the time zone in an index? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256401#M49238</link>
    <description>&lt;P&gt;The link provided in the other answer is a bit out of date and things have changed.&lt;/P&gt;

&lt;P&gt;The highest precedence for TZ settings is an explicit value inside any event (provided the &lt;CODE&gt;TIME_FORMAT&lt;/CODE&gt; is configured to see it).  If this is not in place, then the next highest precedence for TZ settings is the props.conf that is on the forwarder, then the one on the Indexers.  You can override the TZ setting inside the event by using &lt;CODE&gt;TZ_ALIAS&lt;/CODE&gt;.  There is no &lt;CODE&gt;spec&lt;/CODE&gt; for &lt;CODE&gt;index&lt;/CODE&gt; inside props.conf; there is only this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;spec&amp;gt; can be:
1. &amp;lt;sourcetype&amp;gt;, the source type of an event.
2. host::&amp;lt;host&amp;gt;, where &amp;lt;host&amp;gt; is the host, or host-matching pattern, for an
                 event.
3. source::&amp;lt;source&amp;gt;, where &amp;lt;source&amp;gt; is the source, or source-matching
                     pattern, for an event.
4. rule::&amp;lt;rulename&amp;gt;, where &amp;lt;rulename&amp;gt; is a unique name of a source type
                     classification rule.
5. delayedrule::&amp;lt;rulename&amp;gt;, where &amp;lt;rulename&amp;gt; is a unique name of a delayed
                            source type classification rule.
                            These are only considered as a last resort
                            before generating a new source type based on the
                            source seen.
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;So you will have to work with &lt;CODE&gt;sourcetype&lt;/CODE&gt; specification stanzas instead, which should be no problem.&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/6.4.2/Admin/Propsconf"&gt;http://docs.splunk.com/Documentation/Splunk/6.4.2/Admin/Propsconf&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 14 Jul 2016 20:01:23 GMT</pubDate>
    <dc:creator>woodcock</dc:creator>
    <dc:date>2016-07-14T20:01:23Z</dc:date>
    <item>
      <title>How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256398#M49235</link>
      <description>&lt;P&gt;I want to set the time zone in an index.&lt;BR /&gt;
The time zone is GMT -03: 00 (São Paulo - Brazil).&lt;BR /&gt;
How do I do that?&lt;/P&gt;

&lt;P&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jul 2016 19:15:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256398#M49235</guid>
      <dc:creator>renanprado96</dc:creator>
      <dc:date>2016-07-14T19:15:03Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256399#M49236</link>
      <description>&lt;P&gt;A good discussion at &lt;A href="https://answers.splunk.com/answers/90262/how-and-where-does-splunk-determine-host-time-zone.html"&gt;How and where does splunk determine host time zone ?&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jul 2016 19:35:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256399#M49236</guid>
      <dc:creator>ddrillic</dc:creator>
      <dc:date>2016-07-14T19:35:29Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256400#M49237</link>
      <description>&lt;P&gt;Hi renanprado96, Unfortunately a timezone can't be associated with an index. Rather, each event has a timezone specified. In the best case this timezone is pulled directly from the event itself (the timestamp has a timezone splunk can recognize, or be configured to recognize)&lt;/P&gt;

&lt;P&gt;Past that, in version 6.0+ Splunk will leverage the timezone set in the OS of the forwarding host. Finally, it will use the timezone of the indexer.&lt;/P&gt;

&lt;P&gt;Timezone can also be configured on a per host/source/sourcetype manner by configuring as such in props.conf like so:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[host::nyc*]
TZ = US/Eastern
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;More info can be found here : &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.4.2/Data/Applytimezoneoffsetstotimestamps"&gt;http://docs.splunk.com/Documentation/Splunk/6.4.2/Data/Applytimezoneoffsetstotimestamps&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Please let me know if this answers your question! &lt;span class="lia-unicode-emoji" title=":grinning_face_with_smiling_eyes:"&gt;😄&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jul 2016 19:47:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256400#M49237</guid>
      <dc:creator>muebel</dc:creator>
      <dc:date>2016-07-14T19:47:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256401#M49238</link>
      <description>&lt;P&gt;The link provided in the other answer is a bit out of date and things have changed.&lt;/P&gt;

&lt;P&gt;The highest precedence for TZ settings is an explicit value inside any event (provided the &lt;CODE&gt;TIME_FORMAT&lt;/CODE&gt; is configured to see it).  If this is not in place, then the next highest precedence for TZ settings is the props.conf that is on the forwarder, then the one on the Indexers.  You can override the TZ setting inside the event by using &lt;CODE&gt;TZ_ALIAS&lt;/CODE&gt;.  There is no &lt;CODE&gt;spec&lt;/CODE&gt; for &lt;CODE&gt;index&lt;/CODE&gt; inside props.conf; there is only this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;spec&amp;gt; can be:
1. &amp;lt;sourcetype&amp;gt;, the source type of an event.
2. host::&amp;lt;host&amp;gt;, where &amp;lt;host&amp;gt; is the host, or host-matching pattern, for an
                 event.
3. source::&amp;lt;source&amp;gt;, where &amp;lt;source&amp;gt; is the source, or source-matching
                     pattern, for an event.
4. rule::&amp;lt;rulename&amp;gt;, where &amp;lt;rulename&amp;gt; is a unique name of a source type
                     classification rule.
5. delayedrule::&amp;lt;rulename&amp;gt;, where &amp;lt;rulename&amp;gt; is a unique name of a delayed
                            source type classification rule.
                            These are only considered as a last resort
                            before generating a new source type based on the
                            source seen.
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;So you will have to work with &lt;CODE&gt;sourcetype&lt;/CODE&gt; specification stanzas instead, which should be no problem.&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/6.4.2/Admin/Propsconf"&gt;http://docs.splunk.com/Documentation/Splunk/6.4.2/Admin/Propsconf&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jul 2016 20:01:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256401#M49238</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2016-07-14T20:01:23Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256402#M49239</link>
      <description>&lt;P&gt;Hello, have not worked yet.&lt;BR /&gt;
What did I do wrong?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[dbcmp_csv]
EXTRACT-jobname_ricoh = ^(?P&amp;lt;jobname_ricoh&amp;gt;\d+_&amp;amp;\d+&amp;amp;)
FIELD_NAMES = ClienteERP,Aplicacao,ClienteAplicacao,idHistoricoProducao,DataHoraInicio,DataHoraTermino,Quantidade,idEtapa,NomeArquivoImpressao,CentroImpressao,TipoProduto,FormatoPapel,Maquina,GrupoMaquina,Fabricante,SituacaoArqImpressao,SituacaoLote
INDEXED_EXTRACTIONS = csv
TIME_PREFIX = .{0,}DataHoraTermino=
TIME_FORMAT = %s%3N
TZ = America/Sao_Paulo
FIELD_DELIMITER = ,
KV_MODE = none
NO_BINARY_CHECK = true
SHOULD_LINEMERGE = false
category = Structured
description = Comma-separated value format. Set header and other settings in "Delimited Settings"
disabled = false
pulldown_type = true
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jul 2016 18:07:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256402#M49239</guid>
      <dc:creator>renanprado96</dc:creator>
      <dc:date>2016-07-15T18:07:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256403#M49240</link>
      <description>&lt;P&gt;Hello, have not worked yet.&lt;BR /&gt;
What did I do wrong?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[dbcmp_csv]
EXTRACT-jobname_ricoh = ^(?P&amp;lt;jobname_ricoh&amp;gt;\d+_&amp;amp;\d+&amp;amp;)
FIELD_NAMES = ClienteERP,Aplicacao,ClienteAplicacao,idHistoricoProducao,DataHoraInicio,DataHoraTermino,Quantidade,idEtapa,NomeArquivoImpressao,CentroImpressao,TipoProduto,FormatoPapel,Maquina,GrupoMaquina,Fabricante,SituacaoArqImpressao,SituacaoLote
INDEXED_EXTRACTIONS = csv
TIME_PREFIX = .{0,}DataHoraTermino=
TIME_FORMAT = %s%3N
TZ = GMT
TZ_ALIAS = GMT = GMT-3:00
FIELD_DELIMITER = ,
KV_MODE = none
NO_BINARY_CHECK = true
SHOULD_LINEMERGE = false
category = Structured
description = Comma-separated value format. Set header and other settings in "Delimited Settings"
disabled = false
pulldown_type = true
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jul 2016 18:09:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256403#M49240</guid>
      <dc:creator>renanprado96</dc:creator>
      <dc:date>2016-07-15T18:09:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256404#M49241</link>
      <description>&lt;P&gt;Hmm, my guess is that there is something up with the time_prefix and/or time_format config. From the spec:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;If the TIME_PREFIX cannot be found in the event text, timestamp extraction will not occur.
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 29 Sep 2020 10:14:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256404#M49241</guid>
      <dc:creator>muebel</dc:creator>
      <dc:date>2020-09-29T10:14:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256405#M49242</link>
      <description>&lt;P&gt;TIME_PREFIX removed and still did not work :'(&lt;BR /&gt;
I had already tried to removed it&lt;BR /&gt;
I do not know what to do ..&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jul 2016 18:25:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256405#M49242</guid>
      <dc:creator>renanprado96</dc:creator>
      <dc:date>2016-07-15T18:25:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256406#M49243</link>
      <description>&lt;P&gt;Is this props config set on the receiver? (heavy forwarder/indexer)&lt;/P&gt;

&lt;P&gt;Setting on the Universal Forwarder isn't enough for it to be effective.&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jul 2016 18:32:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256406#M49243</guid>
      <dc:creator>muebel</dc:creator>
      <dc:date>2016-07-15T18:32:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256407#M49244</link>
      <description>&lt;P&gt;This configuration is defined in the Splunk server, the data is sent to a SQL database connected by dbConnect v2&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jul 2016 18:40:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256407#M49244</guid>
      <dc:creator>renanprado96</dc:creator>
      <dc:date>2016-07-15T18:40:22Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256408#M49245</link>
      <description>&lt;P&gt;Show me a sample event first.  There is no way to validate your configurations otherwise.&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jul 2016 18:48:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256408#M49245</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2016-07-15T18:48:15Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256409#M49246</link>
      <description>&lt;P&gt;In these samples the time should be at least 3 hours ago.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;"2015-07-24 11:50:41" DATAAREAID="206", RECID=5637144596, DATAAREAID#2="206", ITEMID="002.0001.171", TRANSDATE=1437706800000, SUMOFQTYSEND=1.000000000000, SUMOFQTYRET=0E-12, RECIDLINE=5637184982, TRANSDATETIME=1437749441000, TRANSDATETIMETZID=37001, DATAAREAID#3="206", ITEMNAME="PRINT-INS-RICOH 5000 TINTA DYE PLUS BLACK"


"2015-07-24 11:50:41" DATAAREAID="206", RECID=5637144589, DATAAREAID#2="206", ITEMID="002.0001.163", TRANSDATE=1437706800000, SUMOFQTYSEND=1.000000000000, SUMOFQTYRET=0E-12, RECIDLINE=5637184981, TRANSDATETIME=1437749441000, TRANSDATETIMETZID=37001, DATAAREAID#3="206", ITEMNAME="PRINT-INS-TINTA PIGMENTADA PARA COLORSTREAM COR CYAN"
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 15 Jul 2016 19:17:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256409#M49246</guid>
      <dc:creator>renanprado96</dc:creator>
      <dc:date>2016-07-15T19:17:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256410#M49247</link>
      <description>&lt;P&gt;Your field names do not match the data in the events that you posted.  Which is correct?  Which field is the tmiestamp?&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jul 2016 21:14:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256410#M49247</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2016-07-15T21:14:22Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256411#M49248</link>
      <description>&lt;P&gt;True, sorry!!&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[dynamicsAX_csv]
FIELD_NAMES = DATAAREAID,RECID,DATAAREAID2,ITEMID,TRANSDATE,SUMOFQTYSEND,SUMOFQTYRET,RECIDLINE,TRANSDATETIME,DATAAREAID3,ITEMNAME
INDEXED_EXTRACTIONS = csv
TIME_PREFIX = .{0,}TRANSDATETIME=
TIME_FORMAT = %s%3N
TZ = GMT
TZ_ALIAS = GMT = GMT-3:00
FIELD_DELIMITER = ,
KV_MODE = none
NO_BINARY_CHECK = true
SHOULD_LINEMERGE = false
category = Structured
description = Comma-separated value format. Set header and other settings in "Delimited Settings"
disabled = false
pulldown_type = true
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I sent the wrong, but I applied in correct.&lt;BR /&gt;
It was just a mess when sending.&lt;/P&gt;</description>
      <pubDate>Mon, 18 Jul 2016 13:12:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256411#M49248</guid>
      <dc:creator>renanprado96</dc:creator>
      <dc:date>2016-07-18T13:12:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256412#M49249</link>
      <description>&lt;P&gt;It is possible to do this for search?&lt;/P&gt;</description>
      <pubDate>Mon, 18 Jul 2016 18:00:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256412#M49249</guid>
      <dc:creator>renanprado96</dc:creator>
      <dc:date>2016-07-18T18:00:22Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256413#M49250</link>
      <description>&lt;P&gt;It is possible to do this for search?&lt;/P&gt;</description>
      <pubDate>Mon, 18 Jul 2016 18:00:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256413#M49250</guid>
      <dc:creator>renanprado96</dc:creator>
      <dc:date>2016-07-18T18:00:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to set the time zone in an index?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256414#M49251</link>
      <description>&lt;P&gt;Because you have opened another question for this and that one is progressing, the right thing to do is to pick the best "can't do that" answer in this question and click &lt;CODE&gt;Accept&lt;/CODE&gt; to close this question. &lt;BR /&gt;
&lt;A href="https://answers.splunk.com/answers/432855/how-to-configure-the-timezone-by-sourcetype.html#comment-433036"&gt;https://answers.splunk.com/answers/432855/how-to-configure-the-timezone-by-sourcetype.html#comment-433036&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Jul 2016 14:42:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-set-the-time-zone-in-an-index/m-p/256414#M49251</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2016-07-19T14:42:33Z</dc:date>
    </item>
  </channel>
</rss>

