Convert disk to GPT without losing data

Customer asked for it…. Customer got it….
(and I was scared as hell…..)

a.   Check if the gdisk is installed – if not install it
# rpm -qa | grep gdisk
# yum install gdisk
this if for RHEL/Centos… For ubuntu use apt 😉

b.     Convert disk from MBR to GPT – just run gdisk, write and reboot
scary part number 1

b.     After reboot resize the partition – with gdisk delete the partition an immediately create new but bigger on the same place (use offered default values when creating) and reboot
scarry part number 2

c.     After reboot resize the LVM Physical volume and verify free space grew
yeah… piece of cake….

In theory – we can do all this online without reboot. I tried it in my lab and it worked….. But just to be sure and play it safe I like to refresh all changes related to partitions with reboot.


Posted

in

by

Tags:

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *