Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Differentiate between partitions and devices using sysfs #1312

Closed
wants to merge 1 commit into from

Conversation

wiggin15
Copy link
Collaborator

disk_io_counters skips devices that have partitions, and to differentiate partitions from devices we can't use the names - we need to look in sysfs.
Partitions and devices have entries in /sys/class/block and only devices have entries in /sys/block.
This should fix issues #1244 and #1305.
Also fixed looking up the sector size of partitions.

disk_io_counters skips devices that have partitions,
and to differentiate partitions from devices we can't
use the names - we need to look in sysfs.
Partitions and devices have entries in /sys/class/block
and only devices have entries in /sys/block
This fixes counters of NVMe devices.
Also fixed looking up the sector size of partitions.
@wiggin15
Copy link
Collaborator Author

Closed in favor of #1313.

@wiggin15 wiggin15 closed this Jul 28, 2018
giampaolo added a commit that referenced this pull request Jul 28, 2018
Fix #1244, #1305, #1312. disk_io_counters(perdisk=False) on Linux was counting disk device + partitions(s) twice
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant