| Summary: | Used space value inconsistent | ||
|---|---|---|---|
| Product: | [Applications] partitionmanager | Reporter: | Justin Zobel <justin> |
| Component: | general | Assignee: | Andrius Štikonas <andrius> |
| Status: | RESOLVED NOT A BUG | ||
| Severity: | normal | ||
| Priority: | NOR | ||
| Version First Reported In: | 24.12.2 | ||
| Target Milestone: | --- | ||
| Platform: | Solus | ||
| OS: | Other | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
|
Description
Justin Zobel
2025-03-04 01:24:52 UTC
Hmm, it uses different sources of data. I don't know which one would be correct in your case. When partition is mounted QStorageInfo from Qt is used (https://doc.qt.io/qt-6/qstorageinfo.html) which under the hood calls statfs64 syscall and asks kernel how much space is used. When partition is unmounted we call btrfs filesystem show --raw and parse that. Presumably the first source is more accurate since it comes from the kernel... The 5.02GB one when mounted would be correct. There was no content in the drive. (In reply to Justin Zobel from comment #2) > The 5.02GB one when mounted would be correct. There was no content in the > drive. Well, that's what we are using when that info is available. But then partition is unmounted, we can't use that. So does sudo btrfs filesystem show --raw show wrong info for you if you run it manually? Unfortunately, that volume is now gone.
On my current system I see in Partition Manager:
125GiB of 472.94GiB
Via BTRFS:
sudo btrfs filesystem show --raw
Label: 'KDELinux' uuid: 50a6d7b1-c8ee-4aeb-b1ce-3b8376e836be
Total devices 1 FS bytes used 126785499136
devid 1 size 507794214912 used 134242893824 path /dev/mapper/root
And those numbers seem to match up, but that partition is mounted.
Anyway, not much we can do in partitionmanager itself here (especially if the btrfs tool was inaccurate). We use better source (kernel info) when it is available... |