Splunk Search

join in search string

Splunk_U
Path Finder

I have a search string

index=os source=vmstat
| multikv fields memUsedPct memTotalMB memFreeMB
| stats avg(memUsedPct) as avgMemPct max(memUsedPct) as peakMemPct avg(memUsedMB) as avgMemMb max(memUsedMB) as peakMemMb by host
| join host [ search index=os source=cpu
| multikv fields pctIdle

| search all

| eval Percent_CPU_Load = 100 - pctIdle

| stats avg(Percent_CPU_Load) as avgCpuPct max(Percent_CPU_Load) as peakCpuPct by host

Now is there any way that I can get the same result without doing join??

Tags (1)
0 Karma

cramasta
Builder

How does this work?

index=os AND ( source=cpu OR source=vmstat) | multikv fields memUsedPct memTotalMB memFreeMB pctIdle | eval Percent_CPU_Load = 100 - pctIdle | stats avg(memUsedPct) as avgMemPct max(memUsedPct) as peakMemPct avg(memUsedMB) as avgMemMb max(memUsedMB) as peakMemMb avg(Percent_CPU_Load) as avgCpuPct max(Percent_CPU_Load) as peakCpuPct by host

0 Karma
Get Updates on the Splunk Community!

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 ...

Combine Multiline Logs into a Single Event with SOCK: a Step-by-Step Guide for ...

Combine multiline logs into a single event with SOCK - a step-by-step guide for newbies Olga Malita The ...