I’m a beginner with Grafana and am really enjoying it but I have been struggling with the documentation on this. I have a switch with 24 ports and I created a panel to monitor data in/out for each port. I have done a few of them now but I’m finding that copying and editing each is time consuming. I would like to:
Duplicate this panel for each interface without having to create each port manually (retaining all of the settings from the original). This creates variables in the ‘items’ and with the overrides.
Once complete, I would like to duplicate the dashboard for other switches without having to edit all of the settings (Host name for each query, names in overrides).
For other newbies with the same questions, using an alias for each query (under function click ‘+’ and then type ‘setAlias’ and give it a name) removes the variable in the overrides. In overrides, you just use the alias name instead of the specific item name. This way you can make multiple dashboards off of one template without the need for changing the name for each duplicate panel and each duplicate dashboard.
For creating the variables, in the dashboard click the gear icon, then variables on the left. There is ample documentation on this, it’s just a matter of searching ‘Grafana template’ on this site or using a search engine. It looks like the term ‘template’ has been depreciated in 9 but that’s the key to finding a vast array of answers and how-to’s.