1

My rpi is using a SD card with 64GB which is showing the following space available when I use df -h command:

Filesystem      Size  Used Avail Use% Mounted on
/dev/root        59G   56G   79M 100% /
devtmpfs        182M     0  182M   0% /dev
tmpfs            38M  212K   37M   1% /run
tmpfs           5.0M     0  5.0M   0% /run/lock
tmpfs            75M     0   75M   0% /run/shm
/dev/mmcblk0p1   56M   22M   35M  38% /boot
none            186M     0  186M   0% /sys/fs/cgroup

I was expecting to have 3GB available (or the whole 59GB used). Can anyone tell me what happened to the 3GB? Do I have to run a disk check for errors to retrieve the 3GB?

1
  • It's not necessarily errors that fill up the disk. The cache of the package manager is also is very fruitful source.
    – Ghanima
    Jul 26, 2016 at 17:27

1 Answer 1

2

This is the 5% file system overhead reserved for root. This percentage may be tuned, but normally it is not advisable as the overhead is needed for the system to function properly. My advise is to consider moving some of your data to a network or USB disk.

3
  • Hum, did not know that! This is a default value for linux or for raspberry pi? Do you have any link/material to share about this? Thanks!
    – Vini.g.fer
    Jul 26, 2016 at 18:03
  • 1
    It's for the filesystem type (ext4). The reason for this is, as jogco implies, to prevent non-privileged processes from filling a root fs arbitrarily, at which point the system will cease to function properly (the assumption is that privileged processes are managed responsibly, although Raspbian's by default over-privileged pi user largely negates this allowing you to shoot both your feet off if you want). See also unix.stackexchange.com/q/7950/25985 and note carefully when T.T. refers to "won't matter" he is not talking about a root filesystem.
    – goldilocks
    Jul 26, 2016 at 18:12
  • @goldilocks, excellent link, sums it up quite nicely!
    – jogco
    Jul 26, 2016 at 18:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.