Splunk Search

Sme search with same slot time doesnt returns same number of events

jip31
Motivator

Hi
I have something strange
when I execute the search below, I have 47 events on a one week slot time

eventtype="AppliService" AND (NOT host=E* AND NOT host=I*) Name="MBAMAgent"  State="Stopped" 
| dedup host 
| table _time host DisplayName Name Started State

when I execute the search below on the same slot time, I have only 4 events for MBAMAgent

**eventtype="AppliService" AND (NOT host=E* AND NOT host=I***) (Name="dot3svc" OR Name="WlanSvc" OR Name="Winmgmt" OR Name="LanWlanSwitchingService" OR Name="PCServicesWinSrv" OR Name="CcmExec" OR Name="vpnagent" OR Name="wuauserv"OR Name="RCAgentMgr" OR Name="W32Time" OR **Name="MBAMAgent"** OR Name="BDESVC" OR Name="mfevtp" OR Name="mfemms" OR Name="McAfeeFramework" ) **State="Stopped"** 
| dedup host 
| table _time host DisplayName Name Started State

How is it possible because I use the same searc fields?
Thanks for your help

Tags (1)
0 Karma
1 Solution

cvssravan
Path Finder

That could be because for the same host, there might be multiple Name values. Dedup returns only the latest. So, In order to get the same count for Name=MBAMAgent, you need to add the Name field to dedup command

eventtype="AppliService" AND (NOT host=E* AND NOT host=I*) (Name="dot3svc" OR Name="WlanSvc" OR Name="Winmgmt" OR Name="LanWlanSwitchingService" OR Name="PCServicesWinSrv" OR Name="CcmExec" OR Name="vpnagent" OR Name="wuauserv" OR Name="RCAgentMgr" OR Name="W32Time" OR Name="MBAMAgent" OR Name="BDESVC" OR Name="mfevtp" OR Name="mfemms" OR Name="McAfeeFramework" ) State="Stopped"
| dedup host Name
| table _time host DisplayName Name Started State

View solution in original post

cvssravan
Path Finder

That could be because for the same host, there might be multiple Name values. Dedup returns only the latest. So, In order to get the same count for Name=MBAMAgent, you need to add the Name field to dedup command

eventtype="AppliService" AND (NOT host=E* AND NOT host=I*) (Name="dot3svc" OR Name="WlanSvc" OR Name="Winmgmt" OR Name="LanWlanSwitchingService" OR Name="PCServicesWinSrv" OR Name="CcmExec" OR Name="vpnagent" OR Name="wuauserv" OR Name="RCAgentMgr" OR Name="W32Time" OR Name="MBAMAgent" OR Name="BDESVC" OR Name="mfevtp" OR Name="mfemms" OR Name="McAfeeFramework" ) State="Stopped"
| dedup host Name
| table _time host DisplayName Name Started State

jip31
Motivator

yes it was the issue....... thanks a lot

0 Karma

chrisyounger
SplunkTrust
SplunkTrust

Wierd.

Are the extra "*" from trying to making things bold on the forums?

Is it becuase there is no space here: Name="wuauserv"OR

Can you use the job inspector >Search log and compare the lispy?

0 Karma

jip31
Motivator

Ohhhhhhhh.... thanks!

0 Karma
Get Updates on the Splunk Community!

Observe and Secure All Apps with Splunk

  Join Us for Our Next Tech Talk: Observe and Secure All Apps with SplunkAs organizations continue to innovate ...

Splunk Decoded: Business Transactions vs Business IQ

It’s the morning of Black Friday, and your e-commerce site is handling 10x normal traffic. Orders are flowing, ...

Fastest way to demo Observability

I’ve been having a lot of fun learning about Kubernetes and Observability. I set myself an interesting ...