Splunk Search

Can you help to match events with an inputlookup search?

jip31
Motivator

Hi,

I use the basic query below in order to collect the model of a host (workstation)

index="xx" sourcetype="WMI:Model" | table host Model

In parallel, I have a CSV file called "cmdb" where there is a field called "HOSTNAME", which refers to the field "host" in my search

I want to match these 2 fields (host and HOSTNAME) in order to collect in a same table the host, the Model and other fields of my CSV file like CLIENT_USER COUNTRY STATUS ROOM SITE & TOWN

Could you help me please??

0 Karma
1 Solution

chrisyounger
SplunkTrust
SplunkTrust

Try this: index="xx" sourcetype="WMI:Model" |fields host Model | lookup cmdb HOSTNAME as host OUTPUTNEW | table *

View solution in original post

chrisyounger
SplunkTrust
SplunkTrust

Try this: index="xx" sourcetype="WMI:Model" |fields host Model | lookup cmdb HOSTNAME as host OUTPUTNEW | table *

avoelk
Communicator

I know this answer is pretty old but, does this kind of lookup match command work within tstats or how would I need to re arrange it? 

 

0 Karma

jip31
Motivator

perfect thanks

0 Karma
Get Updates on the Splunk Community!

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...

Splunk Custom Visualizations App End of Life

The Splunk Custom Visualizations apps End of Life for SimpleXML will reach end of support on Dec 21, 2024, ...