Splunk Search

How to write a search to return events for a particular source IP for the last 7 days?

syed_star357
New Member

Hi,

How do I write a search to get particular source IP activities for the last 7 days?

Ex :src="122.15.158.173"

Regards,
Syed

0 Karma
1 Solution

sundareshr
Legend

Try this if src field has already been extracted.

index=yourindex sourcetype=yoursourcetype src=122.15.158.173 earliest=-7d@d | table _time src _raw

If src field has not been extracted, you will need to extract that first. If you share some data, someone here can help.

View solution in original post

0 Karma

sundareshr
Legend

Try this if src field has already been extracted.

index=yourindex sourcetype=yoursourcetype src=122.15.158.173 earliest=-7d@d | table _time src _raw

If src field has not been extracted, you will need to extract that first. If you share some data, someone here can help.

0 Karma

syed_star357
New Member

Thanks, the logs for the particular Source ip contains more than one Index and Sourcetypes and also data is containing huge, which is taking much time to get the answer.
is there any query, where can get the data in few mins, which can help us to analys the issue.

0 Karma
Get Updates on the Splunk Community!

Splunk + ThousandEyes: Correlate frontend, app, and network data to troubleshoot ...

 Are you tired of troubleshooting delays caused by siloed frontend, application, and network data? We've got a ...

Splunk Observability for AI

Don’t miss out on an exciting Tech Talk on Splunk Observability for AI!Discover how Splunk’s agentic AI ...

🔐 Trust at Every Hop: How mTLS in Splunk Enterprise 10.0 Makes Security Simpler

From Idea to Implementation: Why Splunk Built mTLS into Splunk Enterprise 10.0  mTLS wasn’t just a checkbox ...