<?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 Architecture specific scripts (linux/windows) in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Architecture-specific-scripts-linux-windows/m-p/103524#M21764</link>
    <description>&lt;P&gt;I've been trying to get my data input Python script to work on both Windows and Linux but I've run into a problem with inputs.conf&lt;/P&gt;

&lt;P&gt;It seems that with Splunk 6 I can have forward slashes in my script path in Windows but Splunk 5 doesn't like the forward slashes. I know I could easily change the forward slashes to back slashes but then it won't work in Linux! I want to support both Linux and Windows in both Splunk 5 and 6 and I want my data input enabled by default (i.e. not have the user choose which OS he is on.&lt;/P&gt;

&lt;P&gt;One solution I thought might work would be to have two stanzas in inputs.conf, one with a backslash path and the other with a forward slash path and one will error out while the other works. The problem with this is that Splunk 6 in Windows will run both scripts because it isn't as picky about separators. &lt;/P&gt;

&lt;P&gt;I also had a look at: &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.0/AdvancedDev/ModInputsScripts#Architecture-specific_scripts"&gt;http://docs.splunk.com/Documentation/Splunk/6.0/AdvancedDev/ModInputsScripts#Architecture-specific_scripts&lt;/A&gt; which mentions having different folders (Windowsx86, Linux x86, etc) with a bin folder in each that contains my script. The issue with this is it doesn't mention what I should put in my inputs.conf stanza, assuming I could just have one. I tried [script://MYSCRIPT.py] but that didn't work.&lt;/P&gt;

&lt;P&gt;Thanks&lt;/P&gt;</description>
    <pubDate>Thu, 17 Oct 2013 10:31:15 GMT</pubDate>
    <dc:creator>ralphmct</dc:creator>
    <dc:date>2013-10-17T10:31:15Z</dc:date>
    <item>
      <title>Architecture specific scripts (linux/windows)</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Architecture-specific-scripts-linux-windows/m-p/103524#M21764</link>
      <description>&lt;P&gt;I've been trying to get my data input Python script to work on both Windows and Linux but I've run into a problem with inputs.conf&lt;/P&gt;

&lt;P&gt;It seems that with Splunk 6 I can have forward slashes in my script path in Windows but Splunk 5 doesn't like the forward slashes. I know I could easily change the forward slashes to back slashes but then it won't work in Linux! I want to support both Linux and Windows in both Splunk 5 and 6 and I want my data input enabled by default (i.e. not have the user choose which OS he is on.&lt;/P&gt;

&lt;P&gt;One solution I thought might work would be to have two stanzas in inputs.conf, one with a backslash path and the other with a forward slash path and one will error out while the other works. The problem with this is that Splunk 6 in Windows will run both scripts because it isn't as picky about separators. &lt;/P&gt;

&lt;P&gt;I also had a look at: &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.0/AdvancedDev/ModInputsScripts#Architecture-specific_scripts"&gt;http://docs.splunk.com/Documentation/Splunk/6.0/AdvancedDev/ModInputsScripts#Architecture-specific_scripts&lt;/A&gt; which mentions having different folders (Windowsx86, Linux x86, etc) with a bin folder in each that contains my script. The issue with this is it doesn't mention what I should put in my inputs.conf stanza, assuming I could just have one. I tried [script://MYSCRIPT.py] but that didn't work.&lt;/P&gt;

&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Thu, 17 Oct 2013 10:31:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Architecture-specific-scripts-linux-windows/m-p/103524#M21764</guid>
      <dc:creator>ralphmct</dc:creator>
      <dc:date>2013-10-17T10:31:15Z</dc:date>
    </item>
    <item>
      <title>Re: Architecture specific scripts (linux/windows)</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Architecture-specific-scripts-linux-windows/m-p/103525#M21765</link>
      <description>&lt;P&gt;The docs for &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.0/admin/Inputsconf"&gt;inputs.conf&lt;/A&gt; say:&lt;/P&gt;

&lt;BLOCKQUOTE&gt;
&lt;P&gt;Script path can be an absolute path, make use of an environment variable such as $SPLUNK_HOME, or use the special pattern of an initial '.' as the first directory to indicate a location inside the current app.   Note that the '.' must be followed by a platform-specific directory separator.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;

&lt;P&gt;I believe you may need to have separate entries per platform. However, you could see if &lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/Data/Specifyinputpathswithwildcards"&gt;input paths with wildcards&lt;/A&gt; helps with this.&lt;/P&gt;</description>
      <pubDate>Sat, 19 Oct 2013 17:11:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Architecture-specific-scripts-linux-windows/m-p/103525#M21765</guid>
      <dc:creator>jtrucks</dc:creator>
      <dc:date>2013-10-19T17:11:26Z</dc:date>
    </item>
    <item>
      <title>Re: Architecture specific scripts (linux/windows)</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Architecture-specific-scripts-linux-windows/m-p/103526#M21766</link>
      <description>&lt;P&gt;I went for separate entries per platform in the end though the docs on wildcards were interesting and could prove useful for other scenarios&lt;/P&gt;</description>
      <pubDate>Tue, 12 Nov 2013 11:40:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Architecture-specific-scripts-linux-windows/m-p/103526#M21766</guid>
      <dc:creator>ralphmct</dc:creator>
      <dc:date>2013-11-12T11:40:15Z</dc:date>
    </item>
  </channel>
</rss>

