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!

October Community Champions: A Shoutout to Our Contributors!

As October comes to a close, we want to take a moment to celebrate the people who make the Splunk Community ...

Community Content Calendar, November Edition

Welcome to the November edition of our Community Spotlight! Each month, we dive into the Splunk Community to ...

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

What are Community Office Hours? Community Office Hours is an interactive 60-minute Zoom series where ...