No matter what I do, I am unable to get the input to load, it fails with...
Fatal 2014-11-04T15:54:24.7870003Z Failed to parse stanza name="powershell://PowerShell-Test" Unexpected end of expression.
Info 2014-11-04T15:54:24.8026266Z Modular PowerShell Initialized Successfully: 0 Jobs Loaded
Debug 2014-11-04T15:54:25.0057597Z Scheduler Started. Scheduling 0 Jobs
inputs.conf...
[powershell://PowerShell-Test]
index = powershelltest
schedule = 51 10 4 * *
script = . "$SPLUNK_HOME\bin\scripts\PowerShellTest.ps1"
sourcetype = Windows:PowerShell
I have tried multiple ways...
script = . "E:\Splunk\bin\scripts\PowerShellTest.ps1"
script = . "$SPLUNK_HOME\bin\scripts\PowerShellTest.ps1 -pcgSrvs TestSrv"
script = . "$SPLUNK_HOME\bin\scripts\PowerShellTest.ps1 TestSrv"
script = . "$SPLUNK_HOME\bin\scripts\PowerShellTest.ps1" "TestSrv"
I know it's not a permissions thing for PowerShell because the script works correctly the old way using the .path file...
Inputs.conf...
[script://$SPLUNK_HOME\bin\scripts\PowerShellTest.path]
index = powershelltest
interval = 32 10 3 * *
sourcetype = Windows:PowerShell
PowerShellTest.path....
$SystemRoot\System32\WindowsPowerShell\v1.0\powershell.exe -command "& $SPLUNK_HOME\bin\scripts\PowerShellTest.ps1" "TestSrv"
Environment...
Splunk 6.2
SA-ModularInput-PowerShell 1.2.0
Windows 2012 R2 64Bit
PowerShell 4.0
So I am not sure what "Unexpected end of expression" is referring to or how to troubleshoot it.
Any assistance is greatly appreciated,
Scott
... View more