Getting Data In

Is it possible to use regular expressions and wildcard in the monitoring stanza of inputs.conf?

ankithreddy777
Contributor

In inputs.conf for monitor stanza, can we write regex?

If so,
/opt/splunk/cgate* matches (/opt/splunk/cgateee) or (/opt/splunk/cgateabd)

Can we use wildcards(*) for whitelist attribute?

0 Karma

ddrillic
Ultra Champion

The * wildcard is available. Explained nicely at Note concerning wildcards and monitor:

It says -

alt text

I usually check myself by running the monitor part in ls -

ls /opt/splunk/cgate*. If it returns the desired /opt/splunk/cgateee and/or /opt/splunk/cgateabd I know I'm fine.

0 Karma

C_HIEN
Path Finder

Sure, you can add regex to whitelist/blacklist in inputs.conf.

You can found the doc here: (http://docs.splunk.com/Documentation/Splunk/latest/Data/Whitelistorblacklistspecificincomingdata).

If you add whitelist = \.log$, Splunk will monitor only *.log files

0 Karma
Get Updates on the Splunk Community!

Threat Hunting Unlocked: How to Uplevel Your Threat Hunting With the PEAK Framework ...

WATCH NOWAs AI starts tackling low level alerts, it's more critical than ever to uplevel your threat hunting ...

Splunk APM: New Product Features + Community Office Hours Recap!

Howdy Splunk Community! Over the past few months, we’ve had a lot going on in the world of Splunk Application ...

Index This | Forward, I’m heavy; backward, I’m not. What am I?

April 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...