Splunk Search

Need help on rex

rishiaggarwal
Explorer

Hi Team,

Need help to extract fields for the following. Please help rex for the below.

    'ConnID'    '007202761fdb2c01'
    'VirtualQueue'  'ABC_EFG_BJFNKJFN'
Tags (1)
0 Karma
1 Solution

esix_splunk
Splunk Employee
Splunk Employee

If these are single line events:

\'ConnID\'\s+\'(?<ConnID>[^\']+)'

And

\'VirtualQueue\'\s+\'(?<VirtualQueue>[^\']+)'

Multiline events are a bit different. You need to make sure that the events are process properly as multiline, then you can do something like..

  (?m) \'ConnID\'\s+\'(?<ConnID>[^\']+)'\n\'VirtualQueue\'\s+\'(?<VirtualQueue>[^']+)'

View solution in original post

0 Karma

esix_splunk
Splunk Employee
Splunk Employee

If these are single line events:

\'ConnID\'\s+\'(?<ConnID>[^\']+)'

And

\'VirtualQueue\'\s+\'(?<VirtualQueue>[^\']+)'

Multiline events are a bit different. You need to make sure that the events are process properly as multiline, then you can do something like..

  (?m) \'ConnID\'\s+\'(?<ConnID>[^\']+)'\n\'VirtualQueue\'\s+\'(?<VirtualQueue>[^']+)'
0 Karma

Amohlmann
Communicator

Is that the full event? Which part are you trying to extract? What are the names of the fields here?

0 Karma

renjith_nair
Legend

@rishiaggarwal , Is that the full event ? Also please clarify what you want to extract

Happy Splunking!
0 Karma
Get Updates on the Splunk Community!

Webinar Recap | Revolutionizing IT Operations: The Transformative Power of AI and ML ...

The Transformative Power of AI and ML in Enhancing Observability   In the realm of IT operations, the ...

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...