Splunk Search

How do I parse single-line entries for stacked timechart?

mikeely
Path Finder

I've got a scripted input that dumps a line like the following every minute:

2011-12-22 08:46:56,0,30,6

What I'd like to do is parse it for a stacked timechart as follows:
Datestamp, Critical, Error, Warning

I know the comma is my delimiter, but beyond that I'm kind of at a loss. Any help?

Tags (2)
0 Karma
1 Solution

mikeely
Path Finder

Self-answering:

sourcetype="my_custom_sourcetype" | timechart sum("Critical"),sum("Error"),sum("Warning") by time

View solution in original post

0 Karma

mikeely
Path Finder

Self-answering:

sourcetype="my_custom_sourcetype" | timechart sum("Critical"),sum("Error"),sum("Warning") by time

0 Karma

mikeely
Path Finder

Update: I managed to use the IFX to correctly parse the fields so Critical/Error/Warning are being counted. Now I need to figure out how to do the stacked area chart based on COUNT(Critical),COUNT(Error),COUNT(Warning) for each time the script generates a row.

0 Karma
Get Updates on the Splunk Community!

Splunk Education - Fast Start Program!

Welcome to Splunk Education! Splunk training programs are designed to enable you to get started quickly and ...

Five Subtly Different Ways of Adding Manual Instrumentation in Java

You can find the code of this example on GitHub here. Please feel free to star the repository to keep in ...

New Splunk APM Enhancements Help Troubleshoot Your MySQL and NoSQL Databases Faster

Splunk Observability has two new enhancements to make it quicker and easier to troubleshoot slow or frequently ...