Monitor in Splunk: Assign filename extension to sourcetype

Problem

  • You want to monitor a folder and want to automatic assign sourcetypes to filename extension

Solution

  1. Create your sourcetypes (example ABC and DEF)
  2. Open or create /$SPLUNK_HOME/etc/system/local/props.conf

[source::/opt/example/*.abc]
sourcetype = ABC

[source::/opt/example/*.def]
sourcetype = DEF

Fin

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s