Getting Data In

Extract timestamp from the date-time of the log file

laristote
Explorer

Hi,
I have some log files with no timestamp neither in the indexed data nor in the path or filename.
I don't want to use the current time.

Is there a way to use the date and time of the file as the timestamp?

Thanks

Tags (1)
0 Karma
1 Solution

tom_frotscher
Builder

As you can see here: link

Splunk prefers the Files modification time (5.) over the current timestamp (6.). So this should happen automatically, if splunk can not find an other timestamp from (1.) to (4.).

Greetings

Tom

View solution in original post

0 Karma

tom_frotscher
Builder

As you can see here: link

Splunk prefers the Files modification time (5.) over the current timestamp (6.). So this should happen automatically, if splunk can not find an other timestamp from (1.) to (4.).

Greetings

Tom

0 Karma

laristote
Explorer

You're right, it's working.
Strangely, it is not working in the data preview from Add Data / upload while it's working in Add Data / monitor.

0 Karma
Get Updates on the Splunk Community!

Detecting Remote Code Executions With the Splunk Threat Research Team

REGISTER NOWRemote code execution (RCE) vulnerabilities pose a significant risk to organizations. If ...

Observability | Use Synthetic Monitoring for Website Metadata Verification

If you are on Splunk Observability Cloud, you may already have Synthetic Monitoringin your observability ...

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...