Merge pull request #120 from alram/luminous
health: adds unclean PGs for luminous
This commit is contained in:
commit
41bf098e2b
|
@ -989,6 +989,14 @@ func (c *ClusterHealthCollector) collect(ch chan<- prometheus.Metric) error {
|
|||
}
|
||||
c.DegradedObjectsCount.Set(float64(v))
|
||||
}
|
||||
matched = uncleanRegex.FindStringSubmatch(check.Summary.Message)
|
||||
if len(matched) == 2 {
|
||||
v, err := strconv.Atoi(matched[1])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
c.UncleanPGs.Set(float64(v))
|
||||
}
|
||||
}
|
||||
|
||||
if k == "OBJECT_MISPLACED" {
|
||||
|
|
|
@ -473,6 +473,7 @@ $ sudo ceph -s
|
|||
}`,
|
||||
regexes: []*regexp.Regexp{
|
||||
regexp.MustCompile(`degraded_objects{cluster="ceph"} 1.54443937e\+08`),
|
||||
regexp.MustCompile(`unclean_pgs{cluster="ceph"} 4886`),
|
||||
},
|
||||
},
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue