Splunk Enterprise

Inline field extractions in props.conf not working

Danny_Williams
Engager

I've read the documentation for inline field extractions and I don't see what I'm doing wrong here. I've added a props.conf file to my test app with the following:

[emm_syslog]
LINE_BREAKER = ([\r\n]+)
category = Application
disabled = false
EXTRACT-emm_syslog = <(?<priority>[\d]+)>\d (?<timestamp>\S+) (?<hostname>\S+) (?<app_name>\S+) (?<proc_id>\S+) (?<msg_id>\S+) \[(?<sd_id>\S+) auditType=\"(?<audit_type>\S+)\" tenantId=\"(?<tenant_id>\S+)\"\] (?<message>.*)

 

This regex matches my test event on regex101.com:

<135>1 2024-01-02T14:34:51.429Z TestServer EMM_Console 9176 FULL [emmAudit@18060 auditType="Console" tenantId="EMM"] "Console","2024-01-02T14:34:51.429+00:00","username","127.0.0.1","","CCON0030","Admin Login",,"Info","SUCCESS","0",,"Admin User Login Success (HTTPS)"

 

Within the Search app, however, none of these capture groups are extracted. Am I doing something obviously wrong here, or how should I proceed with troubleshooting ?

Labels (2)
0 Karma
1 Solution

dtburrows3
Builder

Check your permissions in local.meta or default.meta of your test app.

If you want this extractions to work in other app contexts then you may need to export and make it readable to your desired roles.

Example:
$SPLUNK_HOME/etc/apps/<test_app>/metadata/local.meta

[props/emm_syslog/EXTRACT-emm_syslog]
access = read : [ * ], write : [ admin ]
export = system

 

View solution in original post

dtburrows3
Builder

Check your permissions in local.meta or default.meta of your test app.

If you want this extractions to work in other app contexts then you may need to export and make it readable to your desired roles.

Example:
$SPLUNK_HOME/etc/apps/<test_app>/metadata/local.meta

[props/emm_syslog/EXTRACT-emm_syslog]
access = read : [ * ], write : [ admin ]
export = system

 

Danny_Williams
Engager

Ahh yes it works now, thank you! I was going crazy trying to think of reasons the regex wasn't matching.

0 Karma
Get Updates on the Splunk Community!

Index This | I’m short for "configuration file.” What am I?

May 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with a Special ...

New Articles from Academic Learning Partners, Help Expand Lantern’s Use Case Library, ...

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Your Guide to SPL2 at .conf24!

So, you’re headed to .conf24? You’re in for a good time. Las Vegas weather is just *chef’s kiss* beautiful in ...