2

What are the counter types for /sys/block/$DEVICE/stat?

$ cat /sys/block/sda/stat
8323741 42381356 464031898 19207478  1940738 49062039 408122282 79935459        0 22315734 99172579

Specifically, do they rollover? At what value? The documentation at https://www.kernel.org/doc/Documentation/block/stat.txt only states they are "decimal values".

dialt0ne
  • 3,065
  • 20
  • 27

1 Answers1

2

They are unsigned long integers with a length depending on the platform (32/64 bit). Yes, they can indeed wrap over if the system is very active for very long. You have to consider that when doing any kind of monitoring.

See https://www.kernel.org/doc/Documentation/iostats.txt

Sven
  • 98,649
  • 14
  • 180
  • 226