Filesystem root has X bytes of space remaining

Hello, I keep getting a strange message. Yesterday i got it saying Filesystem root has 64 GB of space remaining [or something like that, i can’t remember the exact number]. Naturally, I’m an idiot so I simply ignored it thinking it was just a wierd bug. Now I log on today and I get a message saying Filesystem root has 0 bytes of space remaining.

Now I’m beginning to worry… I ran df -h and df -i and got this

joshua@joshua-HP-15-Notebook-PC:~$ df -h
Filesystem                         Size  Used Avail Use% Mounted on
udev                               1.7G     0  1.7G   0% /dev
tmpfs                              339M  5.7M  333M   2% /run
/dev/mapper/ubuntu--mate--vg-root  454G  431G  204M 100% /
tmpfs                              1.7G  8.3M  1.7G   1% /dev/shm
tmpfs                              5.0M  4.0K  5.0M   1% /run/lock
tmpfs                              1.7G     0  1.7G   0% /sys/fs/cgroup
/dev/sda2                          473M  136M  313M  31% /boot
/dev/sda1                          508M  4.7M  504M   1% /boot/efi
tmpfs                              339M   44K  339M   1% /run/user/1000

joshua@joshua-HP-15-Notebook-PC:~$ df -i
Filesystem                          Inodes  IUsed    IFree IUse% Mounted on
udev                                427295    576   426719    1% /dev
tmpfs                               432958    828   432130    1% /run
/dev/mapper/ubuntu--mate--vg-root 30236672 815816 29420856    3% /
tmpfs                               432958     28   432930    1% /dev/shm
tmpfs                               432958      6   432952    1% /run/lock
tmpfs                               432958     16   432942    1% /sys/fs/cgroup
/dev/sda2                           124928    381   124547    1% /boot
/dev/sda1                                0      0        0     - /boot/efi
tmpfs                               432958     23   432935    1% /run/user/1000

I also ran df and got this

joshua@joshua-HP-15-Notebook-PC:~$ df
Filesystem                        1K-blocks      Used Available Use% Mounted on
udev                                1709180         0   1709180   0% /dev
tmpfs                                346368      5772    340596   2% /run
/dev/mapper/ubuntu--mate--vg-root 476027960 451585116    238968 100% /
tmpfs                               1731832     15412   1716420   1% /dev/shm
tmpfs                                  5120         4      5116   1% /run/lock
tmpfs                               1731832         0   1731832   0% /sys/fs/cgroup
/dev/sda2                            483946    138483    320478  31% /boot
/dev/sda1                            520192      4784    515408   1% /boot/efi
tmpfs                                346368        48    346320   1% /run/user/1000

I’m on a HP 15 Notebook laptop with UbuntuMATE 16.04.2 LTS installed. I honestly have no idea what’s going on ere. I only knew about these commands because I have been doing a bit of googling to try to assess the issue. So far, I’m clueless… I don’t understand this one bit. Any help would be much appreciated.

Hi
Your HOME folder is on the same partition as your root.
You need to delete some files to recover hard drive space.
Please make sure your Trash is empty.

Edit: Self moderation, did not read correctly.

Addendum: For the record, it might be useful to format the output of df with the preformatted text option (see the post editor).

1 Like

Seems you have a 500 GB disk drive, df will output in 1K-blocks, df -h will output in human readable format (KB, MB, GB). You could try, sudo du -d1 / | sort -n which uses the disk usage utility (du) to start from root / go depth 1 and sort them numerically. That way you can see which dir has is the largest files and cleanup your system. Usually /home, /usr, and /var take large space.

1 Like

Linux doesn’t really behave too nicely when the bytes are all gone. Sometimes it’s necessary to boot from a live-USB and clean things up enough to get things going again.

mate-disk-usage-analyzer is your friend. In synaptic (if you use it) there’s a category called “installed (auto-removable)”. look there to see all the previous kernel updates. They take up a goodly bit of space and i don’t think they ever get cleaned up until you do it manually. Synaptic seems to clean those up nicely in my experience.

Between your Trash folder (i don’t use it, i just “delete” and if necessary recover from a backup, but most folks seem to like Trash since they’re not paranoid about having backups) and old kernels that are hanging around unused, you should at least be able to get to the point of running mate-disk-usage-analyzer to see what you have to work with. If you don’t use synaptic, there are apt commands to do the same thing, but i’d have to look those up to figure out what the parameters are.

1 Like

dpkg -l | cut -d " " -f 3 | grep -E 'linux-image-|linux-headers-' | grep -v $(uname -r)

Breakdown:

dpkg -l – List all installed packages
cut -d " " -f 3 – Take only the actual package name
grep -E 'linux-image-|linux-headers- – List only the linux kernel and headers
grep -v $(uname -r) – Filter out the currently running kernel.

Combined, this will list all installed kernels (and their headers) that aren’t the currently running version.

Edit: Be mindful how to interpret this information and what to do with it. Because it might still list meta packages.

2 Likes

That’s why i like GUI, i don’t have to remember the details in addition to several hundred thousand lines of code. :wink:

Thanks! MATE Disk Usage Analyzer appears to be the best bet for me. I’m guessing running BleahBit was the main fix but MATE Disk Usage Analyzer seems to be the perfect tool for figuring this one out. Thnak so much. :grin: