Splunk Search

How to get notified for indexer automatic detention

jpillai
Path Finder

Im not seeing any way Splunk will notify regarding automatic detention, which usually happens because of disk space issues

0 Karma

isoutamo
SplunkTrust
SplunkTrust

Hi

I think that the easiest way to get this is an activate MC's Alert: "DMC Alert - Abnormal State of Indexer Processor". Then it informs you e.g. with email that there is issue with indexer.

r. Ismo

0 Karma

jpillai
Path Finder

Thank you for the quick responses, I will certainly check on this and let you know. But it is a shame there is no better/obvious ways to do this in Splunk, given this is an important event.

0 Karma

sumanssah
Communicator

If looking for Splunk disk space issue, you can use your monitoring console for space details

Splunk >> Setting >> Monitoring Console >> Indexing >> Volume Detail Instance

or try below mentioned SPL

| rest /services/server/status/partitions-space | eval usage = capacity
- free | eval pct_usage = round(usage / capacity * 100, 2) | stats
first(fs_type) as fs_type first(usage) as usage first(capacity) as
capacity first(pct_usage) as pct_usage by splunk_server, mount_point

If you want to monitor Space issue in non-Splunk instances, try onboarding perfmon logs, onboarding details are on below mentioned Splunk answer

https://answers.splunk.com/answers/454999/how-to-develop-a-search-to-find-free-disk-space-us.html

index=perfmon sourcetype="Perfmon:Free Disk Space" counter="Free Megabytes" (instance!="HarddiskVolume*") (instance!=_Total) |dedup host
 | eval FreeSpace=(Value/1024)
 | eval GB=tostring(FreeSpace,"commas")
 | table host instance GB 
 | sort + host instance
 | rename instance as "Drive Letter" GB as "GigaBytes Free"
0 Karma

somesoni2
Revered Legend

The cluster master dashboard shows status of indexers (via REST call). You can setup an alert to which can query the indexer status at an interval and notify you when the status changes to AutomaticDetention. See this for rest api endpoint details.

https://docs.splunk.com/Documentation/Splunk/8.0.2/RESTREF/RESTcluster#cluster.2Fmaster.2Fpeers

In search query you could do something like this (run on cluster master node)

| rest splunk_server=local /services/cluster/master/peers | table title label status | where status="AutomaticDetention"
0 Karma

jpillai
Path Finder

@somesoni2 This is exactly what I was looking for, once I found there is no user friendly way of doing it. I have setup an alert with this on the master. Thank you 🙂

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.
Get Updates on the Splunk Community!

Tech Talk Recap | Mastering Threat Hunting

Mastering Threat HuntingDive into the world of threat hunting, exploring the key differences between ...

Observability for AI Applications: Troubleshooting Latency

If you’re working with proprietary company data, you’re probably going to have a locally hosted LLM or many ...

Splunk AI Assistant for SPL vs. ChatGPT: Which One is Better?

In the age of AI, every tool promises to make our lives easier. From summarizing content to writing code, ...