<?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: override source field to a common source using transform.conf and props.conf in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425941#M74653</link>
    <description>&lt;P&gt;tried your suggestion, didn't work. no effect.&lt;/P&gt;</description>
    <pubDate>Fri, 07 Dec 2018 06:38:40 GMT</pubDate>
    <dc:creator>meet_vadaria</dc:creator>
    <dc:date>2018-12-07T06:38:40Z</dc:date>
    <item>
      <title>override source field to a common source using transform.conf and props.conf</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425939#M74651</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;

&lt;P&gt;I want to have a common source field for all my syslog. I have centralized syslog server where I am running splunkforwarder to send all remote hosts logs to splunk.&lt;/P&gt;

&lt;P&gt;currently source filed is default which is "/var/log/syslog/%year%/%month%/%date%/%host%/syslog" &lt;BR /&gt;
what I want is "/var/log/syslog" - I want this static for all logs. how to do this with transforms.conf and props.conf&lt;/P&gt;

&lt;P&gt;I know I can do it in input.conf by just mentioning source="/var/log/syslog". I tried that and it works but it's breaking host field. I am overriding host field using host_segment in input.conf. so if I put static source there it breaks host_segment and splunk can't parse host.&lt;/P&gt;

&lt;P&gt;current configs,&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;transform.conf&lt;/STRONG&gt;&lt;BR /&gt;
[source]&lt;BR /&gt;
FORMAT = source::/var/log/syslog&lt;BR /&gt;
SOURCE_KEY=MetaData:Source&lt;BR /&gt;
DEST_KEY = MetaData:Source&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;props.conf&lt;/STRONG&gt;&lt;BR /&gt;
[sourceoverride]&lt;BR /&gt;
TRANSFORMS-source = source&lt;BR /&gt;
SHOULD_LINEMERGE = false&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;input.conf&lt;/STRONG&gt;&lt;BR /&gt;
[monitor:///var/log/rsyslog/&lt;EM&gt;/&lt;/EM&gt;/&lt;EM&gt;/&lt;/EM&gt;/syslog]&lt;BR /&gt;
disabled = false&lt;BR /&gt;
followTail=0&lt;BR /&gt;
host_segment = 7&lt;BR /&gt;
blacklist = .(gz)$&lt;BR /&gt;
sourcetype = syslog&lt;/P&gt;

&lt;H1&gt;source=/var/log/syslog&lt;/H1&gt;</description>
      <pubDate>Tue, 29 Sep 2020 22:19:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425939#M74651</guid>
      <dc:creator>meet_vadaria</dc:creator>
      <dc:date>2020-09-29T22:19:01Z</dc:date>
    </item>
    <item>
      <title>Re: override source field to a common source using transform.conf and props.conf</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425940#M74652</link>
      <description>&lt;P&gt;Can you try props as below:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;props.conf
[syslog]
TRANSFORMS-source = source
SHOULD_LINEMERGE = false
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 07 Dec 2018 06:27:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425940#M74652</guid>
      <dc:creator>p_gurav</dc:creator>
      <dc:date>2018-12-07T06:27:12Z</dc:date>
    </item>
    <item>
      <title>Re: override source field to a common source using transform.conf and props.conf</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425941#M74653</link>
      <description>&lt;P&gt;tried your suggestion, didn't work. no effect.&lt;/P&gt;</description>
      <pubDate>Fri, 07 Dec 2018 06:38:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425941#M74653</guid>
      <dc:creator>meet_vadaria</dc:creator>
      <dc:date>2018-12-07T06:38:40Z</dc:date>
    </item>
    <item>
      <title>Re: override source field to a common source using transform.conf and props.conf</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425942#M74654</link>
      <description>&lt;P&gt;Your transforms.conf is missing the REGEX part. Even though you don't need it functionally, it is a mandatory setting for indextime transforms.&lt;/P&gt;

&lt;P&gt;So just add &lt;CODE&gt;REGEX = .&lt;/CODE&gt; and then I think it should work.&lt;/P&gt;</description>
      <pubDate>Fri, 07 Dec 2018 10:21:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425942#M74654</guid>
      <dc:creator>FrankVl</dc:creator>
      <dc:date>2018-12-07T10:21:43Z</dc:date>
    </item>
    <item>
      <title>Re: override source field to a common source using transform.conf and props.conf</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425943#M74655</link>
      <description>&lt;P&gt;Just tried this. didn't work. Somehow it seems like splunk is ignoring transforms and props config files. no effect at all.&lt;/P&gt;</description>
      <pubDate>Fri, 07 Dec 2018 17:48:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425943#M74655</guid>
      <dc:creator>meet_vadaria</dc:creator>
      <dc:date>2018-12-07T17:48:38Z</dc:date>
    </item>
    <item>
      <title>Re: override source field to a common source using transform.conf and props.conf</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425944#M74656</link>
      <description>&lt;P&gt;Did you try my suggestion combined with the other answer about using [syslog]?&lt;/P&gt;

&lt;P&gt;Because using [sourceoverride] in your props.conf is incorrect. You need to put your actual sourcetype between de square brackets not some&lt;BR /&gt;
random word.&lt;/P&gt;</description>
      <pubDate>Fri, 07 Dec 2018 21:37:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/override-source-field-to-a-common-source-using-transform-conf/m-p/425944#M74656</guid>
      <dc:creator>FrankVl</dc:creator>
      <dc:date>2018-12-07T21:37:18Z</dc:date>
    </item>
  </channel>
</rss>

