Splunk Search

How to find a host from a list of hosts in a file?

gokulakrishnans
Explorer

I need to refer to a table file which contains a list of servers. Need to check with all the servers like a loop which shows the status as 200-Means success/OtherErrorCode-Unsuccessful.

If any of the servers in the list is having other than 200, then an alert should be triggered.

Tags (1)
0 Karma

richgalloway
SplunkTrust
SplunkTrust

Use a subsearch.

index=foo status!=200 [ | inputlookup serverList.csv ] | ...
---
If this reply helps you, Karma would be appreciated.
0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to November Tech Talks, Office Hours, and Webinars!

🍂 Fall into November with a fresh lineup of Community Office Hours, Tech Talks, and Webinars we’ve ...

Transform your security operations with Splunk Enterprise Security

Hi Splunk Community, Splunk Platform has set a great foundation for your security operations. With the ...

Splunk Admins and App Developers | Earn a $35 gift card!

Splunk, in collaboration with ESG (Enterprise Strategy Group) by TechTarget, is excited to announce a ...