0

Lately I've had space problems in my Ubuntu 20.04.5 OS (such as not showing the ui for example).

I checked my disk space and I found that I have two partitions for file systems. Is it normal? Because I have free space in one of them that isn't being used so I wonder if I can merge them and solve my space problem

Reference image 1

Reference image 2

Reference image 3

Thomas Ward
  • 78,878

1 Answers1

2

Your partition /dev/sda5 isn't unused; according to the image you provided it is mounted on /home, so any files that are placed within your home directory are actually located on that partition.

You probably set it this way during system installation, to have separate partitions for system (/) and for data (/home). This is a perfectly normal setup, but your problem is that you set your system partition too small (20 GB). It should definitely be larger - 50 GB seems a reasonable size.

You can boot from the live media you used to install the system and use GParted program to resize/move the partitions. It is recommended to have a backup of everything important while doing this, in case something goes wrong.

Merging the partitions will be a bit more complicated in your case, because:

  1. your system is already configured to use two separate partitions, as said above - you would need to change this configuration (it is done via /etc/fstab file).
  2. before attempting to merge the partitions, you should copy the entire contents of your /dev/sda5 partition to some external storage (eg. USB drive) - as you would need to delete that partition. After resizing /dev/sda3 is done, you must copy that contents back into /home directory.
  3. then you should use GParted to delete /dev/sda5, move /dev/sda4 to the end of the drive and resize /dev/sda3.
raj
  • 11,409