Splunk Search

How do I create a query to look at multiple sources which have very similar names but with different numbers at the end?

Jennifer
Path Finder

Hi, all!

Here are the sources that I want to contain at my search:

/appvol/wlp/DIVR01HK-AS01/applogs/appl.log

/appvol/wlp/DIVR01HK-AS01/applogs/appl.log.1

-  /appvol/wlp/DIVR01HK-AS01/applogs/appl.log.2

...

- /appvol/wlp/DIVR01HK-AS01/applogs/appl.log.50

How I could summarize those sources in a simple way in my Search command?

 

Labels (1)
0 Karma
1 Solution

gcusello
SplunkTrust
SplunkTrust

Hi @Jennifer,

what do you mean with summarize?

if you want to filter logs with this sources, you can use:

index=your_index source="/appvol/wlp/DIVR01HK-AS01/applogs/appl.log*"
| ...

if you want to count the number of events for each source, you could run something like this:

index=your_index source="/appvol/wlp/DIVR01HK-AS01/applogs/appl.log*"
| stats count BY source

Ciao.

Giuseppe

View solution in original post

gcusello
SplunkTrust
SplunkTrust

Hi @Jennifer,

what do you mean with summarize?

if you want to filter logs with this sources, you can use:

index=your_index source="/appvol/wlp/DIVR01HK-AS01/applogs/appl.log*"
| ...

if you want to count the number of events for each source, you could run something like this:

index=your_index source="/appvol/wlp/DIVR01HK-AS01/applogs/appl.log*"
| stats count BY source

Ciao.

Giuseppe

ITWhisperer
SplunkTrust
SplunkTrust

Try something like this

index=... source=/appvol/wlp/DIVR01HK-AS01/applogs/appl.log*
Get Updates on the Splunk Community!

Data Management Digest – December 2025

Welcome to the December edition of Data Management Digest! As we continue our journey of data innovation, the ...

Index This | What is broken 80% of the time by February?

December 2025 Edition   Hayyy Splunk Education Enthusiasts and the Eternally Curious!    We’re back with this ...

Unlock Faster Time-to-Value on Edge and Ingest Processor with New SPL2 Pipeline ...

Hello Splunk Community,   We're thrilled to share an exciting update that will help you manage your data more ...