How to extend primary partition

broken image

This step is neccessary so the partition table gets re-read. You will get an error message from partprobe that the partition table couldn't be reread (because the disk is in use). If everything looks right, issue w to write the partition table to disk. Issue p to review your new partition layout and make sure the start of the new second partition is exactly where the old second partition was. Issue t followed by 2 followed by 8e to toggle the partition type of your new second partition to 8e (Linux LVM). Make sure the end is at the end of the disk (usually the default). Make sure the start equals the start of the partition table you printed earlier. Issue n to create a new second partition. Now issue d followed by 2 to remove the second partition. Issue p to print your current partition table and copy that output to some safe place.

broken image
broken image

alter your partition table so sda2 ends at end of disk.