Getting Data In

host_regex syntax for SMB share?

the_wolverine
Champion

I need a syntax example for host_regex to pull the hostname out of a share like the following:

[monitor://\\norcal_server\c$\Windows\System32\LogFiles]
0 Karma

kristian_kolb
Ultra Champion

Since the messageboard seems to be rather moody today, I'm having trouble writing HTML-specific characters at the moment, like < or >, so here goes.

\[monitor\:\/+\\+(?< HOST >[^\\]+)\\

You'd have to remove the spaces surrounding HOST..

or perhaps, even simpler

\\{2}(?< host >[^\\]+)\\

Hope this helps,

Kristian

0 Karma
Get Updates on the Splunk Community!

Introducing the Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...

Get the T-shirt to Prove You Survived Splunk University Bootcamp

As if Splunk University, in Las Vegas, in-person, with three days of bootcamps and labs weren’t enough, now ...

Wondering How to Build Resiliency in the Cloud?

IT leaders are choosing Splunk Cloud as an ideal cloud transformation platform to drive business resilience,  ...