<?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: Can't launch bat file at UF in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382937#M94286</link>
    <description>&lt;P&gt;So, I tried to use this code:&lt;BR /&gt;
[script://$SPLUNK_HOME\etc\apps\SQL_Failed_logon\bin\script\LogCheck.bat]&lt;BR /&gt;
disabled = 0&lt;BR /&gt;
interval = 300&lt;BR /&gt;
sourcetype = SQL_Audit&lt;/P&gt;

&lt;P&gt;and if I insert a code into LogChecked.bat as: &lt;/P&gt;

&lt;P&gt;echo This is a test &amp;gt; "C:\Program Files\Splunk\var\log\splunk\test.txt"&lt;BR /&gt;
     echo 123 &amp;gt;&amp;gt; "C:\Program Files\Splunk\var\log\splunk\test.txt"&lt;BR /&gt;
     echo 245.67 &amp;gt;&amp;gt; "C:\Program Files\Splunk\var\log\splunk\test.txt"&lt;/P&gt;

&lt;P&gt;It.s work fine.&lt;/P&gt;

&lt;P&gt;But if I insert a code into LogChecked.bat as:&lt;/P&gt;

&lt;P&gt;@Echo Off&lt;BR /&gt;
SetLocal EnableExtensions EnableDelayedExpansion&lt;BR /&gt;
For /F "Delims=" %%I In ('Hostname') Do Set V=%%~I&lt;/P&gt;

&lt;P&gt;setlocal enabledelayedexpansion&lt;BR /&gt;
set d=%date:~0,2%&lt;BR /&gt;
set m=%date:~3,2%&lt;BR /&gt;
set y=%date:~6,4%&lt;BR /&gt;
if %d:~0,1%==0 set d=%d:~1%&lt;BR /&gt;
if %m:~0,1%==0 set m=%m:~1%&lt;BR /&gt;
set /a feb=y%%4&lt;BR /&gt;
if %feb%==0 (set feb=29) else (set feb=28)&lt;BR /&gt;
set /a tok=m-1&lt;BR /&gt;
if %tok%==0 set tok=12&lt;BR /&gt;
for /f "tokens=%tok%" %%i in ("31 %feb% 31 30 31 30 31 31 30 31 30 31") do (&lt;BR /&gt;
:: минус 1 month  set /a m-=1&lt;BR /&gt;
   set /a m-=1&lt;BR /&gt;
    if !d!==0 (&lt;BR /&gt;
        set d=%%i&lt;BR /&gt;
        set m=%tok%&lt;BR /&gt;
        if !m!==12 set /a y-=1&lt;BR /&gt;
    )&lt;BR /&gt;
)&lt;BR /&gt;
set d=0%d%&lt;BR /&gt;
set m=0%m%&lt;BR /&gt;
set lastmonth=%y%-%m:~-2%&lt;/P&gt;

&lt;P&gt;@copy "\%V%\SQLLOGS$\ERRORLOG.&lt;EM&gt;" errorlog.&lt;/EM&gt;.%V% /Z&lt;BR /&gt;
@find "%lastmonth%" Errorlog..%V% &amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.1.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.2.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.3.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.4.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.5.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.6.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.7.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.8.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.9.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.10.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.11.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.12.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.13.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.14.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.15.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.16.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.17.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.18.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.19.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.20.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.21.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.22.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.23.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.24.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.25.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.26.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.27.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.28.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.29.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.30.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.31.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.32.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.33.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.34.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.35.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.36.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.37.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.38.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.39.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.40.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.41.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.42.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.43.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.44.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.45.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.46.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.47.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.48.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.49.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.50.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "Logon" out2.%V% &amp;gt; out.%V%&lt;BR /&gt;
@del out2.*&lt;BR /&gt;
MonthREport2005.exe %lastmonth% out.%V% outlog%V%.txt %V% 2008&lt;/P&gt;

&lt;P&gt;@type outlog%V%.txt &amp;gt;&amp;gt; SumLog.txt&lt;/P&gt;

&lt;P&gt;@del Errorlog*&lt;BR /&gt;
@del outlog%V%.txt&lt;BR /&gt;
:@del out.*&lt;/P&gt;

&lt;P&gt;It doesn't work. How can I check what happened in splunk and why this is not work?&lt;BR /&gt;
If I start this code throught cmd it works.&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 20:42:57 GMT</pubDate>
    <dc:creator>atyshke1</dc:creator>
    <dc:date>2020-09-29T20:42:57Z</dc:date>
    <item>
      <title>Can't launch bat file at UF</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382934#M94283</link>
      <description>&lt;P&gt;I am trying to launch some batch file but UF don't want to do this.&lt;BR /&gt;
My input.cong contain:&lt;BR /&gt;
[script://.\bin\script\LogCheck.bat 2018-07]&lt;BR /&gt;
disabled = 0&lt;BR /&gt;
interval = 300&lt;BR /&gt;
index = werrorindex&lt;BR /&gt;
sourcetype = sql_audit&lt;/P&gt;

&lt;P&gt;2018-07 is a parametr of launch the batch&lt;BR /&gt;
If I use in cmd LogCheck.bat 2018-07 it works fine.&lt;BR /&gt;
Help me please to find the issue..&lt;/P&gt;</description>
      <pubDate>Thu, 02 Aug 2018 09:17:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382934#M94283</guid>
      <dc:creator>atyshke1</dc:creator>
      <dc:date>2018-08-02T09:17:11Z</dc:date>
    </item>
    <item>
      <title>Re: Can't launch bat file at UF</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382935#M94284</link>
      <description>&lt;P&gt;Hey@atyshke1,&lt;/P&gt;

&lt;P&gt;I think the issue is with the path of the script .Instead of .\ it should be $SPLUNK_HOME or the splunk home path.&lt;BR /&gt;
Refer this link:&lt;BR /&gt;
&lt;A href="https://docs.splunk.com/Documentation/Splunk/7.1.2/AdvancedDev/ScriptSetup"&gt;https://docs.splunk.com/Documentation/Splunk/7.1.2/AdvancedDev/ScriptSetup&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Let me know if this helps!!&lt;/P&gt;</description>
      <pubDate>Thu, 02 Aug 2018 09:25:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382935#M94284</guid>
      <dc:creator>deepashri_123</dc:creator>
      <dc:date>2018-08-02T09:25:24Z</dc:date>
    </item>
    <item>
      <title>Re: Can't launch bat file at UF</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382936#M94285</link>
      <description>&lt;P&gt;I tried this:&lt;/P&gt;

&lt;P&gt;[script://$SPLUNK_HOME/etc/apps/SQL_Failed_logon/bin/script/log.bat]&lt;BR /&gt;
disabled = 0&lt;BR /&gt;
interval = 300&lt;BR /&gt;
index = werrorindex&lt;BR /&gt;
sourcetype = sql_audit&lt;/P&gt;

&lt;P&gt;But it didn't help&lt;BR /&gt;
I created a log.bat for test with simple code:&lt;/P&gt;

&lt;P&gt;echo This is a test &amp;gt; "C:\Program Files\SplunkUniversalForwarder\etc\apps\SQL_Failed_logon\bin\script\test.txt"&lt;BR /&gt;
echo 123 &amp;gt;&amp;gt; "C:\Program Files\SplunkUniversalForwarder\etc\apps\SQL_Failed_logon\bin\script\test.txt"&lt;BR /&gt;
echo 245.67 &amp;gt;&amp;gt; "C:\Program Files\SplunkUniversalForwarder\etc\apps\SQL_Failed_logon\bin\script\test.txt"&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:42:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382936#M94285</guid>
      <dc:creator>atyshke1</dc:creator>
      <dc:date>2020-09-29T20:42:46Z</dc:date>
    </item>
    <item>
      <title>Re: Can't launch bat file at UF</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382937#M94286</link>
      <description>&lt;P&gt;So, I tried to use this code:&lt;BR /&gt;
[script://$SPLUNK_HOME\etc\apps\SQL_Failed_logon\bin\script\LogCheck.bat]&lt;BR /&gt;
disabled = 0&lt;BR /&gt;
interval = 300&lt;BR /&gt;
sourcetype = SQL_Audit&lt;/P&gt;

&lt;P&gt;and if I insert a code into LogChecked.bat as: &lt;/P&gt;

&lt;P&gt;echo This is a test &amp;gt; "C:\Program Files\Splunk\var\log\splunk\test.txt"&lt;BR /&gt;
     echo 123 &amp;gt;&amp;gt; "C:\Program Files\Splunk\var\log\splunk\test.txt"&lt;BR /&gt;
     echo 245.67 &amp;gt;&amp;gt; "C:\Program Files\Splunk\var\log\splunk\test.txt"&lt;/P&gt;

&lt;P&gt;It.s work fine.&lt;/P&gt;

&lt;P&gt;But if I insert a code into LogChecked.bat as:&lt;/P&gt;

&lt;P&gt;@Echo Off&lt;BR /&gt;
SetLocal EnableExtensions EnableDelayedExpansion&lt;BR /&gt;
For /F "Delims=" %%I In ('Hostname') Do Set V=%%~I&lt;/P&gt;

&lt;P&gt;setlocal enabledelayedexpansion&lt;BR /&gt;
set d=%date:~0,2%&lt;BR /&gt;
set m=%date:~3,2%&lt;BR /&gt;
set y=%date:~6,4%&lt;BR /&gt;
if %d:~0,1%==0 set d=%d:~1%&lt;BR /&gt;
if %m:~0,1%==0 set m=%m:~1%&lt;BR /&gt;
set /a feb=y%%4&lt;BR /&gt;
if %feb%==0 (set feb=29) else (set feb=28)&lt;BR /&gt;
set /a tok=m-1&lt;BR /&gt;
if %tok%==0 set tok=12&lt;BR /&gt;
for /f "tokens=%tok%" %%i in ("31 %feb% 31 30 31 30 31 31 30 31 30 31") do (&lt;BR /&gt;
:: минус 1 month  set /a m-=1&lt;BR /&gt;
   set /a m-=1&lt;BR /&gt;
    if !d!==0 (&lt;BR /&gt;
        set d=%%i&lt;BR /&gt;
        set m=%tok%&lt;BR /&gt;
        if !m!==12 set /a y-=1&lt;BR /&gt;
    )&lt;BR /&gt;
)&lt;BR /&gt;
set d=0%d%&lt;BR /&gt;
set m=0%m%&lt;BR /&gt;
set lastmonth=%y%-%m:~-2%&lt;/P&gt;

&lt;P&gt;@copy "\%V%\SQLLOGS$\ERRORLOG.&lt;EM&gt;" errorlog.&lt;/EM&gt;.%V% /Z&lt;BR /&gt;
@find "%lastmonth%" Errorlog..%V% &amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.1.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.2.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.3.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.4.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.5.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.6.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.7.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.8.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.9.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.10.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.11.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.12.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.13.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.14.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.15.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.16.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.17.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.18.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.19.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.20.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.21.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.22.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.23.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.24.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.25.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.26.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.27.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.28.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.29.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.30.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.31.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.32.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.33.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.34.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.35.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.36.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.37.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.38.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.39.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.40.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.41.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.42.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.43.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.44.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.45.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.46.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.47.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.48.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.49.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "%lastmonth%" Errorlog.50.%V% &amp;gt;&amp;gt; out2.%V%&lt;BR /&gt;
@find "Logon" out2.%V% &amp;gt; out.%V%&lt;BR /&gt;
@del out2.*&lt;BR /&gt;
MonthREport2005.exe %lastmonth% out.%V% outlog%V%.txt %V% 2008&lt;/P&gt;

&lt;P&gt;@type outlog%V%.txt &amp;gt;&amp;gt; SumLog.txt&lt;/P&gt;

&lt;P&gt;@del Errorlog*&lt;BR /&gt;
@del outlog%V%.txt&lt;BR /&gt;
:@del out.*&lt;/P&gt;

&lt;P&gt;It doesn't work. How can I check what happened in splunk and why this is not work?&lt;BR /&gt;
If I start this code throught cmd it works.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:42:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382937#M94286</guid>
      <dc:creator>atyshke1</dc:creator>
      <dc:date>2020-09-29T20:42:57Z</dc:date>
    </item>
    <item>
      <title>Re: Can't launch bat file at UF</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382938#M94287</link>
      <description>&lt;P&gt;hi @atyshke1&lt;/P&gt;

&lt;P&gt;can you follow this link &lt;/P&gt;

&lt;P&gt;&lt;A href="https://answers.splunk.com/answers/242242/how-to-run-batch-file-in-splunk.html"&gt;https://answers.splunk.com/answers/242242/how-to-run-batch-file-in-splunk.html&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;&lt;A href="http://docs.splunk.com/Special:SpecialLatestDoc?t=Documentation/Splunk/latest/Deploy/Introducingtheuniversalforwarder"&gt;http://docs.splunk.com/Special:SpecialLatestDoc?t=Documentation/Splunk/latest/Deploy/Introducingtheuniversalforwarder&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Aug 2018 12:04:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382938#M94287</guid>
      <dc:creator>harishalipaka</dc:creator>
      <dc:date>2018-08-02T12:04:13Z</dc:date>
    </item>
    <item>
      <title>Re: Can't launch bat file at UF</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382939#M94288</link>
      <description>&lt;P&gt;The second link doesn't work&lt;BR /&gt;
Regarding first link, I tried and it works but doesn't work with my code &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Aug 2018 12:15:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382939#M94288</guid>
      <dc:creator>atyshke1</dc:creator>
      <dc:date>2018-08-02T12:15:01Z</dc:date>
    </item>
    <item>
      <title>Re: Can't launch bat file at UF</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382940#M94289</link>
      <description>&lt;P&gt;So, I can start bat file,&lt;BR /&gt;
But I have another issue now. Bat file start ok when I start it by myself. When I restart UF, he try to start bat file. AS per splunkd.log it start then create a files but after some jobs with those files the files doesn't copy to  folder where located UF. If I start again by myself, the csript will do all jobs which indicated in bat file. It seems that universal forward can't do any command in bat file or maybe UF need additional NTFS permission. How can I check this? I can't see any error info in splunkd.log&lt;/P&gt;</description>
      <pubDate>Tue, 07 Aug 2018 13:49:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Can-t-launch-bat-file-at-UF/m-p/382940#M94289</guid>
      <dc:creator>atyshke1</dc:creator>
      <dc:date>2018-08-07T13:49:04Z</dc:date>
    </item>
  </channel>
</rss>

