Splunk Enterprise

qq

chandankr
Path Finder
 
Labels (1)
Tags (1)
0 Karma

chandankr
Path Finder

request your help on this 

0 Karma

chandankr
Path Finder

thanks @ITWhisperer  for your reply . i am trying to fetch data based on data_center and create four fields that is AvgCpuLoad-UKDC MaxCpuLoad-UKDC AvgCpuLoad-USDC MaxCpuLoad-USDC.

0 Karma

ITWhisperer
SplunkTrust
SplunkTrust

If what I suggested doesn't work for you, perhaps you could share some of your raw events in a code block </> and the output from my suggestion?

0 Karma

ITWhisperer
SplunkTrust
SplunkTrust

Try something like this

| ...... base search 

| rex field=_raw "measResults\W(?<avgCpuUtilization>\d{0,3})\s(?<maxCpuUtilization>\d{0,3})"
| rex field=_raw "PLMN-PLMN\W\w+-\d\W\w\w\w-\d{0,3}.\d{0,3}.\d{0,3}.\d{0,3}@(?<data_center>\w+-\w+)"
| rex field=_raw " endTime\D\D(?<year>\d{0,4})\D(?<month>\d\d)\D(?<date>\d\d)"
| eval order = case(month==1,"january", month==2,"february", month==3,"march", month==4,"april", month==5,"may", month==6,"june", month==7,"july", month==8,"august", month==9,"september", month==10,"october", month==11,"november", 1==1, "december")
| chart avg(avgCpuUtilization) as AvgCpuLoad max(maxCpuUtilization) as MaxCpuLoad by order, data_center
| eval order = upper(order)
| rename "AvgCpuLoad: LVS_DC" as "AvgCpuLoad-UKDC", "AvgCpuLoad: RB_DC" as "AvgCpuLoad-USDC", "MaxCpuLoad: LVS_DC" as "MaxCpuLoad-UKDC", "MaxCpuLoad: RB_DC" as "MaxCpuLoad-USDC"
0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Can’t Make It to Boston? Stream .conf25 and Learn with Haya Husain

Boston may be buzzing this September with Splunk University and .conf25, but you don’t have to pack a bag to ...

Splunk Lantern’s Guide to The Most Popular .conf25 Sessions

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

Unlock What’s Next: The Splunk Cloud Platform at .conf25

In just a few days, Boston will be buzzing as the Splunk team and thousands of community members come together ...