** Description changed: - Kernel change introducing the diskstat format field add: + ## DRAFT ### + + [Impact] + With v4.19, Linux gained extra fields in /proc/diskstats: https://github.com/torvalds/linux/commit/bdca3c87fb7ad1cc61d231d37eb0d8f90d001e0c + + [Test Case] + + * Follow the procedure here: + https://collectd.org/wiki/index.php/First_steps + + and make sure disk plugin is working with let's say v4.15, then move to + >5.0 and graph will stop working, because current collectd is expecting + a precise total of fields (14), but it is now 18: + + 15 - discards completed successfully + 16 - discards merged + 17 - sectors discarded + 18 - time spent discarding + + [Regression Potential] + + [Other Informations] Upstream bug & fix: https://github.com/collectd/collectd/issues/2951 https://github.com/collectd/collectd/commit/6ce52f70cc1e6450df3454f19743a29295b84050 https://github.com/collectd/collectd/commit/42f8dc033f5009dda7202ceee97e57bbbedf6fc3 $ git describe --contains 6ce52f70cc1e6450df3454f19743a29295b84050 collectd-5.8.1~3 - => collectd | 5.7.2-2ubuntu1.1 | bionic-updates/universe - collectd | 5.8.1-1.3ubuntu1 | eoan/universe - collectd | 5.9.2.g-1ubuntu4 | focal/universe - - *Expected behavior: - The disk plugin should export stats as it has done in the past - - *Actual behavior: - No disk stats are exported at all - - * Steps to reproduce - Run any of the 4.19-rc Linux kernels and probably any recent collectd version - Cause - With 4.19, Linux gained extra fields in /proc/diskstats, indicating r/w stats for Discard operations on SSDs. From linux/Documentation/iostats.txt: - - Field 12 -- # of discards completed - This is the total number of discards completed successfully. - - Field 13 -- # of discards merged - See the description of field 2 - - Field 14 -- # of sectors discarded - This is the total number of sectors discarded successfully. - - Field 15 -- # of milliseconds spent discarding - This is the total number of milliseconds spent by all discards (as - measured from __make_request() to end_that_request_last()). - Collectd simply quits parsing if the number of fields is not exactly what it expects. I think that may be overly conservative, since the nuber of fields usually only gets added to, without rearrangement of existing fields. - - I recommend making the checks for field numbers not X!=10 but X<10, that - way, we don't lose stats in these cases, and can take time to implement - parsing out extra stats if and when 4.19 becomes stable. + => collectd | 5.7.2-2ubuntu1.1 | bionic-updates/universe + collectd | 5.8.1-1.3ubuntu1 | eoan/universe + collectd | 5.9.2.g-1ubuntu4 | focal/universe
** Description changed: ## DRAFT ### [Impact] With v4.19, Linux gained extra fields in /proc/diskstats: https://github.com/torvalds/linux/commit/bdca3c87fb7ad1cc61d231d37eb0d8f90d001e0c [Test Case] * Follow the procedure here: https://collectd.org/wiki/index.php/First_steps and make sure disk plugin is working with let's say v4.15, then move to >5.0 and graph will stop working, because current collectd is expecting a precise total of fields (14), but it is now 18: 15 - discards completed successfully 16 - discards merged 17 - sectors discarded 18 - time spent discarding + + $ uname -r + 4.18.0-25-generic + + $ awk '{ print NF }' /proc/diskstats + 14 + + ----- + + $ uname -r + 5.0.0-41-generic + + $ awk '{ print NF }' /proc/diskstats + 18 + [Regression Potential] [Other Informations] Upstream bug & fix: https://github.com/collectd/collectd/issues/2951 https://github.com/collectd/collectd/commit/6ce52f70cc1e6450df3454f19743a29295b84050 https://github.com/collectd/collectd/commit/42f8dc033f5009dda7202ceee97e57bbbedf6fc3 $ git describe --contains 6ce52f70cc1e6450df3454f19743a29295b84050 collectd-5.8.1~3 - => collectd | 5.7.2-2ubuntu1.1 | bionic-updates/universe - collectd | 5.8.1-1.3ubuntu1 | eoan/universe - collectd | 5.9.2.g-1ubuntu4 | focal/universe + => collectd | 5.7.2-2ubuntu1.1 | bionic-updates/universe + collectd | 5.8.1-1.3ubuntu1 | eoan/universe + collectd | 5.9.2.g-1ubuntu4 | focal/universe -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1865895 Title: /proc/diskstats format changes in kernel v4.19 To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/collectd/+bug/1865895/+subscriptions -- ubuntu-bugs mailing list [email protected] https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
