Splunk Search

What is the best way to extract URL information from logs?

z782568
New Member

What would be the fastest way to grab the URLs out of logs in Splunk? I am thinking a regex expression would work, but how would I format that? Some of the logs are Sourcefire, some are not. Any ideas?

0 Karma

thomrs
Communicator

Something link this:

rex field=_raw "(?https?:\/\/[\da-z.-]+.[a-z.]{2,6}[\/\w .-]*)"

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