Splunk Search

where does splunk store output of shell scripts?

batemanj
New Member

Hi,

On Splunk forwarders, we have few shell scripts in "SPLUNK_HOME/etc/apps/my_app/bin/" that are being run. Just wondering where do the outputs of these shell scripts store? Shell scripts don't have the output filename in them so I tried to look into "SPLUNK_HOME/var/log/splunk" but no luck. Are these outputs store in "*.dat" file which we can't read?

Thanks

Tags (1)
0 Karma
1 Solution

woodcock
Esteemed Legend

If you are running scripted inputs, then Splunk will index the output that it sees hitting stdout. This means that you can pipe the output of your scripts to other things and Splunk will only index the final text that hits stdout. Any other output that goes anywhere else will be ignored by Splunk, unless of course you are writing it to file and have a different [monitor://...] stanza looking for it, which would be strange.

View solution in original post

0 Karma

woodcock
Esteemed Legend

If you are running scripted inputs, then Splunk will index the output that it sees hitting stdout. This means that you can pipe the output of your scripts to other things and Splunk will only index the final text that hits stdout. Any other output that goes anywhere else will be ignored by Splunk, unless of course you are writing it to file and have a different [monitor://...] stanza looking for it, which would be strange.

0 Karma

burwell
SplunkTrust
SplunkTrust

So you are doing scripted input? Splunk runs the script on the interval you specify and then indexes the output. I don't think there's an intermediate location.

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Why Splunk Customers Should Attend Cisco Live 2026 Las Vegas

Why Splunk Customers Should Attend Cisco Live 2026 Las Vegas     Cisco Live 2026 is almost here, and this ...

What Is the Name of the USB Key Inserted by Bob Smith? (BOTS Hint, Not the Answer)

Hello Splunkers,   So you searched, “what is the name of the usb key inserted by bob smith?”  Not gonna lie… ...

Automating Threat Operations and Threat Hunting with Recorded Future

    Automating Threat Operations and Threat Hunting with Recorded Future June 29, 2026 | Register   Is your ...