Public bug reported:
Ubuntu release: jammy
Package version: libgtop-2.0-11 2.40.0-2build3
Kernel version: 5.15.0-76-generic
Situation: An encrypted partition (root in this case) is mounted on
/dev/mapper/cryptroot .
/dev/mapper/cryptroot is actually a symlink to ../dm-0 , i.e. /dev/dm-0 .
Expected behaviour:
glibtop_get_fsusage(&fsusage, "/")
should return correct read/write statistics for the partition (i.e.
fsusage.read and fusage.write).
Observed behaviour:
fsusage.read and fusage.write are incorrectly returned as zero.
I have tried to further track down the problem.
linux_2_6_0() in sysdeps/linux/fsusage.c calls
get_device() which checks the table of mounted filesystems and returns
"mapper/cryptroot", referring to /dev/mapper/cryptroot .
get_sys_path() then turns this into the incorrect sys file path
"/sys/block/mapper/cryptroot/stat".
It should be "/sys/block/dm-0/stat".
Proposed solution: get_sys_path() should check if the device file is a symlink
and if so, dereference it before using it as a device name.
** Affects: libgtop2 (Ubuntu)
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Desktop
Packages, which is subscribed to libgtop2 in Ubuntu.
https://bugs.launchpad.net/bugs/2025476
Title:
glibtop_get_fsusage() read/write stats not working on encrypted
partition
Status in libgtop2 package in Ubuntu:
New
Bug description:
Ubuntu release: jammy
Package version: libgtop-2.0-11 2.40.0-2build3
Kernel version: 5.15.0-76-generic
Situation: An encrypted partition (root in this case) is mounted on
/dev/mapper/cryptroot .
/dev/mapper/cryptroot is actually a symlink to ../dm-0 , i.e. /dev/dm-0 .
Expected behaviour:
glibtop_get_fsusage(&fsusage, "/")
should return correct read/write statistics for the partition (i.e.
fsusage.read and fusage.write).
Observed behaviour:
fsusage.read and fusage.write are incorrectly returned as zero.
I have tried to further track down the problem.
linux_2_6_0() in sysdeps/linux/fsusage.c calls
get_device() which checks the table of mounted filesystems and returns
"mapper/cryptroot", referring to /dev/mapper/cryptroot .
get_sys_path() then turns this into the incorrect sys file path
"/sys/block/mapper/cryptroot/stat".
It should be "/sys/block/dm-0/stat".
Proposed solution: get_sys_path() should check if the device file is a
symlink and if so, dereference it before using it as a device name.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/libgtop2/+bug/2025476/+subscriptions
--
Mailing list: https://launchpad.net/~desktop-packages
Post to : [email protected]
Unsubscribe : https://launchpad.net/~desktop-packages
More help : https://help.launchpad.net/ListHelp