Splunk Search

Convert point in time events to timeseries with Data points

SplunkNs231
Engager

I have the following data. That I am trying to convert to a time series by Type with the last Status brought forward.

Raw data:

TimestampStatusType
10/28/2021 12:00downB
10/28/2021 12:10upA
10/28/2021 12:30upB
10/28/2021 13:10downB
10/28/2021 13:30upB

 

After transformation I need a data point every 10 minutes for each Type with the pervious Status brought forward. Note I could have 40-50 different types.

Example Transformation:

TimestampStatusType
10/28/2021 12:00downB
10/28/2021 12:10downB
10/28/2021 12:20downB
10/28/2021 12:30upB
10/28/2021 12:40upB
10/28/2021 12:50upB
10/28/2021 13:00upB
10/28/2021 13:10downB
10/28/2021 13:20downB
10/28/2021 13:30upB
10/28/2021 13:40upB

 

Any Ideas?

Labels (1)
Tags (1)
0 Karma
1 Solution

PickleRick
Ultra Champion
<your search>
| timechart span=10m last(status) by Type 
| filldown
| untable _time Type Status

Mind you that you might not get values at the beginning since you don't have any initial value.

Of course you might want to | sort at the end to your liking.

View solution in original post

0 Karma

PickleRick
Ultra Champion
<your search>
| timechart span=10m last(status) by Type 
| filldown
| untable _time Type Status

Mind you that you might not get values at the beginning since you don't have any initial value.

Of course you might want to | sort at the end to your liking.

0 Karma
Get Updates on the Splunk Community!

This Week's Community Digest - Splunk Community Happenings [9.26.22]

Get the latest news and updates from the Splunk Community here! Upcoming User Group Events! &#x1f44f; Check ...

BSides Splunk 2022 - The Call for Papers is now Open!

TLDR; Main Site: https://bsidessplunk.com CFP Site: https://bsidessplunk.com/cfp CFP Opens: December 15th, ...

Sending Metrics to Splunk Enterprise With the OpenTelemetry Collector

This blog post is part of an ongoing series on OpenTelemetry. The OpenTelemetry project is the second largest ...