Hello:
I have a problem with my dashboard. The problem is that every time I refresh the page with the dashboard, searches are executed. I would like the dashboard to refresh only every x hours (configurable) like it works for the reports (job).
Splunk version: Splunk Enterprise.
thank you
The only way you could achieve this (well it's kind of workaround, the dashboard will always re-run if you refresh the browser window) is to have all dashboard panel load from result of scheduled search using loadjob command ( see here for more info). You run all those scheduled searches which are loading your dashboard to run every X hours (configurable). The dashboard will just load the already executed result using loadjob, so technically it'll re-run but not the search just the loading of result.
If your intent is to only get data in 6hr interval, you could create a saved report for each panel, schedule those reports to run every 6hrs and use the reports results in each panel in the dashboard. That way, even if the dashboard is refreshed, it will retrieve the results of the last run report.
https://docs.splunk.com/Documentation/Splunk/6.4.3/SearchTutorial/Aboutsavingandsharingreports
The only way you could achieve this (well it's kind of workaround, the dashboard will always re-run if you refresh the browser window) is to have all dashboard panel load from result of scheduled search using loadjob command ( see here for more info). You run all those scheduled searches which are loading your dashboard to run every X hours (configurable). The dashboard will just load the already executed result using loadjob, so technically it'll re-run but not the search just the loading of result.
If you wish to refresh the entire dashboard page automatically you can add the refresh
attribute. When the dashboard is refreshed, all searches within the dashboard will be reran. Alternatively, the refresh
attribute can be added to individual panels to refresh only that panel. The following example will refresh the entire dashboard every hour, the interval being in seconds.
<form refresh="3600">
just curious, may i know, why you would want to refresh the page, if you want the dashboard query should not run
just want to share the dashboard with the users and I want it to update every two days (the queries take much for time runs)
Hi @TISKAR - If one of the answers below has helped answer your question, please don't forget to resolve this post by clicking on "Accept" below the best answer. Thank you!
The answer provided by somesoni2 should accomplish what you're looking for. If the dashboards are left open, then you can also add the refresh
attribute to update the values from the scheduled searches so the dashboard will not need to be manually refreshed.