Splunk Search

How can I search count by DN based on my sample event?

sid19920
New Member

How can I do search count by dn here? tag=101 means search. I have already used transaction conn to separate based on connection numberalt text

0 Karma

sundareshr
Legend

Try this instead of using transaction

*EDITED*

 your base search | eventstats values(dn) as dn by conn | where tag=101 | timechart count by dn usenull=f useother=f
0 Karma

sid19920
New Member

This is a preview of how the data is indexed initiallyalt text

0 Karma

sid19920
New Member

https://postimg.org/image/igb8y7ohv/. I couldn't as I don't have enough karma points. Can you see the link now?

0 Karma

sundareshr
Legend

yes. i see it now

0 Karma

sundareshr
Legend

I assume the events you shared are from a search like this your base search tag=101, right? Because I don't see dn= anywhere. Try the updated query I posted.

0 Karma

sid19920
New Member

the events i have posted are without any search. Just the raw file. When I do search for tag=101 all the dn fields disappear. I did get an output using the new query but the result is different from what I expected and its not a timechart

0 Karma

sid19920
New Member

The graphs should look like this. The first one is for Search count by DN and the second one is for Search count duration by DN. I need help with both pleasealt text

0 Karma

sundareshr
Legend

Try the edited query

0 Karma

sid19920
New Member

I did. It doesn't work. I think you'd be able to solve it if I can send you the log file

0 Karma

sundareshr
Legend

That'll be great. Share a few events

0 Karma

sid19920
New Member

alt text

Thnx.Ive added a link to the image url for you.

0 Karma

sundareshr
Legend

I don't see the link. All I see is alt text. Just paste a few events to your original question

0 Karma

sid19920
New Member

Thnx for the reply. Sorry but it says "No results". If i don't use transaction then the events are not grouped based on conn number. The DN value is only present after the binding is complete so I used transaction so that the dn and SRCH are grouped in same event.

0 Karma
Get Updates on the Splunk Community!

Index This | Why did the turkey cross the road?

November 2025 Edition  Hayyy Splunk Education Enthusiasts and the Eternally Curious!   We’re back with this ...

Enter the Agentic Era with Splunk AI Assistant for SPL 1.4

  🚀 Your data just got a serious AI upgrade — are you ready? Say hello to the Agentic Era with the ...

Feel the Splunk Love: Real Stories from Real Customers

Hello Splunk Community,    What’s the best part of hearing how our customers use Splunk? Easy: the positive ...