Splunk Search

Timecharts, distinct count and Total distinct count

jerwood
New Member

This may be simple, but I am pretty new to splunk in general and my attempts have not proved fruitful yet.

So I have a search returns a timechart of distinct users per State for an event, works fine. Timechart auto breaks it down which can be tuned, no problems there. What I want to do though, is add one final line to my timechart that is a "cumulative distinct count" for the search. The catch is, I want it to be a DC for the WHOLE timeframe, not just a sum of each dc timechart splits up into (aka addtotals col=t is not what I am looking for).

Any thoughts?

Tags (2)
0 Karma

jerwood
New Member

Edit: Here is the search string

index=cap type="AcctBadPswd" | geoip fromhost | search fromhost_country_name="United States"|timechart dc(user) by fromhost_region_name limit=55 usenull=0 useother=0

PS: I am having a TERRIBLE time with captchas on this site, worst ever... I can't edit my original post, always fails.

0 Karma

gfuente
Motivator

I think you are looking for

...| eventstats dc(users) | ...

Or something similar, please add your base search and sample events to get more information

0 Karma
Get Updates on the Splunk Community!

Introducing Splunk Enterprise 9.2

WATCH HERE! Watch this Tech Talk to learn about the latest features and enhancements shipped in the new Splunk ...

Adoption of RUM and APM at Splunk

    Unleash the power of Splunk Observability   Watch Now In this can't miss Tech Talk! The Splunk Growth ...

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...