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

incorrect information wrt used and free: #240

Open
MangoIV opened this issue Apr 13, 2023 · 6 comments
Open

incorrect information wrt used and free: #240

MangoIV opened this issue Apr 13, 2023 · 6 comments

Comments

@MangoIV
Copy link

MangoIV commented Apr 13, 2023

duf outputs:

╭───────────────────────────────────────────────────────────────────────────────────────────────╮
│ 3 local devices                                                                               │
├────────────┬────────┬────────┬────────┬───────────────────────────────┬──────┬────────────────┤
│ MOUNTED ON │   SIZE │   USED │  AVAIL │              USE%             │ TYPE │ FILESYSTEM     │
├────────────┼────────┼────────┼────────┼───────────────────────────────┼──────┼────────────────┤
│ /          │ 907.8G │ 487.8G │ 373.8G │ [##########..........]  53.7% │ ext4 │ /dev/vg/root   │
│ /boot      │ 498.7M │ 357.2M │ 141.5M │ [##############......]  71.6% │ vfat │ /dev/nvme0n1p1 │
│ /nix/store │ 907.8G │ 487.8G │ 373.8G │ [##########..........]  53.7% │ ext4 │ /dev/vg/root   │
╰────────────┴────────┴────────┴────────┴───────────────────────────────┴──────┴────────────────╯

as you can see, the used and avail don't sum up to size, they pretty much miss exactly the size of my home folder.

@IGLOU-EU
Copy link
Contributor

IGLOU-EU commented May 8, 2023

Hi @MangoIV
This is probably the reserved blocks on EXT4 filesystem. By default, an ext4 FS reserve 5% of its capacity for special processes.

Used and Avail are rounded value but:
Reserved space: 907.8*5/100=45.39
487.8+373.8+45.39=906.99

@MangoIV
Copy link
Author

MangoIV commented May 9, 2023

Still where's my /home? It's around 60 GB, according to duf, the nix store is all I have in my disk

@IGLOU-EU
Copy link
Contributor

IGLOU-EU commented May 9, 2023

My bad, you are under NixOs.
Send the result of df -h and mount

@MangoIV
Copy link
Author

MangoIV commented May 10, 2023

Filesystem           Size  Used Avail Use% Mounted on
/dev/mapper/vg-root  908G  505G  358G  59% /
tmpfs                6.9G   15M  6.8G   1% /run
devtmpfs             1.4G     0  1.4G   0% /dev
tmpfs                 14G   68M   14G   1% /dev/shm
tmpfs                 14G  456K   14G   1% /run/wrappers
/dev/nvme0n1p1       499M  211M  288M  43% /boot
tmpfs                2.8G   44K  2.8G   1% /run/user/1000
/dev/mapper/vg-root on / type ext4 (rw,relatime)
tmpfs on /run type tmpfs (rw,nosuid,nodev,size=7141100k,nr_inodes=819200,mode=755)
devtmpfs on /dev type devtmpfs (rw,nosuid,size=1428220k,nr_inodes=3567556,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=3,mode=620,ptmxmode=666)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
ramfs on /run/keys type ramfs (rw,nosuid,nodev,relatime,mode=750)
tmpfs on /run/wrappers type tmpfs (rw,nodev,relatime,mode=755)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
/dev/mapper/vg-root on /nix/store type ext4 (ro,relatime)
none on /run/agenix.d type ramfs (rw,nosuid,nodev,relatime,mode=751)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
cgroup2 on /sys/fs/cgroup type cgroup2 (rw,nosuid,nodev,noexec,relatime,nsdelegate,memory_recursiveprot)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
bpf on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
ramfs on /run/credentials/systemd-sysctl.service type ramfs (ro,nosuid,nodev,noexec,relatime,mode=700)
ramfs on /run/credentials/systemd-tmpfiles-setup-dev.service type ramfs (ro,nosuid,nodev,noexec,relatime,mode=700)
/dev/nvme0n1p1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
ramfs on /run/credentials/systemd-tmpfiles-setup.service type ramfs (ro,nosuid,nodev,noexec,relatime,mode=700)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=2856436k,nr_inodes=714109,mode=700,uid=1000,gid=100)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=100)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=100)

@IGLOU-EU
Copy link
Contributor

Thanks.
As you can see, you don't have a /home mount point. So duf can't display it.
You can use the -all option with duf, to see everything, including tmpfs file system.

@MangoIV
Copy link
Author

MangoIV commented May 10, 2023

Do I understand something wrong here?
Afaiu:

  • /nix/store is part of / so it should be only part of what is shown for /, so how can the used and free for them be the same? /nix/store is not the whole /?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants