Skip to content
New issue

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

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

info reports wrong disk numbers for core-based instances #1245

Closed
ricab opened this issue Dec 18, 2019 · 0 comments · Fixed by #2974
Closed

info reports wrong disk numbers for core-based instances #1245

ricab opened this issue Dec 18, 2019 · 0 comments · Fixed by #2974
Assignees
Labels
bug medium medium importance
Milestone

Comments

@ricab
Copy link
Collaborator

ricab commented Dec 18, 2019

$ multipass info zealous-cusk firm-harrier | egrep -i "name|release|disk"
Name:           firm-harrier
Release:        Core 18
Disk usage:     54,6M out of 54,6M
Name:           zealous-cusk
Release:        Core 16
Disk usage:     89,1M out of 89,1M

These values are being obtained from df for /:

ubuntu@firm-harrier:~$ df -h /
Filesystem      Size  Used Avail Use% Mounted on
/dev/loop0       55M   55M     0 100% /

However, things are actually in /writable:

ricab@ricab-xps13:~ $ multipass exec firm-harrier -- df -h /writable
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda3       4.9G  560M  4.1G  12% /writable
ricab@ricab-xps13:~ $ multipass exec firm-harrier -- fallocate -l 1G test
ricab@ricab-xps13:~ $ multipass exec firm-harrier -- df -h /writable
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda3       4.9G  1.6G  3.1G  34% /writable
@Saviq Saviq added bug medium medium importance labels Dec 19, 2019
@sharder996 sharder996 self-assigned this Mar 17, 2023
@sharder996 sharder996 added this to the 1.12.0 milestone Mar 17, 2023
bors bot added a commit that referenced this issue Mar 22, 2023
2974: [daemon] Edit disk usage info r=townsend2010 a=sharder996

Edit how disk usage is gotten so that it outputs the correct in core instance as well as regular ubuntu images. The command now takes the output from `fdisk -l` and courses references the devices found in `df`. Instead of returning the size of the root directory, `/`, the device marked as `Linux filesystem` in `dfisk` will be taken from `df`.

Fixes #1245

Co-authored-by: sharder996 <sharder996@gmail.com>
@bors bors bot closed this as completed in 29156dc Mar 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug medium medium importance
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants