Reporting

Automate lookup table to report to email

brc55
Explorer

Hello,

I currently upload data into a lookup table and have to also separately send this data manually to another team on a daily basis. Unfortunately, they do not/cannot have access to the lookup table in Splunk. Is there a way to automate this a little more by sending the data in the lookup table into a report and have that report emailed to a group of users daily?

 

 

Labels (1)
0 Karma
1 Solution

tscroggins
Influencer

Hi @brc55,

You can save an inputlookup search as an alert:

| inputlookup my_lookup ``` or my_lookup.csv etc. ```

After setting a schedule, add "Send email" as a triggered action. Under the Send email settings, select "Attach CSV." The search results will be attached the message a CSV file.

If your lookup file is large (greater than 10,000 rows), you may need to modify the maxresults setting in the alert_actions.conf [email] stanza:

# e.g. /opt/splunk/etc/system/local/alert_actions.conf

[email]
maxresults = 25000

 

View solution in original post

tscroggins
Influencer

Hi @brc55,

You can save an inputlookup search as an alert:

| inputlookup my_lookup ``` or my_lookup.csv etc. ```

After setting a schedule, add "Send email" as a triggered action. Under the Send email settings, select "Attach CSV." The search results will be attached the message a CSV file.

If your lookup file is large (greater than 10,000 rows), you may need to modify the maxresults setting in the alert_actions.conf [email] stanza:

# e.g. /opt/splunk/etc/system/local/alert_actions.conf

[email]
maxresults = 25000

 

brc55
Explorer

Will look into this. The lookup is within/associated to a specific app that the other team does not have access to. Would this cause an issue?

tscroggins
Influencer

The scheduled alert should be owned by a user with access to the app and (probably) be saved within the app. Their access to Splunk should have no bearing on whether they can access MIME attachments in their email client; however, they may not not be able to access any links you include. The CSV file will be an attachment, not a link.

tscroggins
Influencer

if your mail server limits attachment size or otherwise restricts message content, you should contact your mail administrator.

Get Updates on the Splunk Community!

Take Your Breath Away with Splunk Risk-Based Alerting (RBA)

WATCH NOW!The Splunk Guide to Risk-Based Alerting is here to empower your SOC like never before. Join Haylee ...

SignalFlow: What? Why? How?

What is SignalFlow? Splunk Observability Cloud’s analytics engine, SignalFlow, opens up a world of in-depth ...

Federated Search for Amazon S3 | Key Use Cases to Streamline Compliance Workflows

Modern business operations are supported by data compliance. As regulations evolve, organizations must ...