Splunk Search

how to take the data if in the data with time stamp the value is separated with space.

pritamkumar01
Engager

my data for buffer use for a particular time is:
00:00:04: port 1, buffer 12221,
00:00:04: port 2, buffer 22,
00:00:04: port 3, buffer 3333,
00:00:04: port 4, buffer 0,
00:00:04: port 5, buffer 0,
00:00:04: port 6, buffer 0,
00:00:04: port 7, buffer 0,
00:00:04: port 8, buffer 122,

i want a graph of use of buffer by all ports at a timestamp.
kindly help .thanks in advance.

Tags (3)
0 Karma

martin_mueller
SplunkTrust
SplunkTrust

You can extract your port and buffer values like this:

... | rex "port (?<port>\d+), buffer (?<buffer>\d+)"

and then chart that over time like this:

... | timechart sum(buffer) by port

I've chosen sum(), but you may also be looking for avg() instead depending on your requirements.

Once you're happy with the field extraction within the search you should move it to the configuration, go to Settings -> Fields -> Field Extraction and add the expression there for your sourcetype, without the double quotes.

pritamkumar01
Engager

thanks for the help Mr Martin.

0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...