Getting Data In

Sourcetype not forwarding for 10 minutes

asarolkar
Builder

This is my stab at it:

| metadata type=hosts sourcetype="example" |  convert ctime(recentTime) as Recent_Time | where lastTime LESSTHANSYMBOL (now() - 600)

I am using this query - (now() - 600) translates to look between now and 10 minutes(600 seconds) before of now.

Does look ok ?

0 Karma

Lamar
Splunk Employee
Splunk Employee

This is probably closer to what you'll want:

| metadata type=sourcetypes | eval search_time=(now()-600) | eval status=if(lastTime<search_time, "NOT_OK", "OK") | table sourcetype, status

asarolkar
Builder

Fantastic ! This gives me across all sourcetypes

0 Karma

Lamar
Splunk Employee
Splunk Employee

You could easily translate this to a by 'host' search as well. Just change the word 'sourcetype' to 'host'.

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...