Skip to content

Commit

Permalink
Add standard EC setting to admin info
Browse files Browse the repository at this point in the history
Discretely adds the standard EC setting to regular `mc admin info`.

```
λ mc admin info play
●  play.min.io
   Uptime: 1 hour
   Version: 2024-04-15T10:03:01Z
   Network: 1/1 OK
   Drives: 4/4 OK
   Pool: 1

Pools:
   1st, Erasure sets: 1, Drives per erasure set: 4

945 MiB Used, 409 Buckets, 5,498 Objects, 52 Versions, 4 Delete Markers
4 drives online, 0 drives offline, EC:2
```

Will save many deep dives into JSON.
  • Loading branch information
klauspost committed May 2, 2024
1 parent dcb911b commit a47f7b6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions cmd/admin-info.go
Original file line number Diff line number Diff line change
Expand Up @@ -296,9 +296,10 @@ func (u clusterStruct) String() (msg string) {
}
// Summary on total no of online and total
// number of offline drives at the Cluster level
msg += fmt.Sprintf("%s online, %s offline\n",
msg += fmt.Sprintf("%s online, %s offline, EC:%d\n",
english.Plural(u.Info.Backend.OnlineDisks, "drive", ""),
english.Plural(u.Info.Backend.OfflineDisks, "drive", ""))
english.Plural(u.Info.Backend.OfflineDisks, "drive", ""),
u.Info.Backend.StandardSCParity)
}

// Remove the last new line if any
Expand Down

0 comments on commit a47f7b6

Please sign in to comment.