I use GParted as the main GUI when I want see globally stats about disk space for a HD/SSD. It externally (boot through ventoy) or even within the same OS itself.
parted isn’t just “cli” - if you run it as is - you enter an interactive TTY style “shell” - it’s not really a proper “tui” (i.e. not a TUI like nmtui)… I think it defaults to the device you run it from (e.g. on my Pop!_OS it’s /dev/mapper/cryptdata).
I have maybe used it 3-4 times in my whole career… I think I had to use it once 'cause fdisk couldn’t handle something on the block device partition table…
But I hardly ever partition disks manually - on desktop machines with a DE I usually let the installer take care of partitioning to the vendor defaults - mostly happy to accept Ubuntu and Pop!_OS defaults (but kinda hate Fedora’s!)… I also never dual boot (at least not for a while) so most of my Linux systems have a single “/” that hosts everything (e.g. /var, /home)…
So far it is the unique suggested tool tested because you included a Figure of the output. I think it is the best for the terminal about presentation. Of course according with my requirement. I tested but is strange the following:
Because the Linux server is installed through VirtualBox it is stored in a .vdi file. It was created with a size of 50GB. Therefore the “fake” HDD/SSD has only 50GB. When the du command is executed it shows the same structure data. But in none place appears the 50GB.
In other words if in your side your SSD is 500GB or 1TB in your report shared where appears that global data? It including the space already used and available. Therefore as a global report.
If you execute internally GParted as GUI of course, it shows all the partitions as expected but globally it shows the full capacity of the HDD/SSD itself. And if my memory does not fail the used and available space too.
I am assuming would be there an option in the command itself. It seems not (see man duf). But because you already have experience with the command perhaps you already know how to get that global report
I think duf will be like df … they only report on partitions that are mounted… they do not know about disks, only partitions, so they cant do a global report for a disc.
They also will not see unmounted partitions… you could fix that by mounting every partition, but that would produce some clutter.
Yes, gparted, or parted, or gnome-disks.
Only parted is tui.
I think also fdisk, but I will have to check.
It would be possible to write a script that finds all the partitions, temporarily mounts them all, does df or duf, then sorts the result into disks. … Want to try?
The basic information is in /dev/disk (may be /dev/disks, cant remember)
Yes, gparted, or parted, or gnome-disks.
Only parted is tui.
I think also fdisk, but I will have to check.
In that case I will to do a research for parted
It would be possible to write a script that finds all the partitions, temporarily mounts them all, does df or duf, then sorts the result into disks. … Want to try?
Wondered why so far there is no a command to accomplish that goal. Due lack of time I will pass/avoid to create a script file. The command should be portable among some distros too. So resolve this case through scripts is other history
The basic information is in /dev/disk (may be /dev/disks, cant remember)
I understand. I will check it
The commands shared - for reporting of partitions work fine - it with or without TUI.
But is interesting how the global report of the complete disk is not straightforward
Your observations are correct. I just checked on my system, on which I started my virtual machine Arch Linux using KVM/qemu.
The duf utility doesn’t directly show the space used by virtual machine disk images as part of the overall disk usage in its default output.
Note: For the following I´m taking my qcow2 file for Arch Linux as an example:
However:
you can provide the filepath to the VM file as an argument to duf for showing the
usage of the entire filesystem where the .qcow2 file is stored, not the specific usage of the virtual machine disk image itself.
The output I´m getting from duf -all that shows /run/qemu is a temporary filesystem (tmpfs) used by QEMU for runtime operations, but it doesn’t represent the actual disk usage of your virtual machine images
Therefore the 4 commands must be used together to have a complete picture or better understanding
duf
fdisk -l
lsblk
lsblk |grep -v loop
I am giving the solution to @Rosika because the duf command has the expected TUI (but with the constraint of the global report) …
Why I requested the solution with TUI? It because even when the fdisk and lsblk commands are very valuable … in some point of the day when the brain is very tired this kind of report is much better with a kind of graphical presentation. Thus duf is valuable. Again the set of commands shown above do the complete job.
Pls see again the 3 pictures shown above to do a comparison with GParted as follows:
That key icon indicates that the partition you are trying to modify is currently under use. In order to modify that/those partition/s you have to boot up from a live CD. Then you will be able to modify those partitions. But, be sure to backup your data as it can lead to data loss. But this case is very rare.
Is strange the answer of the other network because the Figures shared by my side are Live CD/DVD and thus the OS itself is not running. I think there is something missing there