romanodog Posted January 12, 2019 Share Posted January 12, 2019 Hello, I have a 60GB SSD being used as a cache drive. On the main page of the GUI it reports that I am using 42.1 GB: Size Used Free 60GB 42.1GB 17.9GB But du tells me it's only using 33G: du -h -d 1 /mnt/cache 12G /mnt/cache/appdata 0 /mnt/cache/domains 21G /mnt/cache/system 0 /mnt/cache/transcode 33G /mnt/cache None of my shares, except the ones listed above, are set to use the cache drive but I ran the mover manually anyway just in case. Is there a reason that the two don't match? Quote Link to comment
Warrentheo Posted January 12, 2019 Share Posted January 12, 2019 (edited) Unlike Windows, Linux allows files to have a different number for "Space Used" and "Size on Disk"... This is because Linux allows files filled with zeros to have a 40GB size for instance while taking up the space needed to store the file name... Causes some issues for the humans that need to read this stuff sometimes... The files under cache/system especially will have lots of empty space allocated to them, don't worry too much about it... The attached is an list of my libvirt file for instance, see that it shows that the file is both 205M and 2.0G at the same time...? The little meter bar on the "Main" page for UnRaid tends to show disk free space just fine... /mnt/cache/system/libvirt# ls -lhsa total 205M 0 drwxrwxrwx 1 root root 22 Mar 8 2018 ./ 0 drwxrwxrwx 1 nobody users 322 Nov 9 11:45 ../ 205M -rw-rw-rw- 1 nobody users 2.0G Jan 11 16:10 libvirt.img Edited January 12, 2019 by Warrentheo Quote Link to comment
Warrentheo Posted January 12, 2019 Share Posted January 12, 2019 On a related note, if you have a large file that takes up lots of space, but you know most of it is zeros (most hard drive image file backups for instance) you can use the fallocate -d command on it, and Linux will go through and un-map all the space that currently stores nothing but zeros from it, had it free up a bunch of hard drive space on some of my VM backups... Just be careful with the command, it can easily accidentally delete files... Quote Link to comment
JorgeB Posted January 12, 2019 Share Posted January 12, 2019 That can happen, especially when sparse files are present, the used space on the GUI is the correct one and the one you should pay attention to. Quote Link to comment
romanodog Posted January 13, 2019 Author Share Posted January 13, 2019 Thank you guys so much for the responses. If I wanted to try to clear out some space, how would I go about finding the large files that are taking up the most space? My docker image is set to 20gb and my libvirt.img is 1gb so I'm assuming the system folder is ok. My appdata is reporting 12g but that must be inflated on the main view? Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.