mirror of
https://github.com/bcicen/ctop.git
synced 2025-12-06 15:16:41 +08:00
aggregate io r/w across all reported stats volumes
This commit is contained in:
@@ -114,10 +114,10 @@ func (c *Docker) ReadIO(stats *api.Stats) {
|
||||
var read, write int64
|
||||
for _, blk := range stats.BlkioStats.IOServiceBytesRecursive {
|
||||
if blk.Op == "Read" {
|
||||
read = int64(blk.Value)
|
||||
read += int64(blk.Value)
|
||||
}
|
||||
if blk.Op == "Write" {
|
||||
write = int64(blk.Value)
|
||||
write += int64(blk.Value)
|
||||
}
|
||||
}
|
||||
c.IOBytesRead, c.IOBytesWrite = read, write
|
||||
|
||||
Reference in New Issue
Block a user