0

I am trying to increase the disk size of my Ubuntu server with Gparted. I've come so far but the changes don't seem to have an effect.

Here is an image of what i began with and how my partitions looked like.

enter image description here

afterall i got this as my endresult

However ithink everything is configured right, the output of the "df -h" command don't confirm my changes have applied. The output of the command still shows the old volumes.

I tried to increase de /dev/sda1 partition with almost the exact steps and on this partition the changes did apply.

What is the reason for this and how can i solve it?

Gerald Schneider
  • 19,757
  • 8
  • 52
  • 79

1 Answers1

1

The partition you enlarged is a physical disk for LVM (as you can see in the "File system" and "Flags" columns). Enlarging a physical disk of an LVM does not automatically enlarges the physical volume which resides on that device. You have to manually enlarge the volume with the

pvresize /dev/sda5

command. After this, you need to manually resize the corresponding logical volume (LV) with the lvresize command, and finally, the file system itself with the proper resize command, which depends on the file system type (e.g. resize2fs for ext{2,3,4})

Note that you usually need to enlarge the file system if you enlarge the device on which it resides, but parted does it for you. It seems that it doesn't do the same for LVM, which is why resizing /dev/sda1 "just worked", and resizing /dev/sda5 is a bit of a pain.

Lacek
  • 6,585
  • 22
  • 28