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

Already on GitHub? Sign in to your account

_pm_ispartition() heulistic miss some block devices #45

Open
moriwaka opened this Issue Aug 26, 2015 · 4 comments

Comments

Projects
None yet
2 participants
Contributor

moriwaka commented Aug 26, 2015

In src/pmdas/linux/proc_partitions.c, _pm_ispartition() use heulistic to detect partitions, but this misses some block devices like "sr0", "scd0", "fd0" etc.
I suggest using sysfs. /sys/block/* listing all block devices.

Thanks,

Contributor

natoscott commented Aug 27, 2015

I believe this was done purposefully, because floppy disk, CDROM, and DVD devices are not typically of interest in general purpose performance analysis tools. Do you have a need for the per-partition values from those devices?

Contributor

moriwaka commented Aug 27, 2015

I noticed this by difference of pmiostat and iostat outputs. I agree with you, CD,DVD,FDs are not interested in almost all use case. To now, I don't have real needs nor problems.

I thought that new devices' or some special drivers' naming rules are uncontrollable. And proper block device detection method can be help for minor devices and users.

Thanks,

Contributor

natoscott commented Aug 27, 2015

I thought that new devices' or some special drivers' naming rules are uncontrollable.
And proper block device detection method can be help for minor devices and users.

Yes, this could certainly be done and would be an improvement I think. We would need to ensure the current code remains though, as it will need to run on older kernels lacking sysfs support. Would you be interested in sending through a patch?

Contributor

moriwaka commented Aug 27, 2015

Yes, I'll try to make a patch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment