Deployment Architecture

to provide the list of P1C alerts for  JMET cluster from Splunk

Splunk-Star
Loves-to-Learn Lots

There is a request to provide the list of P1C alerts for  JMET cluster from Splunk
we have provided the following query, but user wants only priority will be P1C

| rest /servicesNS/-/-/saved/searches
| table title, eai:acl.owner, search, actions, action.apple_alertaction *

This query is giving all the alerts configured but we want only P1C alerts.

Its urgent.

Labels (1)
0 Karma

deepakc
Builder

I suspect you want to know about priority alerts, but how will Splunk magically know about this? 

Its always better to give good context to the Splunk communiy, so what is P1C? and JMET sounds like some internal Splunk environment company code (which you should anonymise) 

Unless you have say for instance in the saved search title name P1C, example, my_search_P1C, Splunk will not be able to find it or filter on it.

Or you will need to use the eval command and for each saveded that you know is a P1C and assign a eval field called priority, but will require a lot of work. 

Tip: As ever its always best practise to have good business naming conventions, makes things easier in the long run

Example using makeresults to assign PC1

| makeresults count=2
| streamstats count as search_num
| eval title=case(search_num=1, "my_savedsearch1", search_num=2, "my_savedsearch2")
| eval priority=if(title=="my_savedsearch1", "P1C", null())
| fields - search_num

 

 

 

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, ...