diff --git a/cmd/collectors/commonutils.go b/cmd/collectors/commonutils.go
index a9330f30b..59600aee9 100644
--- a/cmd/collectors/commonutils.go
+++ b/cmd/collectors/commonutils.go
@@ -11,6 +11,7 @@ import (
"github.com/netapp/harvest/v2/third_party/tidwall/gjson"
"log/slog"
"os"
+ "regexp"
"sort"
"strconv"
"strings"
@@ -543,3 +544,84 @@ func PopulateIfgroupMetrics(portIfgroupMap map[string]string, portDataMap map[st
}
return nil
}
+
+func HandleDuration(value string) float64 {
+ // Example: duration: PT8H35M42S
+ timeDurationRegex := `^P(?:(\d+)Y)?(?:(\d+)M)?(?:(\d+)D)?T(?:(\d+)H)?(?:(\d+)M)?(?:(\d+(?:.\d+)?)S)?$`
+
+ regexTimeDuration := regexp.MustCompile(timeDurationRegex)
+ if match := regexTimeDuration.MatchString(value); match {
+ // example: PT8H35M42S ==> 30942
+ matches := regexTimeDuration.FindStringSubmatch(value)
+ if matches == nil {
+ return 0
+ }
+
+ seconds := 0.0
+
+ // years
+ // months
+
+ // days
+ if matches[3] != "" {
+ f, err := strconv.ParseFloat(matches[3], 64)
+ if err != nil {
+ fmt.Printf("%v", err)
+ return 0
+ }
+ seconds += f * 24 * 60 * 60
+ }
+
+ // hours
+ if matches[4] != "" {
+ f, err := strconv.ParseFloat(matches[4], 64)
+ if err != nil {
+ fmt.Printf("%v", err)
+ return 0
+ }
+ seconds += f * 60 * 60
+ }
+
+ // minutes
+ if matches[5] != "" {
+ f, err := strconv.ParseFloat(matches[5], 64)
+ if err != nil {
+ fmt.Printf("%v", err)
+ return 0
+ }
+ seconds += f * 60
+ }
+
+ // seconds & milliseconds
+ if matches[6] != "" {
+ f, err := strconv.ParseFloat(matches[6], 64)
+ if err != nil {
+ fmt.Printf("%v", err)
+ return 0
+ }
+ seconds += f
+ }
+ return seconds
+ }
+
+ return 0
+}
+
+// Example: timestamp: 2020-12-02T18:36:19-08:00
+var regexTimeStamp = regexp.MustCompile(
+ `[+-]?\d{4}(-[01]\d(-[0-3]\d(T[0-2]\d:[0-5]\d:?([0-5]\d(\.\d+)?)?[+-][0-2]\d:[0-5]\d?)?)?)?`)
+
+func HandleTimestamp(value string) float64 {
+ var timestamp time.Time
+ var err error
+
+ if match := regexTimeStamp.MatchString(value); match {
+ // example: 2020-12-02T18:36:19-08:00 ==> 1606962979
+ if timestamp, err = time.Parse(time.RFC3339, value); err != nil {
+ fmt.Printf("%v", err)
+ return 0
+ }
+ return float64(timestamp.Unix())
+ }
+ return 0
+}
diff --git a/cmd/collectors/commonutils_test.go b/cmd/collectors/commonutils_test.go
index 3319dd98f..b81903520 100644
--- a/cmd/collectors/commonutils_test.go
+++ b/cmd/collectors/commonutils_test.go
@@ -411,3 +411,65 @@ func Test_SplitVscanName(t *testing.T) {
})
}
}
+
+func Test_HandleDuration(t *testing.T) {
+
+ type test struct {
+ timeFieldValue string
+ want float64
+ }
+
+ var tests = []test{
+ {
+ timeFieldValue: "PT54S",
+ want: 54,
+ },
+ {
+ timeFieldValue: "PT48M",
+ want: 2880,
+ },
+ {
+ timeFieldValue: "P428DT22H45M19S",
+ want: 37061119,
+ },
+ {
+ timeFieldValue: "PT8H35M42S",
+ want: 30942,
+ },
+ }
+
+ for _, tt := range tests {
+ t.Run(tt.timeFieldValue, func(t *testing.T) {
+ if got := HandleDuration(tt.timeFieldValue); got != tt.want {
+ t.Errorf("actual value = %v, want %v", got, tt.want)
+ }
+ })
+ }
+}
+
+func Test_HandleTimestamp(t *testing.T) {
+
+ type test struct {
+ timeFieldValue string
+ want float64
+ }
+
+ var tests = []test{
+ {
+ timeFieldValue: "2020-12-02T18:36:19-08:00",
+ want: 1606962979,
+ },
+ {
+ timeFieldValue: "2022-01-31T04:05:02-05:00",
+ want: 1643619902,
+ },
+ }
+
+ for _, tt := range tests {
+ t.Run(tt.timeFieldValue, func(t *testing.T) {
+ if got := HandleTimestamp(tt.timeFieldValue); got != tt.want {
+ t.Errorf("actual value = %v, want %v", got, tt.want)
+ }
+ })
+ }
+}
diff --git a/cmd/collectors/rest/plugins/clusterschedule/clusterschedule.go b/cmd/collectors/rest/plugins/clusterschedule/clusterschedule.go
new file mode 100644
index 000000000..a8badaf4c
--- /dev/null
+++ b/cmd/collectors/rest/plugins/clusterschedule/clusterschedule.go
@@ -0,0 +1,53 @@
+package clusterschedule
+
+import (
+ "github.com/netapp/harvest/v2/cmd/poller/plugin"
+ "github.com/netapp/harvest/v2/pkg/matrix"
+ "github.com/netapp/harvest/v2/pkg/util"
+ "github.com/netapp/harvest/v2/third_party/tidwall/gjson"
+ "strings"
+)
+
+type ClusterScheule struct {
+ *plugin.AbstractPlugin
+}
+
+func New(p *plugin.AbstractPlugin) plugin.Plugin {
+ return &ClusterScheule{AbstractPlugin: p}
+}
+
+func (c *ClusterScheule) Run(dataMap map[string]*matrix.Matrix) ([]*matrix.Matrix, *util.Metadata, error) {
+ for _, instance := range dataMap[c.Object].GetInstances() {
+ if cron := instance.GetLabel("cron"); cron != "" {
+ updateDetailsJSON := gjson.Result{Type: gjson.JSON, Raw: cron}
+ var minStr, hourStr, dayStr, monthStr, weekDayStr string
+ var cronVal []string
+
+ minStr = list(updateDetailsJSON.Get("minutes"))
+ hourStr = list(updateDetailsJSON.Get("hours"))
+ dayStr = list(updateDetailsJSON.Get("days"))
+ monthStr = list(updateDetailsJSON.Get("months"))
+ weekDayStr = list(updateDetailsJSON.Get("weekdays"))
+ cronVal = append(cronVal, minStr, hourStr, dayStr, monthStr, weekDayStr)
+ cronData := strings.Join(cronVal, " ")
+ instance.SetLabel("cron", cronData)
+ instance.SetLabel("schedule", cronData)
+ }
+ if interval := instance.GetLabel("interval"); interval != "" {
+ instance.SetLabel("schedule", interval)
+ }
+ }
+ return nil, nil, nil
+}
+
+func list(get gjson.Result) string {
+ if !get.IsArray() {
+ return "*"
+ }
+ array := get.Array()
+ items := make([]string, 0, len(array))
+ for _, e := range array {
+ items = append(items, e.ClonedString())
+ }
+ return strings.Join(items, ",")
+}
diff --git a/cmd/collectors/rest/plugins/snapshotpolicy/snapshotpolicy.go b/cmd/collectors/rest/plugins/snapshotpolicy/snapshotpolicy.go
new file mode 100644
index 000000000..d44f83a0b
--- /dev/null
+++ b/cmd/collectors/rest/plugins/snapshotpolicy/snapshotpolicy.go
@@ -0,0 +1,49 @@
+/*
+ * Copyright NetApp Inc, 2024 All rights reserved
+ */
+
+package snapshotpolicy
+
+import (
+ "github.com/netapp/harvest/v2/cmd/poller/plugin"
+ "github.com/netapp/harvest/v2/pkg/matrix"
+ "github.com/netapp/harvest/v2/pkg/util"
+ "github.com/netapp/harvest/v2/third_party/tidwall/gjson"
+ "slices"
+ "strconv"
+ "strings"
+)
+
+type SnapshotPolicy struct {
+ *plugin.AbstractPlugin
+}
+
+func New(p *plugin.AbstractPlugin) plugin.Plugin {
+ return &SnapshotPolicy{AbstractPlugin: p}
+}
+
+func (m *SnapshotPolicy) Run(dataMap map[string]*matrix.Matrix) ([]*matrix.Matrix, *util.Metadata, error) {
+ // Purge and reset data
+ data := dataMap[m.Object]
+
+ for _, instance := range data.GetInstances() {
+ copies := instance.GetLabel("copies")
+ copiesJSON := gjson.Result{Type: gjson.JSON, Raw: "[" + copies + "]"}
+ var copiesValue int
+ var schedules []string
+ for _, copiesData := range copiesJSON.Array() {
+ count := copiesData.Get("count").ClonedString()
+ countVal, _ := strconv.Atoi(count)
+ schedule := copiesData.Get("schedule.name").ClonedString()
+ schedules = append(schedules, schedule+":"+count)
+ copiesValue += countVal
+ }
+
+ slices.Sort(schedules)
+
+ instance.SetLabel("schedules", strings.Join(schedules, ","))
+ instance.SetLabel("copies", strconv.Itoa(copiesValue))
+ }
+
+ return nil, nil, nil
+}
diff --git a/cmd/collectors/rest/rest.go b/cmd/collectors/rest/rest.go
index 06a8c0e8a..5e522569a 100644
--- a/cmd/collectors/rest/rest.go
+++ b/cmd/collectors/rest/rest.go
@@ -7,6 +7,7 @@ import (
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/aggregate"
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/certificate"
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/cluster"
+ "github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/clusterschedule"
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/clustersoftware"
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/disk"
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/health"
@@ -19,6 +20,7 @@ import (
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/securityaccount"
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/shelf"
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/snapmirror"
+ "github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/snapshotpolicy"
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/svm"
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/systemnode"
"github.com/netapp/harvest/v2/cmd/collectors/rest/plugins/volume"
@@ -472,6 +474,8 @@ func (r *Rest) LoadPlugin(kind string, abc *plugin.AbstractPlugin) plugin.Plugin
return aggregate.New(abc)
case "Cluster":
return cluster.New(abc)
+ case "ClusterSchedule":
+ return clusterschedule.New(abc)
case "ClusterSoftware":
return clustersoftware.New(abc)
case "Disk":
@@ -496,6 +500,8 @@ func (r *Rest) LoadPlugin(kind string, abc *plugin.AbstractPlugin) plugin.Plugin
return collectors.NewSensor(abc)
case "Shelf":
return shelf.New(abc)
+ case "SnapshotPolicy":
+ return snapshotpolicy.New(abc)
case "SecurityAccount":
return securityaccount.New(abc)
case "QosPolicyFixed":
@@ -628,9 +634,9 @@ func (r *Rest) HandleResults(mat *matrix.Matrix, result []gjson.Result, prop *pr
var floatValue float64
switch metric.MetricType {
case "duration":
- floatValue = HandleDuration(f.ClonedString())
+ floatValue = collectors.HandleDuration(f.ClonedString())
case "timestamp":
- floatValue = HandleTimestamp(f.ClonedString())
+ floatValue = collectors.HandleTimestamp(f.ClonedString())
case "":
floatValue = f.Float()
default:
diff --git a/cmd/collectors/rest/templating.go b/cmd/collectors/rest/templating.go
index 0e29bc9c8..ca803385e 100644
--- a/cmd/collectors/rest/templating.go
+++ b/cmd/collectors/rest/templating.go
@@ -1,18 +1,15 @@
package rest
import (
- "fmt"
"github.com/netapp/harvest/v2/cmd/collectors"
"github.com/netapp/harvest/v2/pkg/errs"
"github.com/netapp/harvest/v2/pkg/tree/node"
"github.com/netapp/harvest/v2/pkg/util"
"log/slog"
"maps"
- "regexp"
"slices"
"strconv"
"strings"
- "time"
)
func (r *Rest) LoadTemplate() (string, error) {
@@ -94,87 +91,6 @@ func (r *Rest) InitCache() error {
return nil
}
-func HandleDuration(value string) float64 {
- // Example: duration: PT8H35M42S
- timeDurationRegex := `^P(?:(\d+)Y)?(?:(\d+)M)?(?:(\d+)D)?T(?:(\d+)H)?(?:(\d+)M)?(?:(\d+(?:.\d+)?)S)?$`
-
- regexTimeDuration := regexp.MustCompile(timeDurationRegex)
- if match := regexTimeDuration.MatchString(value); match {
- // example: PT8H35M42S ==> 30942
- matches := regexTimeDuration.FindStringSubmatch(value)
- if matches == nil {
- return 0
- }
-
- seconds := 0.0
-
- // years
- // months
-
- // days
- if matches[3] != "" {
- f, err := strconv.ParseFloat(matches[3], 64)
- if err != nil {
- fmt.Printf("%v", err)
- return 0
- }
- seconds += f * 24 * 60 * 60
- }
-
- // hours
- if matches[4] != "" {
- f, err := strconv.ParseFloat(matches[4], 64)
- if err != nil {
- fmt.Printf("%v", err)
- return 0
- }
- seconds += f * 60 * 60
- }
-
- // minutes
- if matches[5] != "" {
- f, err := strconv.ParseFloat(matches[5], 64)
- if err != nil {
- fmt.Printf("%v", err)
- return 0
- }
- seconds += f * 60
- }
-
- // seconds & milliseconds
- if matches[6] != "" {
- f, err := strconv.ParseFloat(matches[6], 64)
- if err != nil {
- fmt.Printf("%v", err)
- return 0
- }
- seconds += f
- }
- return seconds
- }
-
- return 0
-}
-
-// Example: timestamp: 2020-12-02T18:36:19-08:00
-var regexTimeStamp = regexp.MustCompile(
- `[+-]?\d{4}(-[01]\d(-[0-3]\d(T[0-2]\d:[0-5]\d:?([0-5]\d(\.\d+)?)?[+-][0-2]\d:[0-5]\d?)?)?)?`)
-
-func HandleTimestamp(value string) float64 {
- var timestamp time.Time
- var err error
-
- if match := regexTimeStamp.MatchString(value); match {
- // example: 2020-12-02T18:36:19-08:00 ==> 1606962979
- if timestamp, err = time.Parse(time.RFC3339, value); err != nil {
- fmt.Printf("%v", err)
- return 0
- }
- return float64(timestamp.Unix())
- }
- return 0
-}
-
func (r *Rest) ParseRestCounters(counter *node.Node, prop *prop) {
var (
display, name, kind, metricType string
diff --git a/cmd/collectors/rest/templating_test.go b/cmd/collectors/rest/templating_test.go
deleted file mode 100644
index 7fd78df45..000000000
--- a/cmd/collectors/rest/templating_test.go
+++ /dev/null
@@ -1,67 +0,0 @@
-package rest
-
-import (
- "testing"
-)
-
-func Test_HandleDuration(t *testing.T) {
-
- type test struct {
- timeFieldValue string
- want float64
- }
-
- var tests = []test{
- {
- timeFieldValue: "PT54S",
- want: 54,
- },
- {
- timeFieldValue: "PT48M",
- want: 2880,
- },
- {
- timeFieldValue: "P428DT22H45M19S",
- want: 37061119,
- },
- {
- timeFieldValue: "PT8H35M42S",
- want: 30942,
- },
- }
-
- for _, tt := range tests {
- t.Run(tt.timeFieldValue, func(t *testing.T) {
- if got := HandleDuration(tt.timeFieldValue); got != tt.want {
- t.Errorf("actual value = %v, want %v", got, tt.want)
- }
- })
- }
-}
-
-func Test_HandleTimestamp(t *testing.T) {
-
- type test struct {
- timeFieldValue string
- want float64
- }
-
- var tests = []test{
- {
- timeFieldValue: "2020-12-02T18:36:19-08:00",
- want: 1606962979,
- },
- {
- timeFieldValue: "2022-01-31T04:05:02-05:00",
- want: 1643619902,
- },
- }
-
- for _, tt := range tests {
- t.Run(tt.timeFieldValue, func(t *testing.T) {
- if got := HandleTimestamp(tt.timeFieldValue); got != tt.want {
- t.Errorf("actual value = %v, want %v", got, tt.want)
- }
- })
- }
-}
diff --git a/cmd/collectors/zapi/collector/zapi.go b/cmd/collectors/zapi/collector/zapi.go
index 6d735fead..acc5461fa 100644
--- a/cmd/collectors/zapi/collector/zapi.go
+++ b/cmd/collectors/zapi/collector/zapi.go
@@ -15,6 +15,7 @@ import (
"github.com/netapp/harvest/v2/cmd/collectors/zapi/plugins/security"
"github.com/netapp/harvest/v2/cmd/collectors/zapi/plugins/shelf"
"github.com/netapp/harvest/v2/cmd/collectors/zapi/plugins/snapmirror"
+ "github.com/netapp/harvest/v2/cmd/collectors/zapi/plugins/snapshotpolicy"
"github.com/netapp/harvest/v2/cmd/collectors/zapi/plugins/svm"
"github.com/netapp/harvest/v2/cmd/collectors/zapi/plugins/systemnode"
"github.com/netapp/harvest/v2/cmd/collectors/zapi/plugins/volume"
@@ -148,6 +149,8 @@ func (z *Zapi) LoadPlugin(kind string, abc *plugin.AbstractPlugin) plugin.Plugin
switch kind {
case "Snapmirror":
return snapmirror.New(abc)
+ case "SnapshotPolicy":
+ return snapshotpolicy.New(abc)
case "Shelf":
return shelf.New(abc)
case "Qtree":
diff --git a/cmd/collectors/zapi/plugins/snapshotpolicy/snapshotpolicy.go b/cmd/collectors/zapi/plugins/snapshotpolicy/snapshotpolicy.go
new file mode 100644
index 000000000..c4981b484
--- /dev/null
+++ b/cmd/collectors/zapi/plugins/snapshotpolicy/snapshotpolicy.go
@@ -0,0 +1,51 @@
+/*
+ * Copyright NetApp Inc, 2024 All rights reserved
+ */
+
+package snapshotpolicy
+
+import (
+ "github.com/netapp/harvest/v2/cmd/poller/plugin"
+ "github.com/netapp/harvest/v2/pkg/matrix"
+ "github.com/netapp/harvest/v2/pkg/util"
+ "slices"
+ "strconv"
+ "strings"
+)
+
+type SnapshotPolicy struct {
+ *plugin.AbstractPlugin
+}
+
+func New(p *plugin.AbstractPlugin) plugin.Plugin {
+ return &SnapshotPolicy{AbstractPlugin: p}
+}
+
+func (m *SnapshotPolicy) Run(dataMap map[string]*matrix.Matrix) ([]*matrix.Matrix, *util.Metadata, error) {
+ // Purge and reset data
+ data := dataMap[m.Object]
+
+ for _, instance := range data.GetInstances() {
+ copies := strings.Split(instance.GetLabel("copies"), ",")
+ schedules := strings.Split(instance.GetLabel("schedules"), ",")
+ var schedulesS []string
+
+ var copiesValue int
+ if len(copies) > 1 {
+ for index, copiesData := range copies {
+ countVal, _ := strconv.Atoi(copiesData)
+ schedule := schedules[index]
+ schedulesS = append(schedulesS, schedule+":"+copiesData)
+
+ copiesValue += countVal
+ }
+
+ slices.Sort(schedulesS)
+
+ instance.SetLabel("schedules", strings.Join(schedulesS, ","))
+ instance.SetLabel("copies", strconv.Itoa(copiesValue))
+ }
+ }
+
+ return nil, nil, nil
+}
diff --git a/cmd/tools/generate/counter.yaml b/cmd/tools/generate/counter.yaml
index 7adc1adcf..6265bcd24 100644
--- a/cmd/tools/generate/counter.yaml
+++ b/cmd/tools/generate/counter.yaml
@@ -873,9 +873,6 @@ counters:
- Name: snapmirror_update_successful_count
Description: Number of Successful Updates
- - Name: snapshot_policy_total_schedules
- Description: Total Number of Schedules in this Policy
-
- Name: svm_nfs_read_throughput
APIs:
- API: REST
@@ -2061,3 +2058,15 @@ counters:
Endpoint: NA
ONTAPCounter: Harvest generated
Template: conf/rest/9.6.0/clustersoftware.yaml
+
+ - Name: shelf_module_status
+ Description: Displays the shelf module labels with their status.
+ APIs:
+ - API: REST
+ Endpoint: NA
+ ONTAPCounter: Harvest generated
+ Template: conf/restperf/9.12.0/disk.yaml
+ - API: ZAPI
+ Endpoint: NA
+ ONTAPCounter: Harvest generated
+ Template: conf/zapiperf/cdot/9.8.0/disk.yaml
\ No newline at end of file
diff --git a/conf/rest/9.12.0/snapshotpolicy.yaml b/conf/rest/9.12.0/snapshotpolicy.yaml
index 34d877be4..b9dc84574 100644
--- a/conf/rest/9.12.0/snapshotpolicy.yaml
+++ b/conf/rest/9.12.0/snapshotpolicy.yaml
@@ -1,15 +1,27 @@
name: SnapshotPolicy
-query: api/private/cli/volume/snapshot/policy
+query: api/storage/snapshot-policies
object: snapshot_policy
counters:
- - ^^policy => snapshot_policy
- - ^^vserver => svm
+ - ^^uuid => uuid
- ^comment => comment
- - total_schedules => total_schedules
+ - ^copies => copies
+ - ^enabled => enabled
+ - ^name => snapshot_policy
+ - ^scope => scope
+ - ^svm.name => svm
+plugins:
+ - SnapshotPolicy
+
export_options:
instance_keys:
- - comment
- snapshot_policy
- - svm
\ No newline at end of file
+ instance_labels:
+ - comment
+ - copies
+ - enabled
+ - schedules
+ - scope
+ - svm
+
diff --git a/conf/rest/9.6.0/clusterschedule.yaml b/conf/rest/9.6.0/clusterschedule.yaml
new file mode 100644
index 000000000..24e52d802
--- /dev/null
+++ b/conf/rest/9.6.0/clusterschedule.yaml
@@ -0,0 +1,27 @@
+name: ClusterSchedule
+query: api/cluster/schedules
+object: cluster_schedule
+
+counters:
+ - ^^uuid => uuid
+ - ^cron => cron
+ - ^interval(duration) => interval
+ - ^name => name
+ - ^scope => scope
+ - ^svm.name => svm
+ - ^type
+
+plugins:
+ - ClusterSchedule
+
+export_options:
+ instance_keys:
+ - name
+ - type
+ instance_labels:
+ - cron
+ - interval
+ - schedule
+ - scope
+ - svm
+
diff --git a/conf/rest/9.6.0/snapmirrorpolicy.yaml b/conf/rest/9.6.0/snapmirrorpolicy.yaml
new file mode 100644
index 000000000..1e90370bc
--- /dev/null
+++ b/conf/rest/9.6.0/snapmirrorpolicy.yaml
@@ -0,0 +1,25 @@
+name: SnapMirrorPolicy
+query: api/snapmirror/policies
+object: snapmirror_policy
+
+counters:
+ - ^^uuid => uuid
+ - ^comment => comment
+ - ^name => policy_name
+ - ^scope
+ - ^svm.name => svm
+ - ^transfer_schedule.name => schedule_name
+ - ^type
+
+
+export_options:
+ instance_keys:
+ - policy_name
+ - svm
+ instance_labels:
+ - comment
+ - policy_name
+ - schedule_name
+ - scope
+ - type
+
diff --git a/conf/rest/9.7.0/ontap_s3.yaml b/conf/rest/9.7.0/ontap_s3.yaml
index 4b44ad31a..588279c92 100644
--- a/conf/rest/9.7.0/ontap_s3.yaml
+++ b/conf/rest/9.7.0/ontap_s3.yaml
@@ -11,6 +11,7 @@ counters:
- ^protection_status.is_protected => is_protected
- ^qos_policy.name => qos_policy_group
- ^svm.name => svm
+ - ^type => type
- ^volume.name => volume
- logical_used_size
- size
@@ -38,4 +39,5 @@ export_options:
- protected_in_cloud
- protected_in_ontap
- qos_policy_group
+ - type
- url
diff --git a/conf/rest/default.yaml b/conf/rest/default.yaml
index 2fa210fd6..054f0f7f0 100644
--- a/conf/rest/default.yaml
+++ b/conf/rest/default.yaml
@@ -16,6 +16,7 @@ objects:
# CIFSShare: cifs_share.yaml
CloudTarget: cloud_target.yaml
ClusterPeer: clusterpeer.yaml
+ ClusterSchedule: clusterschedule.yaml
ClusterSoftware: clustersoftware.yaml
Disk: disk.yaml
EmsDestination: ems_destination.yaml
@@ -53,6 +54,7 @@ objects:
Sensor: sensor.yaml
Shelf: shelf.yaml
SnapMirror: snapmirror.yaml
+ SnapMirrorPolicy: snapmirrorpolicy.yaml
SnapshotPolicy: snapshotpolicy.yaml
Status: status.yaml
Subsystem: subsystem.yaml
diff --git a/conf/zapi/cdot/9.8.0/snapshotpolicy.yaml b/conf/zapi/cdot/9.8.0/snapshotpolicy.yaml
index 1c9d598bb..c9b4d445a 100644
--- a/conf/zapi/cdot/9.8.0/snapshotpolicy.yaml
+++ b/conf/zapi/cdot/9.8.0/snapshotpolicy.yaml
@@ -2,18 +2,33 @@ name: SnapshotPolicy
query: snapshot-policy-get-iter
object: snapshot_policy
-
counters:
snapshot-policy-info:
- - ^^policy => snapshot_policy
- - ^^vserver-name => svm
- - ^comment => comment
- - total-schedules => total_schedules
+ - ^^policy => snapshot_policy
+ - ^^vserver-name => svm
+ - ^comment => comment
+ - ^enabled => enabled
+ - ^policy-owner => policy_owner
+ - snapshot-policy-schedules:
+ - snapshot-schedule-info:
+ - ^count => copies
+ - ^schedule => schedules
+
+plugins:
+ - LabelAgent:
+ split:
+ - policy_owner `-admin` scope,
+ - SnapshotPolicy
export_options:
instance_keys:
- - comment
- snapshot_policy
+ instance_labels:
+ - comment
+ - copies
+ - enabled
+ - schedules
+ - scope
- svm
diff --git a/docs/ontap-metrics.md b/docs/ontap-metrics.md
index 311683e61..5592fd322 100644
--- a/docs/ontap-metrics.md
+++ b/docs/ontap-metrics.md
@@ -7,7 +7,7 @@ These can be generated on demand by running `bin/harvest grafana metrics`. See
- More information about ONTAP REST performance counters can be found [here](https://docs.netapp.com/us-en/ontap-pcmap-9121/index.html).
```
-Creation Date : 2024-Dec-02
+Creation Date : 2025-Jan-10
ONTAP Version: 9.16.1
```
## Understanding the structure
@@ -11023,6 +11023,16 @@ Minimum temperature of all non-ambient sensors for shelf in Celsius.
| ZAPI | `NA` | `Harvest generated`
Unit:
Type:
Base: | conf/zapiperf/cdot/9.8.0/disk.yaml |
+### shelf_module_status
+
+Displays the shelf module labels with their status.
+
+| API | Endpoint | Metric | Template |
+|--------|----------|--------|---------|
+| REST | `NA` | `Harvest generated`
Unit:
Type:
Base: | conf/restperf/9.12.0/disk.yaml |
+| ZAPI | `NA` | `Harvest generated`
Unit:
Type:
Base: | conf/zapiperf/cdot/9.8.0/disk.yaml |
+
+
### shelf_new_status
This metric indicates a value of 1 if the shelf state is online or ok (indicating the shelf is operational) and a value of 0 for any other state (indicating the shelf is not operational).
@@ -11503,16 +11513,6 @@ Number of Successful Updates
| ZAPI | `snapmirror-get-iter` | `snapmirror-info.update-successful-count` | conf/zapi/cdot/9.8.0/snapmirror.yaml |
-### snapshot_policy_total_schedules
-
-Total Number of Schedules in this Policy
-
-| API | Endpoint | Metric | Template |
-|--------|----------|--------|---------|
-| REST | `api/private/cli/volume/snapshot/policy` | `total_schedules` | conf/rest/9.12.0/snapshotpolicy.yaml |
-| ZAPI | `snapshot-policy-get-iter` | `snapshot-policy-info.total-schedules` | conf/zapi/cdot/9.8.0/snapshotpolicy.yaml |
-
-
### svm_cifs_connections
Number of connections
diff --git a/docs/prepare-cdot-clusters.md b/docs/prepare-cdot-clusters.md
index 918d1dd17..f17b4460c 100644
--- a/docs/prepare-cdot-clusters.md
+++ b/docs/prepare-cdot-clusters.md
@@ -197,6 +197,7 @@ security login rest-role create -role harvest2-rest-role -access readonly -api /
security login rest-role create -role harvest-rest-role -access readonly -api /api/security/login/messages
security login rest-role create -role harvest-rest-role -access readonly -api /api/security/ssh
security login rest-role create -role harvest-rest-role -access readonly -api /api/snapmirror/relationships
+ security login rest-role create -role harvest-rest-role -access readonly -api /api/snapmirror/policies
security login rest-role create -role harvest-rest-role -access readonly -api /api/storage/aggregates
security login rest-role create -role harvest-rest-role -access readonly -api /api/storage/disks
security login rest-role create -role harvest-rest-role -access readonly -api /api/storage/flexcache/flexcaches
@@ -207,6 +208,7 @@ security login rest-role create -role harvest2-rest-role -access readonly -api /
security login rest-role create -role harvest-rest-role -access readonly -api /api/storage/qos/workloads
security login rest-role create -role harvest-rest-role -access readonly -api /api/storage/quota/reports
security login rest-role create -role harvest-rest-role -access readonly -api /api/storage/shelves
+ security login rest-role create -role harvest-rest-role -access readonly -api /api/storage/snapshot-policies
security login rest-role create -role harvest-rest-role -access readonly -api /api/storage/volumes
security login rest-role create -role harvest-rest-role -access readonly -api /api/support/auto-update
security login rest-role create -role harvest-rest-role -access readonly -api /api/support/autosupport
@@ -235,7 +237,6 @@ security login rest-role create -role harvest2-rest-role -access readonly -api /
security login rest-role create -role harvest-rest-role -access readonly -api /api/private/cli/qos/workload
security login rest-role create -role harvest-rest-role -access readonly -api /api/private/cli/qtree
security login rest-role create -role harvest-rest-role -access readonly -api /api/private/cli/snapmirror
- security login rest-role create -role harvest-rest-role -access readonly -api /api/private/cli/volume/snapshot/policy
security login rest-role create -role harvest-rest-role -access readonly -api /api/private/cli/storage/failover
security login rest-role create -role harvest-rest-role -access readonly -api /api/private/cli/storage/shelf
security login rest-role create -role harvest-rest-role -access readonly -api /api/private/cli/system/chassis/fru
diff --git a/grafana/dashboards/cmode/data_protection.json b/grafana/dashboards/cmode/data_protection.json
new file mode 100644
index 000000000..13ccf1c85
--- /dev/null
+++ b/grafana/dashboards/cmode/data_protection.json
@@ -0,0 +1,3363 @@
+{
+ "__inputs": [
+ {
+ "description": "",
+ "label": "Prometheus",
+ "name": "DS_PROMETHEUS",
+ "pluginId": "prometheus",
+ "pluginName": "Prometheus",
+ "type": "datasource"
+ }
+ ],
+ "__requires": [
+ {
+ "id": "bargauge",
+ "name": "Bar gauge",
+ "type": "panel",
+ "version": ""
+ },
+ {
+ "id": "grafana",
+ "name": "Grafana",
+ "type": "grafana",
+ "version": "7.5.4"
+ },
+ {
+ "id": "graph",
+ "name": "Graph",
+ "type": "panel",
+ "version": ""
+ },
+ {
+ "id": "prometheus",
+ "name": "Prometheus",
+ "type": "datasource",
+ "version": "1.0.0"
+ },
+ {
+ "id": "stat",
+ "name": "Stat",
+ "type": "panel",
+ "version": ""
+ },
+ {
+ "id": "table",
+ "name": "Table",
+ "type": "panel",
+ "version": ""
+ }
+ ],
+ "annotations": {
+ "list": [
+ {
+ "builtIn": 1,
+ "datasource": "-- Grafana --",
+ "enable": true,
+ "hide": true,
+ "iconColor": "rgba(0, 211, 255, 1)",
+ "name": "Annotations & Alerts",
+ "target": {
+ "limit": 100,
+ "matchAny": false,
+ "tags": [],
+ "type": "dashboard"
+ },
+ "type": "dashboard"
+ }
+ ]
+ },
+ "description": "",
+ "editable": true,
+ "gnetId": null,
+ "graphTooltip": 1,
+ "id": null,
+ "iteration": 1637051731590,
+ "links": [
+ {
+ "asDropdown": true,
+ "icon": "external link",
+ "includeVars": true,
+ "keepTime": true,
+ "tags": [
+ "cdot"
+ ],
+ "targetBlank": false,
+ "title": "Related Dashboards",
+ "tooltip": "",
+ "type": "dashboards",
+ "url": ""
+ }
+ ],
+ "panels": [
+ {
+ "collapsed": false,
+ "datasource": "${DS_PROMETHEUS}",
+ "gridPos": {
+ "h": 1,
+ "w": 24,
+ "x": 0,
+ "y": 0
+ },
+ "id": 15,
+ "panels": [],
+ "title": "Highlights",
+ "type": "row"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "This panel displays volume protection by Snapshot copies.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ }
+ },
+ "decimals": 0,
+ "mappings": [],
+ "unit": "locale"
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Not Protected"
+ },
+ "properties": [
+ {
+ "id": "color",
+ "value": {
+ "fixedColor": "semi-dark-yellow",
+ "mode": "fixed"
+ }
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Protected"
+ },
+ "properties": [
+ {
+ "id": "color",
+ "value": {
+ "fixedColor": "semi-dark-green",
+ "mode": "fixed"
+ }
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 10,
+ "w": 8,
+ "x": 0,
+ "y": 1
+ },
+ "id": 155,
+ "options": {
+ "displayLabels": [
+ "value",
+ "percent"
+ ],
+ "legend": {
+ "displayMode": "table",
+ "placement": "bottom",
+ "values": [
+ "value"
+ ]
+ },
+ "pieType": "donut",
+ "reduceOptions": {
+ "calcs": [
+ "last"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "tooltip": {
+ "mode": "single"
+ }
+ },
+ "pluginVersion": "8.1.2",
+ "targets": [
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "exemplar": false,
+ "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",type=\"rw\",state!=\"\"}) or vector(1)",
+ "instant": true,
+ "interval": "",
+ "legendFormat": "Total",
+ "refId": "A"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "exemplar": false,
+ "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",type=\"rw\",state!=\"\",snapshot_policy=~\"none.*\", volume!~\"MDV.*\"}) OR on() vector(0)",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "legendFormat": "Not Protected",
+ "refId": "B"
+ }
+ ],
+ "title": "Snapshot copies (local)",
+ "transformations": [
+ {
+ "id": "calculateField",
+ "options": {
+ "alias": "Protected",
+ "binary": {
+ "left": "Total",
+ "operator": "-",
+ "reducer": "sum",
+ "right": "Not Protected"
+ },
+ "mode": "binary",
+ "reduce": {
+ "reducer": "sum"
+ },
+ "replaceFields": false
+ }
+ },
+ {
+ "id": "organize",
+ "options": {
+ "excludeByName": {
+ "Time": true,
+ "Total": true
+ },
+ "indexByName": {},
+ "renameByName": {}
+ }
+ }
+ ],
+ "type": "piechart"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "This panel displays volume protection by SnapMirror relationship.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ }
+ },
+ "decimals": 0,
+ "mappings": [],
+ "unit": "locale"
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Not Protected"
+ },
+ "properties": [
+ {
+ "id": "color",
+ "value": {
+ "fixedColor": "semi-dark-yellow",
+ "mode": "fixed"
+ }
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Protected"
+ },
+ "properties": [
+ {
+ "id": "color",
+ "value": {
+ "fixedColor": "semi-dark-green",
+ "mode": "fixed"
+ }
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 10,
+ "w": 8,
+ "x": 8,
+ "y": 1
+ },
+ "id": 157,
+ "options": {
+ "displayLabels": [
+ "value",
+ "percent"
+ ],
+ "legend": {
+ "displayMode": "table",
+ "placement": "bottom",
+ "values": [
+ "value"
+ ]
+ },
+ "pieType": "donut",
+ "reduceOptions": {
+ "calcs": [
+ "last"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "tooltip": {
+ "mode": "single"
+ }
+ },
+ "pluginVersion": "8.1.2",
+ "targets": [
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "exemplar": false,
+ "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",type=\"rw\",state!=\"\"}) or vector(1)",
+ "instant": true,
+ "interval": "",
+ "legendFormat": "Total",
+ "refId": "A"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "exemplar": false,
+ "expr": "count(volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",type=\"rw\",state!=\"\",isProtected=\"true\",isDestinationOntap=\"true\", svm_root=\"false\"}) or vector(0)",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "legendFormat": "Protected",
+ "refId": "B"
+ }
+ ],
+ "title": "SnapMirrors (local or remote)",
+ "transformations": [
+ {
+ "id": "calculateField",
+ "options": {
+ "alias": "Not Protected",
+ "binary": {
+ "left": "Total",
+ "operator": "-",
+ "reducer": "sum",
+ "right": "Protected"
+ },
+ "mode": "binary",
+ "reduce": {
+ "reducer": "sum"
+ },
+ "replaceFields": false
+ }
+ },
+ {
+ "id": "organize",
+ "options": {
+ "excludeByName": {
+ "Time": true,
+ "Total": true
+ },
+ "indexByName": {},
+ "renameByName": {}
+ }
+ }
+ ],
+ "type": "piechart"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "This panel displays volume protection by backed up to cloud bucket.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ }
+ },
+ "decimals": 0,
+ "mappings": [],
+ "unit": "locale"
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Not Protected"
+ },
+ "properties": [
+ {
+ "id": "color",
+ "value": {
+ "fixedColor": "semi-dark-yellow",
+ "mode": "fixed"
+ }
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Protected"
+ },
+ "properties": [
+ {
+ "id": "color",
+ "value": {
+ "fixedColor": "semi-dark-green",
+ "mode": "fixed"
+ }
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 10,
+ "w": 8,
+ "x": 16,
+ "y": 1
+ },
+ "id": 156,
+ "options": {
+ "displayLabels": [
+ "value",
+ "percent"
+ ],
+ "legend": {
+ "displayMode": "table",
+ "placement": "bottom",
+ "values": [
+ "value"
+ ]
+ },
+ "pieType": "donut",
+ "reduceOptions": {
+ "calcs": [
+ "last"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "tooltip": {
+ "mode": "single"
+ }
+ },
+ "pluginVersion": "8.1.2",
+ "targets": [
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "exemplar": false,
+ "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",state!=\"\"}) or vector(1)",
+ "instant": true,
+ "interval": "",
+ "legendFormat": "Total",
+ "refId": "A"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "exemplar": false,
+ "expr": "count(volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",state!=\"\",isProtected=\"true\", isDestinationCloud=\"true\", svm_root=\"false\"}) or vector(0)",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "legendFormat": "Protected",
+ "refId": "B"
+ }
+ ],
+ "title": "Back up to cloud",
+ "transformations": [
+ {
+ "id": "calculateField",
+ "options": {
+ "alias": "Not Protected",
+ "binary": {
+ "left": "Total",
+ "operator": "-",
+ "reducer": "sum",
+ "right": "Protected"
+ },
+ "mode": "binary",
+ "reduce": {
+ "reducer": "sum"
+ },
+ "replaceFields": false
+ }
+ },
+ {
+ "id": "organize",
+ "options": {
+ "excludeByName": {
+ "Time": true,
+ "Total": true
+ },
+ "indexByName": {},
+ "renameByName": {}
+ }
+ }
+ ],
+ "type": "piechart"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "This panel displays volume protection detail via Snapshot, SnapMirror or Bucket.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "fixedColor": "transparent",
+ "mode": "fixed"
+ },
+ "custom": {
+ "align": "left",
+ "displayMode": "auto",
+ "filterable": true
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
+ },
+ "unit": "bytes"
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "cluster"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Cluster"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-cluster/ontap-cluster?orgId=1&${Datacenter:queryparam}&${__url_time_range}&var-Cluster=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "datacenter"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Datacenter"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-datacenter/ontap-datacenter?orgId=1&${__url_time_range}&var-Datacenter=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "svm"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "SVM"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-svm/ontap-svm?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-SVM=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "volume"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Volume"
+ },
+ {
+ "id": "custom.width",
+ "value": null
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-volume/ontap-volume?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${SVM:queryparam}&${__url_time_range}&var-Volume=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Protected"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "false": {
+ "color": "semi-dark-red",
+ "index": 1,
+ "text": "Not Protected"
+ },
+ "true": {
+ "color": "semi-dark-green",
+ "index": 0,
+ "text": "Protected"
+ }
+ },
+ "type": "value"
+ },
+ {
+ "options": {
+ "match": "empty",
+ "result": {
+ "index": 2,
+ "text": "Not Supported"
+ }
+ },
+ "type": "special"
+ }
+ ]
+ },
+ {
+ "id": "custom.displayMode",
+ "value": "color-background-solid"
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Protected in Cloud"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "false": {
+ "color": "semi-dark-red",
+ "index": 1,
+ "text": "Not Backed Up"
+ },
+ "true": {
+ "color": "semi-dark-green",
+ "index": 0,
+ "text": "Backed Up"
+ }
+ },
+ "type": "value"
+ },
+ {
+ "options": {
+ "match": "empty",
+ "result": {
+ "index": 2,
+ "text": "Not Supported"
+ }
+ },
+ "type": "special"
+ }
+ ]
+ },
+ {
+ "id": "custom.displayMode",
+ "value": "color-background-solid"
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Protected in Ontap"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "false": {
+ "color": "semi-dark-red",
+ "index": 1,
+ "text": "Not In Replication"
+ },
+ "true": {
+ "color": "semi-dark-green",
+ "index": 0,
+ "text": "In Replication"
+ }
+ },
+ "type": "value"
+ },
+ {
+ "options": {
+ "match": "empty",
+ "result": {
+ "index": 2,
+ "text": "Not Supported"
+ }
+ },
+ "type": "special"
+ }
+ ]
+ },
+ {
+ "id": "custom.displayMode",
+ "value": "color-background-solid"
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 24,
+ "x": 0,
+ "y": 11
+ },
+ "id": 162,
+ "options": {
+ "footer": {
+ "fields": "",
+ "reducer": [
+ "sum"
+ ],
+ "show": false
+ },
+ "showHeader": true,
+ "sortBy": []
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"}",
+ "format": "table",
+ "instant": true,
+ "interval": "",
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Volumes",
+ "transformations": [
+ {
+ "id": "filterFieldsByName",
+ "options": {
+ "include": {
+ "names": [
+ "cluster",
+ "datacenter",
+ "svm",
+ "isDestinationCloud",
+ "isDestinationOntap",
+ "isProtected",
+ "snapshot_policy",
+ "volume"
+ ]
+ }
+ }
+ },
+ {
+ "id": "organize",
+ "options": {
+ "excludeByName": {},
+ "includeByName": {},
+ "indexByName": {
+ "cluster": 1,
+ "datacenter": 0,
+ "isDestinationCloud": 5,
+ "isDestinationOntap": 6,
+ "isProtected": 7,
+ "snapshot_policy": 4,
+ "svm": 2,
+ "volume": 3
+ },
+ "renameByName": {
+ "Value": "Snapshot Copies",
+ "Value #B": "Size",
+ "Value #C": "Used",
+ "bucket": "Name",
+ "cluster": "",
+ "comment": "Description",
+ "datacenter": "",
+ "isDestinationCloud": "Protected in Cloud",
+ "isDestinationOntap": "Protected in Ontap",
+ "isProtected": "Protected",
+ "is_protected": "Protected",
+ "name": "Name",
+ "policy_name": "Name",
+ "protected_in_cloud": "Protected in Cloud",
+ "protected_in_ontap": "Protected in Ontap",
+ "schedule_name": "Transfer Schedule",
+ "scope": "Scope",
+ "snapshot_policy": "Snapshot Policy",
+ "svm": "",
+ "type": "",
+ "url": "",
+ "volume": ""
+ }
+ }
+ }
+ ],
+ "type": "table"
+ },
+ {
+ "collapsed": true,
+ "datasource": "${DS_PROMETHEUS}",
+ "gridPos": {
+ "h": 1,
+ "w": 24,
+ "x": 0,
+ "y": 18
+ },
+ "id": 24,
+ "panels": [
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Number of total buckets.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "semi-dark-blue",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 8,
+ "x": 0,
+ "y": 3
+ },
+ "id": 104,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "showPercentChange": false,
+ "text": {},
+ "textMode": "auto",
+ "wideLayout": true
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "editorMode": "code",
+ "exemplar": false,
+ "expr": "count(ontaps3_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Total Buckets",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Number of buckets which are not protected.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "red",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 8,
+ "x": 8,
+ "y": 3
+ },
+ "id": 105,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "showPercentChange": false,
+ "text": {},
+ "textMode": "auto",
+ "wideLayout": true
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "editorMode": "code",
+ "exemplar": false,
+ "expr": "count(ontaps3_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",is_protected=\"false\"})",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Unprotected Buckets",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Number of buckets which are not backed up to cloud.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "red",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 8,
+ "x": 16,
+ "y": 3
+ },
+ "id": 106,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "showPercentChange": false,
+ "text": {},
+ "textMode": "auto",
+ "wideLayout": true
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "editorMode": "code",
+ "exemplar": false,
+ "expr": "count(ontaps3_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",protected_in_cloud=\"false\"})",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Not Backed up to Cloud",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "This panel displays bucket detail.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "fixedColor": "transparent",
+ "mode": "fixed"
+ },
+ "custom": {
+ "align": "left",
+ "displayMode": "auto",
+ "filterable": true
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
+ },
+ "unit": "bytes"
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "cluster"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Cluster"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-cluster/ontap-cluster?orgId=1&${Datacenter:queryparam}&${__url_time_range}&var-Cluster=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "datacenter"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Datacenter"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-datacenter/ontap-datacenter?orgId=1&${__url_time_range}&var-Datacenter=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "svm"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "SVM"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-svm/ontap-svm?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-SVM=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Access Type"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "s3": {
+ "index": 0,
+ "text": "S3"
+ }
+ },
+ "type": "value"
+ },
+ {
+ "options": {
+ "match": "empty",
+ "result": {
+ "index": 2,
+ "text": "Not Supported"
+ }
+ },
+ "type": "special"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Protected"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "false": {
+ "color": "semi-dark-red",
+ "index": 1,
+ "text": "Not Protected"
+ },
+ "true": {
+ "color": "semi-dark-green",
+ "index": 0,
+ "text": "Protected"
+ }
+ },
+ "type": "value"
+ },
+ {
+ "options": {
+ "match": "empty",
+ "result": {
+ "index": 2,
+ "text": "Not Supported"
+ }
+ },
+ "type": "special"
+ }
+ ]
+ },
+ {
+ "id": "custom.displayMode",
+ "value": "color-background-solid"
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Protected in Cloud"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "false": {
+ "color": "semi-dark-red",
+ "index": 1,
+ "text": "Not Backed Up"
+ },
+ "true": {
+ "color": "semi-dark-green",
+ "index": 0,
+ "text": "Backed Up"
+ }
+ },
+ "type": "value"
+ },
+ {
+ "options": {
+ "match": "empty",
+ "result": {
+ "index": 2,
+ "text": "Not Supported"
+ }
+ },
+ "type": "special"
+ }
+ ]
+ },
+ {
+ "id": "custom.displayMode",
+ "value": "color-background-solid"
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Protected in Ontap"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "false": {
+ "color": "semi-dark-red",
+ "index": 1,
+ "text": "Not In Replication"
+ },
+ "true": {
+ "color": "semi-dark-green",
+ "index": 0,
+ "text": "In Replication"
+ }
+ },
+ "type": "value"
+ },
+ {
+ "options": {
+ "match": "empty",
+ "result": {
+ "index": 2,
+ "text": "Not Supported"
+ }
+ },
+ "type": "special"
+ }
+ ]
+ },
+ {
+ "id": "custom.displayMode",
+ "value": "color-background-solid"
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Used"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "match": "null",
+ "result": {
+ "index": 0,
+ "text": "Not used"
+ }
+ },
+ "type": "special"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 24,
+ "x": 0,
+ "y": 8
+ },
+ "id": 103,
+ "options": {
+ "footer": {
+ "fields": "",
+ "reducer": [
+ "sum"
+ ],
+ "show": false
+ },
+ "showHeader": true,
+ "sortBy": []
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "ontaps3_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"}",
+ "format": "table",
+ "instant": true,
+ "interval": "",
+ "legendFormat": "",
+ "refId": "A"
+ },
+ {
+ "exemplar": false,
+ "expr": "ontaps3_size{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"}",
+ "format": "table",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "legendFormat": "",
+ "refId": "B"
+ },
+ {
+ "exemplar": false,
+ "expr": "ontaps3_logical_used_size{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"}",
+ "format": "table",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "legendFormat": "",
+ "refId": "C"
+ }
+ ],
+ "title": "Buckets",
+ "transformations": [
+ {
+ "id": "filterFieldsByName",
+ "options": {
+ "include": {
+ "names": [
+ "bucket",
+ "cluster",
+ "datacenter",
+ "is_protected",
+ "protected_in_cloud",
+ "protected_in_ontap",
+ "svm",
+ "Value #B",
+ "Value #C",
+ "type"
+ ]
+ }
+ }
+ },
+ {
+ "id": "merge",
+ "options": {}
+ },
+ {
+ "id": "organize",
+ "options": {
+ "excludeByName": {},
+ "includeByName": {},
+ "indexByName": {
+ "Value #B": 4,
+ "Value #C": 5,
+ "bucket": 2,
+ "cluster": 1,
+ "datacenter": 0,
+ "is_protected": 7,
+ "protected_in_cloud": 8,
+ "protected_in_ontap": 9,
+ "svm": 3,
+ "type": 6
+ },
+ "renameByName": {
+ "Value": "Snapshot Copies",
+ "Value #B": "Size",
+ "Value #C": "Used",
+ "bucket": "Name",
+ "cluster": "",
+ "comment": "Description",
+ "is_protected": "Protected",
+ "name": "Name",
+ "policy_name": "Name",
+ "protected_in_cloud": "Protected in Cloud",
+ "protected_in_ontap": "Protected in Ontap",
+ "schedule_name": "Transfer Schedule",
+ "scope": "Scope",
+ "svm": "",
+ "type": "Access Type",
+ "url": "",
+ "volume": ""
+ }
+ }
+ }
+ ],
+ "type": "table"
+ }
+ ],
+ "title": "Bucket protection",
+ "type": "row"
+ },
+ {
+ "collapsed": true,
+ "datasource": "${DS_PROMETHEUS}",
+ "gridPos": {
+ "h": 1,
+ "w": 24,
+ "x": 0,
+ "y": 19
+ },
+ "id": 45,
+ "panels": [
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Total number of volumes that are not protected.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [
+ {
+ "options": {
+ "match": "null",
+ "result": {
+ "color": "rgb(21, 118, 171)",
+ "text": "0"
+ }
+ },
+ "type": "special"
+ }
+ ],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "dark-yellow",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 6,
+ "x": 0,
+ "y": 12
+ },
+ "id": 79,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "text": {},
+ "textMode": "auto"
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "count((volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy=~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{}))) OR on() vector(0)",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Volumes not protected",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Total number of volumes that are protected.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "semi-dark-green",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 6,
+ "x": 6,
+ "y": 12
+ },
+ "id": 75,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "text": {},
+ "textMode": "auto"
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\", snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{})) OR on() vector(0)",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Volumes protected",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Total number of volumes whose snapshot size used is breached the snapshot reserve size.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "light-red",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 6,
+ "x": 12,
+ "y": 12
+ },
+ "id": 77,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "text": {},
+ "textMode": "auto"
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\", snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} > volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"})) OR on() vector(0)",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Volumes breached",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Total number of volumes whose snapshot size used is not breached the snapshot reserve size.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [
+ {
+ "options": {
+ "match": "null",
+ "result": {
+ "color": "rgb(21, 118, 171)",
+ "text": "0"
+ }
+ },
+ "type": "special"
+ }
+ ],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "semi-dark-green",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 6,
+ "x": 18,
+ "y": 12
+ },
+ "id": 81,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "text": {},
+ "textMode": "auto"
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "(count((volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\", snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{})) * on (volume, svm, cluster) group_right() (volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} > 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} > 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} <= volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"})) OR on() vector(0)) + (count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} == 0)) OR on() vector(0))",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Volumes not breached",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "This panel displays volumes detail with protected status and snapshot policy.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "fixedColor": "transparent",
+ "mode": "fixed"
+ },
+ "custom": {
+ "align": "auto",
+ "displayMode": "auto",
+ "filterable": true
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
+ }
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Status"
+ },
+ "properties": [
+ {
+ "id": "custom.filterable",
+ "value": true
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "volume"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Volume"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-volume/ontap-volume?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-Volume=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "svm"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "SVM"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-svm/ontap-svm?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-SVM=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 13,
+ "w": 12,
+ "x": 0,
+ "y": 17
+ },
+ "id": 83,
+ "options": {
+ "footer": {
+ "fields": "",
+ "reducer": [
+ "sum"
+ ],
+ "show": false
+ },
+ "showHeader": true,
+ "sortBy": []
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "label_replace(label_replace(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\", snapshot_policy!=\"\", volume!~\"MDV.*\"}, \"Status\", \"Protected\", \"snapshot_policy\", \"(.*)\") , \"Status\", \"Unprotected\", \"snapshot_policy\", \"(none.*)\") * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{})",
+ "format": "table",
+ "instant": true,
+ "interval": "",
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Volumes Protected With Snapshot Copies (local)",
+ "transformations": [
+ {
+ "id": "filterFieldsByName",
+ "options": {
+ "include": {
+ "names": [
+ "snapshot_policy",
+ "volume",
+ "Status",
+ "svm"
+ ]
+ }
+ }
+ },
+ {
+ "id": "organize",
+ "options": {
+ "indexByName": {
+ "Status": 3,
+ "snapshot_policy": 2,
+ "svm": 1,
+ "volume": 0
+ },
+ "renameByName": {
+ "snapshot_policy": "Snapshot Policy"
+ }
+ }
+ }
+ ],
+ "type": "table"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Volumes details of snapshot copy reserve space.",
+ "fieldConfig": {
+ "defaults": {
+ "custom": {
+ "align": "left",
+ "displayMode": "auto",
+ "filterable": true
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "rgb(31, 176, 196)",
+ "value": null
+ }
+ ]
+ },
+ "unit": "none"
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "volume"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Volume"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-volume/ontap-volume?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-Volume=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Value #B"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Used"
+ },
+ {
+ "id": "unit",
+ "value": "bytes"
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Value #A"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Reserved"
+ },
+ {
+ "id": "unit",
+ "value": "bytes"
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Status"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "from": -1e+25,
+ "result": {
+ "index": 0,
+ "text": "Not Breached"
+ },
+ "to": 0
+ },
+ "type": "range"
+ },
+ {
+ "options": {
+ "from": 0,
+ "result": {
+ "index": 1,
+ "text": "Breached"
+ },
+ "to": 1e+25
+ },
+ "type": "range"
+ }
+ ]
+ },
+ {
+ "id": "custom.filterable",
+ "value": true
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "svm"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "SVM"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-svm/ontap-svm?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-SVM=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 13,
+ "w": 12,
+ "x": 12,
+ "y": 17
+ },
+ "id": 91,
+ "interval": "1m",
+ "maxDataPoints": 2,
+ "options": {
+ "footer": {
+ "fields": "",
+ "reducer": [
+ "sum"
+ ],
+ "show": false
+ },
+ "showHeader": true,
+ "sortBy": []
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\", snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0)",
+ "format": "table",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ },
+ {
+ "exemplar": false,
+ "expr": "volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"}",
+ "format": "table",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "legendFormat": "",
+ "refId": "B"
+ }
+ ],
+ "title": "Volumes Breaching Snapshot Copy Reserve Space",
+ "transformations": [
+ {
+ "id": "merge",
+ "options": {}
+ },
+ {
+ "id": "filterByValue",
+ "options": {
+ "filters": [
+ {
+ "config": {
+ "id": "greaterOrEqual",
+ "options": {
+ "value": 0
+ }
+ },
+ "fieldName": "Value #A"
+ }
+ ],
+ "match": "all",
+ "type": "include"
+ }
+ },
+ {
+ "id": "filterFieldsByName",
+ "options": {
+ "include": {
+ "names": [
+ "volume",
+ "Value #A",
+ "Value #B",
+ "svm"
+ ]
+ }
+ }
+ },
+ {
+ "id": "calculateField",
+ "options": {
+ "alias": "Status",
+ "binary": {
+ "left": "Value #B",
+ "operator": "-",
+ "reducer": "sum",
+ "right": "Value #A"
+ },
+ "mode": "binary",
+ "reduce": {
+ "include": [
+ "Value #A",
+ "Value #B"
+ ],
+ "reducer": "sum"
+ }
+ }
+ },
+ {
+ "id": "organize",
+ "options": {
+ "excludeByName": {},
+ "indexByName": {
+ "Status": 4,
+ "Value #A": 2,
+ "Value #B": 3,
+ "svm": 1,
+ "volume": 0
+ },
+ "renameByName": {}
+ }
+ }
+ ],
+ "type": "table"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Total number of volumes whose snapshot count is < 10.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "rgb(31, 176, 196)",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 6,
+ "x": 0,
+ "y": 30
+ },
+ "id": 96,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "text": {},
+ "textMode": "auto"
+ },
+ "pluginVersion": "8.4.11",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 0 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} < 10)) OR on() vector(0)",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": " <10 Copies ",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Total number of volumes whose snapshot count is between 10 to 100.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "rgb(31, 176, 196)",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 6,
+ "x": 6,
+ "y": 30
+ },
+ "id": 97,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "text": {},
+ "textMode": "auto"
+ },
+ "pluginVersion": "8.4.11",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} >= 10 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} <= 100)) OR on() vector(0)",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "10-100 Copies",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Total number of volumes whose snapshot count is between 101 to 500.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "rgb(31, 176, 196)",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 6,
+ "x": 12,
+ "y": 30
+ },
+ "id": 98,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "text": {},
+ "textMode": "auto"
+ },
+ "pluginVersion": "8.4.11",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 100 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} <= 500)) OR on() vector(0)",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "101-500 Copies",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "Total number of volumes whose snapshot count is > 500.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "noValue": "0",
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "rgb(31, 176, 196)",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 5,
+ "w": 6,
+ "x": 18,
+ "y": 30
+ },
+ "id": 99,
+ "links": [],
+ "options": {
+ "colorMode": "value",
+ "graphMode": "none",
+ "justifyMode": "center",
+ "orientation": "horizontal",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "text": {},
+ "textMode": "auto"
+ },
+ "pluginVersion": "8.4.11",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 500)) OR on() vector(0)",
+ "format": "time_series",
+ "hide": false,
+ "instant": true,
+ "interval": "",
+ "intervalFactor": 1,
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": ">500 Copies",
+ "type": "stat"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "This panel displays volumes detail with snapshot count.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "fixedColor": "transparent",
+ "mode": "fixed"
+ },
+ "custom": {
+ "align": "left",
+ "displayMode": "auto",
+ "filterable": true
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
+ }
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Bucket"
+ },
+ "properties": [
+ {
+ "id": "custom.filterable",
+ "value": true
+ },
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "from": 0,
+ "result": {
+ "index": 0,
+ "text": "< 10 Copies"
+ },
+ "to": 9
+ },
+ "type": "range"
+ },
+ {
+ "options": {
+ "from": 10,
+ "result": {
+ "index": 1,
+ "text": "10-100 Copies"
+ },
+ "to": 100
+ },
+ "type": "range"
+ },
+ {
+ "options": {
+ "from": 101,
+ "result": {
+ "index": 2,
+ "text": "101-500 Copies"
+ },
+ "to": 500
+ },
+ "type": "range"
+ },
+ {
+ "options": {
+ "from": 501,
+ "result": {
+ "index": 3,
+ "text": "> 500 Copies"
+ },
+ "to": 1e+24
+ },
+ "type": "range"
+ }
+ ]
+ },
+ {
+ "id": "displayName",
+ "value": "Snapshot Copies Bucket"
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "volume"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Volume"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-volume/ontap-volume?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-Volume=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "svm"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "SVM"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-svm/ontap-svm?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-SVM=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "cluster"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Cluster"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-cluster/ontap-cluster?orgId=1&${Datacenter:queryparam}&${__url_time_range}&var-Cluster=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 15,
+ "w": 24,
+ "x": 0,
+ "y": 35
+ },
+ "id": 94,
+ "options": {
+ "footer": {
+ "fields": "",
+ "reducer": [
+ "sum"
+ ],
+ "show": false
+ },
+ "showHeader": true,
+ "sortBy": []
+ },
+ "pluginVersion": "8.4.11",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "(volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 0)",
+ "format": "table",
+ "instant": true,
+ "interval": "",
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Volume count by the number of Snapshot copies",
+ "transformations": [
+ {
+ "id": "filterFieldsByName",
+ "options": {
+ "include": {
+ "names": [
+ "svm",
+ "volume",
+ "Value",
+ "cluster"
+ ]
+ }
+ }
+ },
+ {
+ "id": "organize",
+ "options": {
+ "excludeByName": {},
+ "indexByName": {
+ "Value": 3,
+ "cluster": 2,
+ "svm": 1,
+ "volume": 0
+ },
+ "renameByName": {
+ "Value": "Snapshot Copies",
+ "volume": ""
+ }
+ }
+ },
+ {
+ "id": "calculateField",
+ "options": {
+ "alias": "Bucket",
+ "mode": "reduceRow",
+ "reduce": {
+ "include": [
+ "Snapshot Copies"
+ ],
+ "reducer": "last"
+ }
+ }
+ }
+ ],
+ "type": "table"
+ }
+ ],
+ "title": "Snapshot Copies",
+ "type": "row"
+ },
+ {
+ "collapsed": true,
+ "datasource": "${DS_PROMETHEUS}",
+ "gridPos": {
+ "h": 1,
+ "w": 24,
+ "x": 0,
+ "y": 20
+ },
+ "id": 23,
+ "panels": [
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "This panel displays protection policy detail.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "fixedColor": "transparent",
+ "mode": "fixed"
+ },
+ "custom": {
+ "align": "left",
+ "displayMode": "auto",
+ "filterable": true
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
+ }
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "cluster"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Cluster"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-cluster/ontap-cluster?orgId=1&${Datacenter:queryparam}&${__url_time_range}&var-Cluster=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "datacenter"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Datacenter"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-datacenter/ontap-datacenter?orgId=1&${__url_time_range}&var-Datacenter=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Policy Type"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "async": {
+ "index": 0,
+ "text": "Asynchronous"
+ },
+ "continuous": {
+ "index": 2,
+ "text": "Continuous"
+ },
+ "sync": {
+ "index": 1,
+ "text": "Synchronous"
+ }
+ },
+ "type": "value"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Scope"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "cluster": {
+ "index": 0,
+ "text": "Cluster"
+ }
+ },
+ "type": "value"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 15,
+ "w": 24,
+ "x": 0,
+ "y": 15
+ },
+ "id": 100,
+ "options": {
+ "footer": {
+ "fields": "",
+ "reducer": [
+ "sum"
+ ],
+ "show": false
+ },
+ "showHeader": true,
+ "sortBy": [
+ {
+ "desc": false,
+ "displayName": "Name"
+ }
+ ]
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "snapmirror_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"}",
+ "format": "table",
+ "instant": true,
+ "interval": "",
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Protection policies",
+ "transformations": [
+ {
+ "id": "filterFieldsByName",
+ "options": {
+ "include": {
+ "names": [
+ "cluster",
+ "datacenter",
+ "policy_name",
+ "scope",
+ "type",
+ "schedule_name",
+ "comment"
+ ]
+ }
+ }
+ },
+ {
+ "id": "organize",
+ "options": {
+ "excludeByName": {},
+ "indexByName": {
+ "cluster": 1,
+ "comment": 3,
+ "datacenter": 0,
+ "policy_name": 2,
+ "schedule_name": 6,
+ "scope": 5,
+ "type": 4
+ },
+ "renameByName": {
+ "Value": "Snapshot Copies",
+ "cluster": "",
+ "comment": "Description",
+ "policy_name": "Name",
+ "schedule_name": "Transfer Schedule",
+ "scope": "Scope",
+ "type": "Policy Type",
+ "volume": ""
+ }
+ }
+ }
+ ],
+ "type": "table"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "This panel displays Snapshot policy detail.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "fixedColor": "transparent",
+ "mode": "fixed"
+ },
+ "custom": {
+ "align": "left",
+ "displayMode": "auto",
+ "filterable": true
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "cluster"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Cluster"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-cluster/ontap-cluster?orgId=1&${Datacenter:queryparam}&${__url_time_range}&var-Cluster=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "datacenter"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Datacenter"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-datacenter/ontap-datacenter?orgId=1&${__url_time_range}&var-Datacenter=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Scope"
+ },
+ "properties": [
+ {
+ "id": "noValue",
+ "value": "Cluster"
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "copies"
+ },
+ "properties": [
+ {
+ "id": "noValue",
+ "value": "0"
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Enabled"
+ },
+ "properties": [
+ {
+ "id": "custom.displayMode",
+ "value": "color-background-solid"
+ },
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "false": {
+ "color": "semi-dark-red",
+ "index": 1,
+ "text": "Disabled"
+ },
+ "true": {
+ "color": "semi-dark-green",
+ "index": 0,
+ "text": "Enabled"
+ }
+ },
+ "type": "value"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 8,
+ "w": 24,
+ "x": 0,
+ "y": 30
+ },
+ "id": 101,
+ "options": {
+ "footer": {
+ "fields": "",
+ "reducer": [
+ "sum"
+ ],
+ "show": false
+ },
+ "showHeader": true,
+ "sortBy": [
+ {
+ "desc": false,
+ "displayName": "Enabled"
+ }
+ ]
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "snapshot_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"}",
+ "format": "table",
+ "instant": true,
+ "interval": "",
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Snapshot policies",
+ "transformations": [
+ {
+ "id": "filterFieldsByName",
+ "options": {
+ "include": {
+ "names": [
+ "cluster",
+ "comment",
+ "datacenter",
+ "snapshot_policy",
+ "enabled",
+ "copies",
+ "svm"
+ ]
+ }
+ }
+ },
+ {
+ "id": "organize",
+ "options": {
+ "excludeByName": {},
+ "indexByName": {
+ "cluster": 1,
+ "comment": 3,
+ "copies": 6,
+ "datacenter": 0,
+ "enabled": 4,
+ "snapshot_policy": 2,
+ "svm": 5
+ },
+ "renameByName": {
+ "Value": "Snapshot Copies",
+ "cluster": "",
+ "comment": "Description",
+ "enabled": "Enabled",
+ "policy_name": "Name",
+ "schedule_name": "Transfer Schedule",
+ "scope": "Scope",
+ "snapshot_policy": "Policy Name",
+ "svm": "Scope",
+ "type": "Policy Type",
+ "volume": ""
+ }
+ }
+ }
+ ],
+ "type": "table"
+ },
+ {
+ "datasource": "${DS_PROMETHEUS}",
+ "description": "This panel displays cluster schedules detail.",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "fixedColor": "transparent",
+ "mode": "fixed"
+ },
+ "custom": {
+ "align": "left",
+ "displayMode": "auto",
+ "filterable": true
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
+ },
+ "unit": "short"
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "cluster"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Cluster"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-cluster/ontap-cluster?orgId=1&${Datacenter:queryparam}&${__url_time_range}&var-Cluster=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "datacenter"
+ },
+ "properties": [
+ {
+ "id": "displayName",
+ "value": "Datacenter"
+ },
+ {
+ "id": "links",
+ "value": [
+ {
+ "targetBlank": true,
+ "title": "",
+ "url": "/d/cdot-datacenter/ontap-datacenter?orgId=1&${__url_time_range}&var-Datacenter=${__value.raw}"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "Type"
+ },
+ "properties": [
+ {
+ "id": "mappings",
+ "value": [
+ {
+ "options": {
+ "cron": {
+ "index": 0,
+ "text": "Time-based"
+ },
+ "interval": {
+ "index": 1,
+ "text": "Interval-based"
+ }
+ },
+ "type": "value"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 15,
+ "w": 24,
+ "x": 0,
+ "y": 38
+ },
+ "id": 102,
+ "options": {
+ "footer": {
+ "fields": "",
+ "reducer": [
+ "sum"
+ ],
+ "show": false
+ },
+ "showHeader": true,
+ "sortBy": []
+ },
+ "pluginVersion": "8.1.8",
+ "targets": [
+ {
+ "exemplar": false,
+ "expr": "cluster_schedule_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"}",
+ "format": "table",
+ "instant": true,
+ "interval": "",
+ "legendFormat": "",
+ "refId": "A"
+ }
+ ],
+ "title": "Schedules",
+ "transformations": [
+ {
+ "id": "filterFieldsByName",
+ "options": {
+ "include": {
+ "names": [
+ "cluster",
+ "schedule",
+ "datacenter",
+ "name",
+ "type",
+ "scope"
+ ]
+ }
+ }
+ },
+ {
+ "id": "organize",
+ "options": {
+ "excludeByName": {},
+ "includeByName": {},
+ "indexByName": {
+ "cluster": 1,
+ "datacenter": 0,
+ "name": 2,
+ "type": 3
+ },
+ "renameByName": {
+ "Value": "Snapshot Copies",
+ "cluster": "",
+ "comment": "Description",
+ "name": "Name",
+ "policy_name": "Name",
+ "schedule": "Schedule",
+ "schedule_name": "Transfer Schedule",
+ "scope": "Scope",
+ "type": "Type",
+ "volume": ""
+ }
+ }
+ }
+ ],
+ "type": "table"
+ }
+ ],
+ "title": "Local Policy",
+ "type": "row"
+ }
+ ],
+ "refresh": "",
+ "schemaVersion": 30,
+ "style": "dark",
+ "tags": [
+ "harvest",
+ "ontap",
+ "cdot",
+ "fsx"
+ ],
+ "templating": {
+ "list": [
+ {
+ "current": {
+ "selected": false,
+ "text": "Prometheus",
+ "value": "Prometheus"
+ },
+ "description": null,
+ "error": null,
+ "hide": 2,
+ "includeAll": false,
+ "label": "Data Source",
+ "multi": false,
+ "name": "DS_PROMETHEUS",
+ "options": [],
+ "query": "prometheus",
+ "refresh": 2,
+ "regex": "",
+ "skipUrlSync": false,
+ "type": "datasource"
+ },
+ {
+ "allValue": null,
+ "current": {},
+ "datasource": "${DS_PROMETHEUS}",
+ "definition": "label_values(cluster_new_status{system_type!=\"7mode\"},datacenter)",
+ "description": null,
+ "error": null,
+ "hide": 0,
+ "includeAll": false,
+ "label": null,
+ "multi": true,
+ "name": "Datacenter",
+ "options": [],
+ "query": {
+ "query": "label_values(cluster_new_status{system_type!=\"7mode\"},datacenter)",
+ "refId": "StandardVariableQuery"
+ },
+ "refresh": 2,
+ "regex": "",
+ "skipUrlSync": false,
+ "sort": 1,
+ "tagValuesQuery": "",
+ "tagsQuery": "",
+ "type": "query",
+ "useTags": false
+ },
+ {
+ "allValue": ".*",
+ "current": {},
+ "datasource": "${DS_PROMETHEUS}",
+ "definition": "label_values(cluster_new_status{system_type!=\"7mode\",datacenter=~\"$Datacenter\"},cluster)",
+ "description": null,
+ "error": null,
+ "hide": 0,
+ "includeAll": true,
+ "label": null,
+ "multi": true,
+ "name": "Cluster",
+ "options": [],
+ "query": {
+ "query": "label_values(cluster_new_status{system_type!=\"7mode\",datacenter=~\"$Datacenter\"},cluster)",
+ "refId": "StandardVariableQuery"
+ },
+ "refresh": 2,
+ "regex": "",
+ "skipUrlSync": false,
+ "sort": 1,
+ "tagValuesQuery": "",
+ "tagsQuery": "",
+ "type": "query",
+ "useTags": false
+ }
+ ]
+ },
+ "time": {
+ "from": "now-3h",
+ "to": "now"
+ },
+ "timepicker": {
+ "refresh_intervals": [
+ "10s",
+ "30s",
+ "1m",
+ "5m",
+ "15m",
+ "30m",
+ "1h",
+ "2h",
+ "1d"
+ ]
+ },
+ "timezone": "",
+ "title": "ONTAP: Data Protection",
+ "uid": "cdot-data-protection",
+ "version": 3
+}
diff --git a/grafana/dashboards/cmode/data_protection_snapshot.json b/grafana/dashboards/cmode/data_protection_snapshot.json
deleted file mode 100644
index b05b5c6e3..000000000
--- a/grafana/dashboards/cmode/data_protection_snapshot.json
+++ /dev/null
@@ -1,1677 +0,0 @@
-{
- "__inputs": [
- {
- "description": "",
- "label": "Prometheus",
- "name": "DS_PROMETHEUS",
- "pluginId": "prometheus",
- "pluginName": "Prometheus",
- "type": "datasource"
- }
- ],
- "__requires": [
- {
- "id": "bargauge",
- "name": "Bar gauge",
- "type": "panel",
- "version": ""
- },
- {
- "id": "grafana",
- "name": "Grafana",
- "type": "grafana",
- "version": "7.5.4"
- },
- {
- "id": "graph",
- "name": "Graph",
- "type": "panel",
- "version": ""
- },
- {
- "id": "prometheus",
- "name": "Prometheus",
- "type": "datasource",
- "version": "1.0.0"
- },
- {
- "id": "stat",
- "name": "Stat",
- "type": "panel",
- "version": ""
- },
- {
- "id": "table",
- "name": "Table",
- "type": "panel",
- "version": ""
- }
- ],
- "annotations": {
- "list": [
- {
- "builtIn": 1,
- "datasource": "-- Grafana --",
- "enable": true,
- "hide": true,
- "iconColor": "rgba(0, 211, 255, 1)",
- "name": "Annotations & Alerts",
- "target": {
- "limit": 100,
- "matchAny": false,
- "tags": [],
- "type": "dashboard"
- },
- "type": "dashboard"
- }
- ]
- },
- "description": "",
- "editable": true,
- "gnetId": null,
- "graphTooltip": 1,
- "id": null,
- "iteration": 1637051731590,
- "links": [
- {
- "asDropdown": true,
- "icon": "external link",
- "includeVars": true,
- "keepTime": true,
- "tags": [
- "cdot"
- ],
- "targetBlank": false,
- "title": "Related Dashboards",
- "tooltip": "",
- "type": "dashboards",
- "url": ""
- }
- ],
- "panels": [
- {
- "collapsed": true,
- "datasource": "${DS_PROMETHEUS}",
- "gridPos": {
- "h": 1,
- "w": 24,
- "x": 0,
- "y": 0
- },
- "id": 45,
- "panels": [
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Volumes Protected With Snapshot Copies (local).",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- }
- },
- "decimals": 0,
- "mappings": []
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "Volumes protected"
- },
- "properties": [
- {
- "id": "color",
- "value": {
- "fixedColor": "green",
- "mode": "fixed"
- }
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Volumes not protected"
- },
- "properties": [
- {
- "id": "color",
- "value": {
- "fixedColor": "yellow",
- "mode": "fixed"
- }
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 10,
- "w": 6,
- "x": 0,
- "y": 1
- },
- "id": 12,
- "options": {
- "legend": {
- "displayMode": "hidden",
- "placement": "right",
- "values": [
- "value"
- ]
- },
- "pieType": "donut",
- "reduceOptions": {
- "calcs": [
- "last"
- ],
- "fields": "",
- "values": false
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
- },
- "pluginVersion": "8.1.2",
- "targets": [
- {
- "exemplar": false,
- "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{})) OR on() vector(0)",
- "instant": true,
- "interval": "",
- "legendFormat": "Volumes protected",
- "refId": "A"
- },
- {
- "exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy=~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{}))) OR on() vector(0)",
- "hide": false,
- "instant": true,
- "interval": "",
- "legendFormat": "Volumes not protected",
- "refId": "B"
- }
- ],
- "title": "Protected Status",
- "transformations": [],
- "type": "piechart"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Total number of volumes that are protected.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "noValue": "0",
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "semi-dark-green",
- "value": null
- }
- ]
- },
- "unit": "short"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 5,
- "w": 6,
- "x": 6,
- "y": 1
- },
- "id": 75,
- "links": [],
- "options": {
- "colorMode": "value",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "horizontal",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {},
- "textMode": "auto"
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\", snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{})) OR on() vector(0)",
- "format": "time_series",
- "hide": false,
- "instant": true,
- "interval": "",
- "intervalFactor": 1,
- "legendFormat": "",
- "refId": "A"
- }
- ],
- "title": "Volumes protected",
- "type": "stat"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Volumes Breaching Snapshot Copy Reserve Space.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- }
- },
- "decimals": 0,
- "mappings": []
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "Volumes breached"
- },
- "properties": [
- {
- "id": "color",
- "value": {
- "fixedColor": "super-light-red",
- "mode": "fixed"
- }
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Volumes not breached"
- },
- "properties": [
- {
- "id": "color",
- "value": {
- "fixedColor": "green",
- "mode": "fixed"
- }
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 10,
- "w": 6,
- "x": 12,
- "y": 1
- },
- "id": 13,
- "options": {
- "legend": {
- "displayMode": "hidden",
- "placement": "right",
- "values": [
- "value"
- ]
- },
- "pieType": "donut",
- "reduceOptions": {
- "calcs": [
- "last"
- ],
- "fields": "",
- "values": false
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
- },
- "pluginVersion": "8.1.2",
- "targets": [
- {
- "exemplar": false,
- "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} > volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"})) OR on() vector(0)",
- "instant": true,
- "interval": "",
- "legendFormat": "Volumes breached",
- "refId": "A"
- },
- {
- "exemplar": false,
- "expr": "(count((volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{})) * on (volume, svm, cluster) group_right() (volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} <= volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"})) OR on() vector(0)) + (count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} == 0)) OR on() vector(0))",
- "instant": true,
- "interval": "",
- "legendFormat": "Volumes not breached",
- "refId": "B"
- }
- ],
- "title": "Breached Status",
- "transformations": [],
- "type": "piechart"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Total number of volumes whose snapshot size used is breached the snapshot reserve size.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "noValue": "0",
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "light-red",
- "value": null
- }
- ]
- },
- "unit": "short"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 5,
- "w": 6,
- "x": 18,
- "y": 1
- },
- "id": 77,
- "links": [],
- "options": {
- "colorMode": "value",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "horizontal",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {},
- "textMode": "auto"
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\", snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} > volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"})) OR on() vector(0)",
- "format": "time_series",
- "hide": false,
- "instant": true,
- "interval": "",
- "intervalFactor": 1,
- "legendFormat": "",
- "refId": "A"
- }
- ],
- "title": "Volumes breached",
- "type": "stat"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Total number of volumes that are not protected.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [
- {
- "options": {
- "match": "null",
- "result": {
- "color": "rgb(21, 118, 171)",
- "text": "0"
- }
- },
- "type": "special"
- }
- ],
- "noValue": "0",
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "dark-yellow",
- "value": null
- }
- ]
- },
- "unit": "short"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 5,
- "w": 6,
- "x": 6,
- "y": 6
- },
- "id": 79,
- "links": [],
- "options": {
- "colorMode": "value",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "horizontal",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {},
- "textMode": "auto"
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy=~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{}))) OR on() vector(0)",
- "format": "time_series",
- "hide": false,
- "instant": true,
- "interval": "",
- "intervalFactor": 1,
- "legendFormat": "",
- "refId": "A"
- }
- ],
- "title": "Volumes not protected",
- "type": "stat"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Total number of volumes whose snapshot size used is not breached the snapshot reserve size.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [
- {
- "options": {
- "match": "null",
- "result": {
- "color": "rgb(21, 118, 171)",
- "text": "0"
- }
- },
- "type": "special"
- }
- ],
- "noValue": "0",
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "semi-dark-green",
- "value": null
- }
- ]
- },
- "unit": "short"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 5,
- "w": 6,
- "x": 18,
- "y": 6
- },
- "id": 81,
- "links": [],
- "options": {
- "colorMode": "value",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "horizontal",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {},
- "textMode": "auto"
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "(count((volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\", snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{})) * on (volume, svm, cluster) group_right() (volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} > 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} > 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} <= volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"})) OR on() vector(0)) + (count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} == 0)) OR on() vector(0))",
- "format": "time_series",
- "hide": false,
- "instant": true,
- "interval": "",
- "intervalFactor": 1,
- "legendFormat": "",
- "refId": "A"
- }
- ],
- "title": "Volumes not breached",
- "type": "stat"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "This panel displays volumes detail with protected status and snapshot policy.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "fixedColor": "transparent",
- "mode": "fixed"
- },
- "custom": {
- "align": "auto",
- "displayMode": "auto",
- "filterable": true
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- }
- ]
- }
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "Status"
- },
- "properties": [
- {
- "id": "custom.filterable",
- "value": true
- },
- {
- "id": "custom.width",
- "value": 150
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "volume"
- },
- "properties": [
- {
- "id": "displayName",
- "value": "Volume"
- },
- {
- "id": "custom.width",
- "value": 350
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "",
- "url": "/d/cdot-volume/ontap-volume?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-Volume=${__value.raw}"
- }
- ]
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "snapshot_policy"
- },
- "properties": [
- {
- "id": "displayName",
- "value": "Snapshot Policy"
- },
- {
- "id": "custom.width",
- "value": 220
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "svm"
- },
- "properties": [
- {
- "id": "displayName",
- "value": "SVM"
- },
- {
- "id": "custom.width",
- "value": 250
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "",
- "url": "/d/cdot-svm/ontap-svm?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-SVM=${__value.raw}"
- }
- ]
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 13,
- "w": 12,
- "x": 0,
- "y": 11
- },
- "id": 83,
- "options": {
- "footer": {
- "fields": "",
- "reducer": [
- "sum"
- ],
- "show": false
- },
- "showHeader": true,
- "sortBy": []
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "label_replace(label_replace(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\", snapshot_policy!=\"\", volume!~\"MDV.*\"}, \"Status\", \"Protected\", \"snapshot_policy\", \"(.*)\") , \"Status\", \"Unprotected\", \"snapshot_policy\", \"(none.*)\") * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{})",
- "format": "table",
- "instant": true,
- "interval": "",
- "legendFormat": "",
- "refId": "A"
- }
- ],
- "title": "Volumes Protected With Snapshot Copies (local)",
- "transformations": [
- {
- "id": "filterFieldsByName",
- "options": {
- "include": {
- "names": [
- "snapshot_policy",
- "volume",
- "Status",
- "svm"
- ]
- }
- }
- },
- {
- "id": "organize",
- "options": {
- "indexByName": {
- "Status": 3,
- "snapshot_policy": 2,
- "svm": 1,
- "volume": 0
- }
- }
- }
- ],
- "type": "table"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Volumes details of snapshot copy reserve space.",
- "fieldConfig": {
- "defaults": {
- "custom": {
- "align": "left",
- "displayMode": "auto",
- "filterable": true
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "rgb(31, 176, 196)",
- "value": null
- }
- ]
- },
- "unit": "none"
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "volume"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 320
- },
- {
- "id": "displayName",
- "value": "Volume"
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "",
- "url": "/d/cdot-volume/ontap-volume?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-Volume=${__value.raw}"
- }
- ]
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Value #B"
- },
- "properties": [
- {
- "id": "displayName",
- "value": "Used"
- },
- {
- "id": "unit",
- "value": "bytes"
- },
- {
- "id": "custom.width",
- "value": 130
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Value #A"
- },
- "properties": [
- {
- "id": "displayName",
- "value": "Reserved"
- },
- {
- "id": "unit",
- "value": "bytes"
- },
- {
- "id": "custom.width",
- "value": 130
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Status"
- },
- "properties": [
- {
- "id": "mappings",
- "value": [
- {
- "options": {
- "from": -1e+25,
- "result": {
- "index": 0,
- "text": "Not Breached"
- },
- "to": 0
- },
- "type": "range"
- },
- {
- "options": {
- "from": 0,
- "result": {
- "index": 1,
- "text": "Breached"
- },
- "to": 1e+25
- },
- "type": "range"
- }
- ]
- },
- {
- "id": "custom.filterable",
- "value": true
- },
- {
- "id": "custom.width",
- "value": 150
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "svm"
- },
- "properties": [
- {
- "id": "displayName",
- "value": "SVM"
- },
- {
- "id": "custom.width",
- "value": 240
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "",
- "url": "/d/cdot-svm/ontap-svm?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-SVM=${__value.raw}"
- }
- ]
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 13,
- "w": 12,
- "x": 12,
- "y": 11
- },
- "id": 91,
- "interval": "1m",
- "maxDataPoints": 2,
- "options": {
- "footer": {
- "fields": "",
- "reducer": [
- "sum"
- ],
- "show": false
- },
- "showHeader": true,
- "sortBy": []
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\", snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0)",
- "format": "table",
- "hide": false,
- "instant": true,
- "interval": "",
- "intervalFactor": 1,
- "legendFormat": "",
- "refId": "A"
- },
- {
- "exemplar": false,
- "expr": "volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"}",
- "format": "table",
- "hide": false,
- "instant": true,
- "interval": "",
- "legendFormat": "",
- "refId": "B"
- }
- ],
- "title": "Volumes Breaching Snapshot Copy Reserve Space",
- "transformations": [
- {
- "id": "merge",
- "options": {}
- },
- {
- "id": "filterByValue",
- "options": {
- "filters": [
- {
- "config": {
- "id": "greaterOrEqual",
- "options": {
- "value": 0
- }
- },
- "fieldName": "Value #A"
- }
- ],
- "match": "all",
- "type": "include"
- }
- },
- {
- "id": "filterFieldsByName",
- "options": {
- "include": {
- "names": [
- "volume",
- "Value #A",
- "Value #B",
- "svm"
- ]
- }
- }
- },
- {
- "id": "calculateField",
- "options": {
- "alias": "Status",
- "binary": {
- "left": "Value #B",
- "operator": "-",
- "reducer": "sum",
- "right": "Value #A"
- },
- "mode": "binary",
- "reduce": {
- "include": [
- "Value #A",
- "Value #B"
- ],
- "reducer": "sum"
- }
- }
- },
- {
- "id": "organize",
- "options": {
- "excludeByName": {},
- "indexByName": {
- "Status": 4,
- "Value #A": 2,
- "Value #B": 3,
- "svm": 1,
- "volume": 0
- },
- "renameByName": {}
- }
- }
- ],
- "type": "table"
- }
- ],
- "title": "Snapshot Copies Overview",
- "type": "row"
- },
- {
- "collapsed": true,
- "datasource": "${DS_PROMETHEUS}",
- "gridPos": {
- "h": 1,
- "w": 24,
- "x": 0,
- "y": 1
- },
- "id": 22,
- "panels": [
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Total number of volumes whose snapshot count is < 10.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "noValue": "0",
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "rgb(31, 176, 196)",
- "value": null
- }
- ]
- },
- "unit": "short"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 5,
- "w": 6,
- "x": 0,
- "y": 2
- },
- "id": 96,
- "links": [],
- "options": {
- "colorMode": "value",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "horizontal",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {},
- "textMode": "auto"
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 0 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} < 10)) OR on() vector(0)",
- "format": "time_series",
- "hide": false,
- "instant": true,
- "interval": "",
- "intervalFactor": 1,
- "legendFormat": "",
- "refId": "A"
- }
- ],
- "title": " <10 Copies ",
- "type": "stat"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Total number of volumes whose snapshot count is between 10 to 100.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "noValue": "0",
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "rgb(31, 176, 196)",
- "value": null
- }
- ]
- },
- "unit": "short"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 5,
- "w": 6,
- "x": 6,
- "y": 2
- },
- "id": 97,
- "links": [],
- "options": {
- "colorMode": "value",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "horizontal",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {},
- "textMode": "auto"
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} >= 10 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} <= 100)) OR on() vector(0)",
- "format": "time_series",
- "hide": false,
- "instant": true,
- "interval": "",
- "intervalFactor": 1,
- "legendFormat": "",
- "refId": "A"
- }
- ],
- "title": "10-100 Copies",
- "type": "stat"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Total number of volumes whose snapshot count is between 101 to 500.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "noValue": "0",
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "rgb(31, 176, 196)",
- "value": null
- }
- ]
- },
- "unit": "short"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 5,
- "w": 6,
- "x": 12,
- "y": 2
- },
- "id": 98,
- "links": [],
- "options": {
- "colorMode": "value",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "horizontal",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {},
- "textMode": "auto"
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 100 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} <= 500)) OR on() vector(0)",
- "format": "time_series",
- "hide": false,
- "instant": true,
- "interval": "",
- "intervalFactor": 1,
- "legendFormat": "",
- "refId": "A"
- }
- ],
- "title": "101-500 Copies",
- "type": "stat"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "Total number of volumes whose snapshot count is > 500.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "noValue": "0",
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "rgb(31, 176, 196)",
- "value": null
- }
- ]
- },
- "unit": "short"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 5,
- "w": 6,
- "x": 18,
- "y": 2
- },
- "id": 99,
- "links": [],
- "options": {
- "colorMode": "value",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "horizontal",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {},
- "textMode": "auto"
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 500)) OR on() vector(0)",
- "format": "time_series",
- "hide": false,
- "instant": true,
- "interval": "",
- "intervalFactor": 1,
- "legendFormat": "",
- "refId": "A"
- }
- ],
- "title": ">500 Copies",
- "type": "stat"
- },
- {
- "datasource": "${DS_PROMETHEUS}",
- "description": "This panel displays volumes detail with snapshot count.",
- "fieldConfig": {
- "defaults": {
- "color": {
- "fixedColor": "transparent",
- "mode": "fixed"
- },
- "custom": {
- "align": "left",
- "displayMode": "auto",
- "filterable": true
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- }
- ]
- }
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "Bucket"
- },
- "properties": [
- {
- "id": "custom.filterable",
- "value": true
- },
- {
- "id": "mappings",
- "value": [
- {
- "options": {
- "from": 0,
- "result": {
- "index": 0,
- "text": "< 10 Copies"
- },
- "to": 9
- },
- "type": "range"
- },
- {
- "options": {
- "from": 10,
- "result": {
- "index": 1,
- "text": "10-100 Copies"
- },
- "to": 100
- },
- "type": "range"
- },
- {
- "options": {
- "from": 101,
- "result": {
- "index": 2,
- "text": "101-500 Copies"
- },
- "to": 500
- },
- "type": "range"
- },
- {
- "options": {
- "from": 501,
- "result": {
- "index": 3,
- "text": "> 500 Copies"
- },
- "to": 1e+24
- },
- "type": "range"
- }
- ]
- },
- {
- "id": "custom.width",
- "value": 290
- },
- {
- "id": "displayName",
- "value": "Snapshot Copies Bucket"
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "volume"
- },
- "properties": [
- {
- "id": "displayName",
- "value": "Volume"
- },
- {
- "id": "custom.width",
- "value": 500
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "",
- "url": "/d/cdot-volume/ontap-volume?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-Volume=${__value.raw}"
- }
- ]
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "svm"
- },
- "properties": [
- {
- "id": "displayName",
- "value": "SVM"
- },
- {
- "id": "custom.width",
- "value": 500
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "",
- "url": "/d/cdot-svm/ontap-svm?orgId=1&${Datacenter:queryparam}&${Cluster:queryparam}&${__url_time_range}&var-SVM=${__value.raw}"
- }
- ]
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Snapshot Copies"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 260
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "cluster"
- },
- "properties": [
- {
- "id": "displayName",
- "value": "Cluster"
- },
- {
- "id": "custom.width",
- "value": 400
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "",
- "url": "/d/cdot-cluster/ontap-cluster?orgId=1&${Datacenter:queryparam}&${__url_time_range}&var-Cluster=${__value.raw}"
- }
- ]
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 15,
- "w": 24,
- "x": 0,
- "y": 7
- },
- "id": 94,
- "options": {
- "footer": {
- "fields": "",
- "reducer": [
- "sum"
- ],
- "show": false
- },
- "showHeader": true,
- "sortBy": []
- },
- "pluginVersion": "8.4.11",
- "targets": [
- {
- "exemplar": false,
- "expr": "(volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 0)",
- "format": "table",
- "instant": true,
- "interval": "",
- "legendFormat": "",
- "refId": "A"
- }
- ],
- "title": "Volume count by the number of Snapshot copies",
- "transformations": [
- {
- "id": "filterFieldsByName",
- "options": {
- "include": {
- "names": [
- "svm",
- "volume",
- "Value",
- "cluster"
- ]
- }
- }
- },
- {
- "id": "organize",
- "options": {
- "excludeByName": {},
- "indexByName": {
- "Value": 3,
- "cluster": 2,
- "svm": 1,
- "volume": 0
- },
- "renameByName": {
- "Value": "Snapshot Copies",
- "volume": ""
- }
- }
- },
- {
- "id": "calculateField",
- "options": {
- "alias": "Bucket",
- "mode": "reduceRow",
- "reduce": {
- "include": [
- "Snapshot Copies"
- ],
- "reducer": "last"
- }
- }
- }
- ],
- "type": "table"
- }
- ],
- "title": "Snapshot Copies Analysis",
- "type": "row"
- }
- ],
- "refresh": "",
- "schemaVersion": 30,
- "style": "dark",
- "tags": [
- "harvest",
- "ontap",
- "cdot",
- "fsx"
- ],
- "templating": {
- "list": [
- {
- "current": {
- "selected": false,
- "text": "Prometheus",
- "value": "Prometheus"
- },
- "description": null,
- "error": null,
- "hide": 2,
- "includeAll": false,
- "label": "Data Source",
- "multi": false,
- "name": "DS_PROMETHEUS",
- "options": [],
- "query": "prometheus",
- "refresh": 2,
- "regex": "",
- "skipUrlSync": false,
- "type": "datasource"
- },
- {
- "allValue": null,
- "current": {
- "selected": false,
- "text": "DC-01",
- "value": "DC-01"
- },
- "datasource": "${DS_PROMETHEUS}",
- "definition": "label_values(cluster_new_status{system_type!=\"7mode\"},datacenter)",
- "description": null,
- "error": null,
- "hide": 0,
- "includeAll": false,
- "label": null,
- "multi": true,
- "name": "Datacenter",
- "options": [],
- "query": {
- "query": "label_values(cluster_new_status{system_type!=\"7mode\"},datacenter)",
- "refId": "StandardVariableQuery"
- },
- "refresh": 2,
- "regex": "",
- "skipUrlSync": false,
- "sort": 1,
- "tagValuesQuery": "",
- "tagsQuery": "",
- "type": "query",
- "useTags": false
- },
- {
- "allValue": ".*",
- "current": {},
- "datasource": "${DS_PROMETHEUS}",
- "definition": "label_values(cluster_new_status{system_type!=\"7mode\",datacenter=~\"$Datacenter\"},cluster)",
- "description": null,
- "error": null,
- "hide": 0,
- "includeAll": true,
- "label": null,
- "multi": true,
- "name": "Cluster",
- "options": [],
- "query": {
- "query": "label_values(cluster_new_status{system_type!=\"7mode\",datacenter=~\"$Datacenter\"},cluster)",
- "refId": "StandardVariableQuery"
- },
- "refresh": 2,
- "regex": "",
- "skipUrlSync": false,
- "sort": 1,
- "tagValuesQuery": "",
- "tagsQuery": "",
- "type": "query",
- "useTags": false
- }
- ]
- },
- "time": {
- "from": "now-3h",
- "to": "now"
- },
- "timepicker": {
- "refresh_intervals": [
- "10s",
- "30s",
- "1m",
- "5m",
- "15m",
- "30m",
- "1h",
- "2h",
- "1d"
- ]
- },
- "timezone": "",
- "title": "ONTAP: Data Protection Snapshots",
- "uid": "cdot-data-protection-snapshots",
- "version": 2
-}
diff --git a/grafana/dashboards/cmode/datacenter.json b/grafana/dashboards/cmode/datacenter.json
index 2c4d60d57..f6a793bc4 100644
--- a/grafana/dashboards/cmode/datacenter.json
+++ b/grafana/dashboards/cmode/datacenter.json
@@ -2980,7 +2980,7 @@
"targets": [
{
"exemplar": false,
- "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{})) OR on() vector(0)",
+ "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{})) OR on() vector(0)",
"instant": true,
"interval": "",
"legendFormat": "Volumes protected",
@@ -2988,7 +2988,7 @@
},
{
"exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy=~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{}))) OR on() vector(0)",
+ "expr": "count((volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy=~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{}))) OR on() vector(0)",
"hide": false,
"instant": true,
"interval": "",
@@ -3083,7 +3083,7 @@
"targets": [
{
"exemplar": false,
- "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} > volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"})) OR on() vector(0)",
+ "expr": "count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} > volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"})) OR on() vector(0)",
"instant": true,
"interval": "",
"legendFormat": "Volumes breached",
@@ -3091,7 +3091,7 @@
},
{
"exemplar": false,
- "expr": "(count((volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{})) * on (volume, svm, cluster) group_right() (volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} <= volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"})) OR on() vector(0)) + (count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} == 0)) OR on() vector(0))",
+ "expr": "(count((volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{})) * on (volume, svm, cluster) group_right() (volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} <= volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"})) OR on() vector(0)) + (count(volume_labels{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{}) * on (volume, svm, cluster) group_right() ( volume_snapshot_reserve_size{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} >= 0 and volume_snapshots_size_used{datacenter=~\"$Datacenter\", cluster=~\"$Cluster\"} == 0)) OR on() vector(0))",
"instant": true,
"interval": "",
"legendFormat": "Volumes not breached",
@@ -3185,7 +3185,7 @@
"targets": [
{
"exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 0 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} < 10)) OR on() vector(0)",
+ "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 0 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} < 10)) OR on() vector(0)",
"instant": true,
"interval": "",
"legendFormat": " <10 Copies ",
@@ -3193,7 +3193,7 @@
},
{
"exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} >= 10 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} <= 100)) OR on() vector(0)",
+ "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} >= 10 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} <= 100)) OR on() vector(0)",
"instant": true,
"interval": "",
"legendFormat": "10-100 Copies",
@@ -3201,7 +3201,7 @@
},
{
"exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 100 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} <= 500)) OR on() vector(0)",
+ "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 100 and volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} <= 500)) OR on() vector(0)",
"hide": false,
"instant": true,
"interval": "",
@@ -3210,7 +3210,7 @@
},
{
"exemplar": false,
- "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_total_schedules{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 500)) OR on() vector(0)",
+ "expr": "count((volume_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\",snapshot_policy!=\"\", snapshot_policy!~\"none.*\", volume!~\"MDV.*\"} * on (snapshot_policy) group_left () group by (snapshot_policy) (snapshot_policy_labels{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"})) * on (volume,svm,cluster) (volume_snapshot_count{datacenter=~\"$Datacenter\",cluster=~\"$Cluster\"} > 500)) OR on() vector(0)",
"hide": false,
"instant": true,
"interval": "",
diff --git a/integration/test/dashboard_json_test.go b/integration/test/dashboard_json_test.go
index fe23a2237..847a1ee7d 100644
--- a/integration/test/dashboard_json_test.go
+++ b/integration/test/dashboard_json_test.go
@@ -50,6 +50,8 @@ var zapiCounterMap = map[string]struct{}{
"aggr_object_store_logical_used": {},
"aggr_object_store_physical_used": {},
"fru_status": {},
+ "snapshot_policy_labels": {},
+ "cluster_schedule_labels": {},
}
// restCounterMap are additional counters, above and beyond the ones from counterMap, which should be excluded from Rest
@@ -57,7 +59,7 @@ var restCounterMap = map[string]struct{}{
"aggr_snapshot_inode_used_percent": {},
"flexcache_": {},
"rw_ctx_": {},
- "snapshot_policy_total_schedules": {},
+ "snapshot_policy_labels": {},
"support_labels": {},
}
diff --git a/integration/test/dashboard_test.go b/integration/test/dashboard_test.go
index bb3deec5d..cd62684e6 100644
--- a/integration/test/dashboard_test.go
+++ b/integration/test/dashboard_test.go
@@ -79,7 +79,7 @@ func TestCModeDashboardCount(t *testing.T) {
"ONTAP: SVM",
"ONTAP: Volume",
"ONTAP: MetroCluster",
- "ONTAP: Data Protection Snapshots",
+ "ONTAP: Data Protection",
"ONTAP: Qtree",
"ONTAP: Security",
"ONTAP: Power",