my fedora file system do not show enough space/no space even if the home have free space
Hello @astronaut
Could you provide more information?
In the command line, what is the result of this command?
df -h
Filesystem Size Used Avail Use% Mounted on devtmpfs 1.9G 0 1.9G 0% /dev tmpfs 1.9G 24M 1.9G 2% /dev/shm tmpfs 1.9G 1.5M 1.9G 1% /run /dev/mapper/fedora_localhost--live-root 69G 69G 0 100% / tmpfs 1.9G 44K 1.9G 1% /tmp /dev/mapper/fedora_localhost--live-home 842G 610G 189G 77% /home /dev/sda2 976M 242M 668M 27% /boot /dev/sda1 599M 21M 579M 4% /boot/efi tmpfs 382M 48K 382M 1% /run/user/1000 tmpfs 382M 48K 382M 1% /run/user/1000
i feel home and file system are separate space in fedora
home show the free space of 202.8 GB by filesystem show 0
i clean up some space but not change in df -h
Yes. The root filesystem (/
) is full.
You have to figure out where such space is used.
You can start with
sudo du --exclude=/home -sh /* |sort -h
look what is the biggest directory, then again
sudo du -sh /var/* |sort -h
and so on.
Remember that /var
usually contains logs, caches, spools, etc., while /usr
contains the programs, software, executables, etc.
If you have many packages installed, probably the biggest directory is /usr
, but usually the occupied space goes to /var
if you have many flatpaks, or virtual machines.
In addition, if you are unable to free enough space, you could consider to resize the LVM volumes, shrinking the home and enlarging the root.
+1 for that!
(it gives you the list of the largest directories)
May consider adding a head -n 30
to the command, otherwise, the list will be unnecessarily long.
Looking for the largest single files, you can use something like:
sudo du --exclude=/home -sh / | sort -n -r | head -n 50
For a desktop install a 70G root file system is already pretty large. If you are using a lot of flatpaks (large games?), consider using the --user
option during install. This will place the flatpak in your home directory instead of /.
On my Fedora systems, I have a 30G / partition and never run out of space(no gaming, and no containers or vms on /
, 2G swap file on /)
You wouldn’t want to do that; sort -h
will sort in ascending order by default.
(A tail -n 30
could be useful, though really there’s not a lot of need since you’ll end up at a command prompt right under the bottom of the list. More length just means more data you can scroll back over if needs must.)
How do you do upgrades, though?!? My main desktop box has a 45GB root partition, and it’s awful.
Under normal circumstances I have between 2GB and 5GB free, which means twice a year I have to scrounge around running journalctl --vacuum-size
(blowing away most of my journal history), plus sudo dnf remove
-ing tons of -devel
packages and other large installs, just so I can free up enough room for the two copies of the entire upgrade package set that’s required to successfully dnf system-upgrade
to the next Fedora release. It suuuuuuucks.
If I had it to do over again (and at some point, I will), I’d go with between 80GB and 100GB. At least for that machine, the one I use as my main desktop/development box. (Which does include large mock
sandboxes, potentially some container images, etc…)
It all depends on the use case, for one user 15 GB root file system is sufficient while for another user 100GB is barely enough.
The issue you are running into is well known at Fedora and being actively discussed in the Fedora Workstation working group. See:
- https://pagure.io/fedora-workstation/issue/54
- 1577971 – Default disk partitioning layout for Fedora Workstation
By the way, when setting up your machine, you don’t have to go with the default partitioning scheme (small root, large home, ext4 on LVM) - you can already create a BTRFS filesystem and benefit from all the advantages (volumes, subvolumes, snapshots, compression, encryption) - why not give it a go…
Finally had a chance to upgrade the SSD in that machine to 1TB, so now the root partition is 65GB with almost 20 free, and I have plenty of free extents in the volume group if I ever decide to grow it even bigger.
Still using ext4, though,. I haven’t taken the plunge in exploring butterfs. (I’m sorry, but that’s what ‘btrfs’ will always look like, to me.) I had my hands full enough with the switch I decided to do from MBR+BIOS to GPT+UEFI.