Bug 2029093

Summary: virt-manager reports more free space than is available for storage pool
Product: [Fedora] Fedora Reporter: Maki Oyo <shellgame13>
Component: virt-managerAssignee: Cole Robinson <crobinso>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 35CC: berrange, crobinso, philip.wyett
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: ---
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-12-06 10:41:28 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Maki Oyo 2021-12-04 22:33:12 UTC
Description of problem:

The free space reported on the storage pool management screen does not agree with actual free space.

On my root partition, virt-manger reports 5GiB free, while `df` reports about 2GiB free.
On my data drive, virt-manger reports 62.7GiB free, while `df` reports about 17GiB free.

Version-Release number of selected component (if applicable):
libvirt-7.6.0-3.fc35.x86_64
virt-manager-3.2.0-4.fc35.noarch


How reproducible:
Always 

Expected results:
reported space should either match what command line tools report, or an explanation for the discrepancy should be part of the UI.

Additional info:
Similar report in BZ855533 (closed) 8 years ago, and never addressed.

Comment 1 Maki Oyo 2021-12-06 10:40:38 UTC
virt-manager simply shows what libvirtd reports, so it's not a bug in virt-manager.

libvirtd reports the storage available to the superuser, which includes 
the usual free space on the filesystem as well as the space reserved 
for the superuser when the filesystem was created. By default, that's 5%.
You can inspect this with tune2fs:

# sudo tune2fs -l <device> | grep -P "Block size:|Reserved block count"    
Reserved block count:     655360
Block size:               4096

That seems like the wrong thing, especially since libvirtd runs as qemu, that space probably
isn't available. But I'll open a new BZ for that.

Comment 2 Maki Oyo 2021-12-06 11:01:05 UTC
See BZ2029377