Splunk Search

How to get the difference of time between 2 events

gajananh999
Contributor

Hello Everyone,

I have events like

02-Jul-2014 09:25:25 AM: ========== Finish Transmit Process ==========

02-Jul-2014 09:25:25 AM: AA Proc for AttachmentTransmission

02-Jul-2014 09:25:25 AM: AA Software (Axway Synchrony) version is not setup in ESM Schema in table EDI_TYPE_CD. Default version of EDI Software is 4.2

02-Jul-2014 09:25:25 AM: AA Service Login to 'AA' Database with UserID 'AA' Successfully

02-Jul-2014 09:25:23 AM: ========== Start Transmit Process ==========

So i want to find out the Time which is take by process to complete its task. So here it will be 02.02 sec

Thanks

Gajanan Hiroji

0 Karma
1 Solution

Ayn
Legend

Create a transaction that starts with the "Start Transmit Process" line and ends with the "Finish Trnamit Process" line. The transaction command will automatically create a field duration which gives you the duration of the transaction, which is the same as the time difference between the start and end event.

... | transaction startswith="========== Start Transmit Process ==========" endswith="========== Finish Transmit Process =========="

View solution in original post

Ayn
Legend

Create a transaction that starts with the "Start Transmit Process" line and ends with the "Finish Trnamit Process" line. The transaction command will automatically create a field duration which gives you the duration of the transaction, which is the same as the time difference between the start and end event.

... | transaction startswith="========== Start Transmit Process ==========" endswith="========== Finish Transmit Process =========="

gajananh999
Contributor

Thanks Ayn.

0 Karma
Get Updates on the Splunk Community!

Join Us for Splunk University and Get Your Bootcamp Game On!

If you know, you know! Splunk University is the vibe this summer so register today for bootcamps galore ...

.conf24 | Learning Tracks for Security, Observability, Platform, and Developers!

.conf24 is taking place at The Venetian in Las Vegas from June 11 - 14. Continue reading to learn about the ...

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...