Splunk Search

How to list _key value pairs for all entities in ITSI ?

Suara
Explorer

Hello all ! 

Can anyone help me in editing the below SPL so it can only list the _key - value paris for the entities ? 

| rest splunk_server=local /servicesNS/nobody/SA-ITOA/itoa_interface/entity report_as=text
fields="_key,title,identifier,informational,identifying_name"
| eval value=spath(value,"{}")
| mvexpand value
| eval entity_title=spath(value, "title"),
entity_name=spath(value, "identifying_name"),
entity_aliases=mvzip(spath(value, "identifier.fields{asd}"),spath(value, "identifier.values{}"),"="),
entity_info=mvzip(spath(value, "informational.fields{}"),spath(value, "informational.values{}"),"=")


This is a solution i found online but its rather complicated for my SPL skills at the moment.... 

Thank you in advance ! 

Labels (3)
0 Karma

yuanliu
SplunkTrust
SplunkTrust

Maybe you can share sample search results (full text, anonymize as needed) and let us know which XML nodes represent "entities"?  Is there anything wrong with the search you posted?  If the search produces what you need, what kind of change do you want?

Based on that posted search, I speculate that there is no inherent structure in search results that tells user what are key-value pairs of an "entity".  In other words, the so-called "entity" is a construct invented by whoever posted this search.  Without knowing actual data structure, it is fruitless for volunteers to try simplification.

0 Karma

Suara
Explorer

Hey thanks for the comment ! I will formulate my question better and share more information as needed 

0 Karma
Get Updates on the Splunk Community!

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer at Splunk .conf24 ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...

Share Your Ideas & Meet the Lantern team at .Conf! Plus All of This Month’s New ...

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