Dashboards & Visualizations

Auto refresh All panel on the dashboard

tgulgund
Explorer

I am using splunk 9.3.2. I have visualisation panels added my dashboard with multiple queries.

I use a base search with global time picker default value to 48 hours and subsequently use the chain searches.

I need my entire dashboard to refresh after every 5 mins. I tried "refresh":300 but it doesn't work. Not sure what am I missing here.

{
"visualizations": {
},
"dataSources": {
},
"defaults": {
},
"inputs": {
},
"layout": {
"type": "absolute",
"options": {
"height": 2500,
"backgroundColor": "#000000",
"display": "fit-to-width",
"width": 1550
},
},
"description": "",
"title": "My Dashboard",
"refresh": 300
}


Labels (1)
0 Karma
1 Solution

livehybrid
Super Champion

Hi @tgulgund @Prewin27 

You can set a default refresh time which will apply automatically to all data sources (unless a specific datasource is overwritten, edit the source of your dashboard and find the "defaults" section, under defaults->dataSources->ds.search->options create a new "refresh" key with a value containing your intended refresh interval, such as this:

{
    "title": "testing",
    "description": "",
    "inputs": {},
    "defaults": {
        "dataSources": {
            "ds.search": {
                "options": {
                    "queryParameters": {
                        "earliest": "-24h@h",
                        "latest": "now"
                    },
                    "refresh": "60s"
                }
            }
        }
    },
    "visualizations": {
...
...
    }
}

livehybrid_1-1749463888897.png

🌟 Did this answer help you? If so, please consider:

  • Adding karma to show it was useful
  • Marking it as the solution if it resolved your issue
  • Commenting if you need any clarification

Your feedback encourages the volunteers in this community to continue contributing

View solution in original post

0 Karma

tgulgund
Explorer

I added "refresh": "5m", "refreshType": "delay" to my base search and it works for all the chain searches

0 Karma

tgulgund
Explorer

I have a base search and multiple chain search. can u add refresh only to base search ? 

Will that refresh other panels ?

0 Karma

livehybrid
Super Champion

Hi @tgulgund @Prewin27 

You can set a default refresh time which will apply automatically to all data sources (unless a specific datasource is overwritten, edit the source of your dashboard and find the "defaults" section, under defaults->dataSources->ds.search->options create a new "refresh" key with a value containing your intended refresh interval, such as this:

{
    "title": "testing",
    "description": "",
    "inputs": {},
    "defaults": {
        "dataSources": {
            "ds.search": {
                "options": {
                    "queryParameters": {
                        "earliest": "-24h@h",
                        "latest": "now"
                    },
                    "refresh": "60s"
                }
            }
        }
    },
    "visualizations": {
...
...
    }
}

livehybrid_1-1749463888897.png

🌟 Did this answer help you? If so, please consider:

  • Adding karma to show it was useful
  • Marking it as the solution if it resolved your issue
  • Commenting if you need any clarification

Your feedback encourages the volunteers in this community to continue contributing

0 Karma

Prewin27
Communicator

@tgulgund 

Unfortunately i dont think dashboard studio can set auto refresh for entire dashboard in a single config, auto-refresh is set per data source. You must define the refresh interval for each relevant data source in the dataSources section of your dashboard JSON


Eg:
"dataSources": {
"myDataSource": {
"type": "ds.search",
"options": {
"query": "your search here",
"queryParameters": {
"earliest": "-48h@h",
"latest": "@h"
},
"refresh": "5m",
"refreshType": "delay"
}
}
}

#https://docs.splunk.com/Documentation/Splunk/9.4.2/DashStudio/dsOpt

Regards,
Prewin
Splunk Enthusiast | Always happy to help! If this answer helped you, please consider marking it as the solution or giving a kudos/Karma. Thanks!

livehybrid
Super Champion

Hi @tgulgund 

For the benefit of others who find this answer, this is slightly incorrect. It *is* possible for a single setting for all your datasources, If you want to refresh all datasources on a dashboard studio dashboard then update the defaults as per my previous message.


@livehybrid wrote:

Hi @tgulgund @Prewin27 

You can set a default refresh time which will apply automatically to all data sources (unless a specific datasource is overwritten, edit the source of your dashboard and find the "defaults" section, under defaults->dataSources->ds.search->options create a new "refresh" key with a value containing your intended refresh interval, such as this:

{
    "title": "testing",
    "description": "",
    "inputs": {},
    "defaults": {
        "dataSources": {
            "ds.search": {
                "options": {
                    "queryParameters": {
                        "earliest": "-24h@h",
                        "latest": "now"
                    },
                    "refresh": "60s"
                }
            }
        }
    },
    "visualizations": {
...
...
    }
}

livehybrid_1-1749463888897.png

🌟 Did this answer help you? If so, please consider:

  • Adding karma to show it was useful
  • Marking it as the solution if it resolved your issue
  • Commenting if you need any clarification

Your feedback encourages the volunteers in this community to continue contributing


 

0 Karma
Get Updates on the Splunk Community!

Dashboards: Hiding charts while search is being executed and other uses for tokens

There are a couple of features of SimpleXML / Classic dashboards that can be used to enhance the user ...

Splunk Observability Cloud's AI Assistant in Action Series: Explaining Metrics and ...

This is the fourth post in the Splunk Observability Cloud’s AI Assistant in Action series that digs into how ...

Brains, Bytes, and Boston: Learn from the Best at .conf25

When you think of Boston, you might picture colonial charm, world-class universities, or even the crack of a ...