Alerting

Error in 'sendalert' command: Alert script returned error code 2.

katshima
New Member

I am generating alarms by acquiring abnormal values for CPU usage of NW devices.
I would like to send these alarms via email or webhook, but I get the above error and cannot send them.

What is the cause?

Error in 'sendalert' command: Alert script returned error code 2.

Labels (1)
0 Karma

fredclown
Builder

You can search the internal Splunk logs to see if there are any errors logged. If you run this what do you get?

index=_internal sendemail sourcetype!=splunkd_ui_access sourcetype!=splunkd_remote_searches ERROR

 

0 Karma
Get Updates on the Splunk Community!

Enterprise Security (ES) Essentials 8.3 is Now GA — Smarter Detections, Faster ...

As of today, Enterprise Security (ES) Essentials 8.3 is now generally available, helping SOC teams simplify ...

AI for AppInspect

We’re excited to announce two new updates to AppInspect designed to save you time and make the app approval ...

App Platform's 2025 Year in Review: A Year of Innovation, Growth, and Community

As we step into 2026, it’s the perfect moment to reflect on what an extraordinary year 2025 was for the Splunk ...