Splunk Search

メインサーチのイベントの時間をサブサーチに渡したい

midcoffessplunk
Engager

メインサーチのイベントの_timeをサブサーチに渡したいのですが、上手くいきません。

何か方法はありますでしょうか。

 

index=event_data

|eval earlytime=_time-60 latesttime=_time+60

|fields earlytime,latesttime

[

|search index=event_data2 earliest=earlytime latest=latesttime

|return event_host,event_user

]

|table event_host,event_user

 

ご助力お願いします。

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

millarma
Path Finder

sorry to be so slow to respond.  so there are a few ways to do this.  starting with your example, you need to change the '=' sign to '>' and '<' signs.  so earliest>earlytime latest<latesttime.  

This will mean that splunk will show events that happen during the time between those two.


View solution in original post

millarma
Path Finder

sorry to be so slow to respond.  so there are a few ways to do this.  starting with your example, you need to change the '=' sign to '>' and '<' signs.  so earliest>earlytime latest<latesttime.  

This will mean that splunk will show events that happen during the time between those two.


Get Updates on the Splunk Community!

Enterprise Security Content Update (ESCU) | New Releases

In December, the Splunk Threat Research Team had 1 release of new security content via the Enterprise Security ...

Why am I not seeing the finding in Splunk Enterprise Security Analyst Queue?

(This is the first of a series of 2 blogs). Splunk Enterprise Security is a fantastic tool that offers robust ...

Index This | What are the 12 Days of Splunk-mas?

December 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...