Installation

How to automate deletion of log data from Splunk Indexer based on time of indexing

sdhiren
Explorer

We are currently indexing big log files (~1 GB in size) in our Splunk indexer using Splunk Universal Forwarder.

All the logs data will be stored in a single index.

We want to make sure the logs data is deleted after one week from the date it was indexed. 

Is there a way to achieve the same?

Labels (1)
0 Karma

richgalloway
SplunkTrust
SplunkTrust

Use the frozenTimePeriodInSecs setting in indexes.conf to control how long data lives in the index.

[myindex]
frozenTimePeriodInSecs = 604800

 

---
If this reply helps you, Karma would be appreciated.
0 Karma
Get Updates on the Splunk Community!

Index This | I’m short for "configuration file.” What am I?

May 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with a Special ...

New Articles from Academic Learning Partners, Help Expand Lantern’s Use Case Library, ...

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Your Guide to SPL2 at .conf24!

So, you’re headed to .conf24? You’re in for a good time. Las Vegas weather is just *chef’s kiss* beautiful in ...