Splunk Search

How would you search for an alphanumeric string where the first part is fixed and the end number varies in length?

Akita881
New Member

I would appreciate help in a search for the following:
The first part of the string is always /device/status/ while the end number varies in length.

Examples (the end numbers are random and can be 6-12 digits in length):

  /device/status/5483367
  /device/status/847532148
  /device/status/687459632587
0 Karma

Akita881
New Member

I appreciate your time to reply. My apologies. I did not fully explain my question. The examples should have included what I want to exclude.
The numbers are all random and there is not a pool of them i can reference. I want to search for just the entries that are followed by numbers and not by letters.
Examples:
/device/status/5483367
/device/status/randomletters
/device/status/847532148
/device/status/687459632587
/device/status/morerandomletters

0 Karma

jensonthottian
Contributor

do you want to search for events which have a number at the end?

0 Karma

jensonthottian
Contributor

"your base search query" "/device/status/*"

Use wildcard "*".

somesoni2
Revered Legend

If this string is part of a field, like source, then try this

your base search ...source="/device/status/5483367*" |..rest of the search

If it's a search string in raw data but not extracted yet, simply do this

your base search "/device/status/5483367*" |..rest of the search
0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...