Reclaim some free space on your server 'with this weird trick' (KVM/Xen/dedi only)
# df -h / Filesystem Size Used Avail Use% Mounted on /dev/sda2 146G 871M 138G 1% /
Applying the setting (replace '/dev/sda2' with your actual partition name):
# tune2fs -m 0 /dev/sda2 tune2fs 1.42.5 (29-Jul-2012) Setting reserved blocks percentage to 0% (0 blocks)
# df -h / Filesystem Size Used Avail Use% Mounted on /dev/sda2 146G 871M 146G 1% /
Instantly 8GB more!
What it's all about:
By default the Ext2/3/4 filesystems are created with a setting to set aside 5% of free space for the root user, not shown in the free space count and not usable by other users and their programs. This is done "just in case", with practically just one scenario in mind: if something goes wrong and your server consumes all its free disk space, the root user could still log in and check logs/crashdumps/etc and generally fix the situation.
Goes without saying that this is not something that happens all that often, so it seems unjustified to keep 5% of free space reserved at all times just for that. Especially considering that while on a 10GB filesystem 5% is just 512MB, on a 160GB disk it's 8GB, and on a 500GB one - around 25GB.
In case the described free space exhaustion scenario actually happens, you could likely use some sort of live rescue system offered by your provider instead to recover by deleting some files. Or if you want to still keep some of the "safety" space, you could set it to 1% instead of 5% by using "tune2fs -m 1".
This all is only for Ext2/3/4, other filesystems such as Btrfs do not have this quirk/feature.