Copy GPT Partitioning layout to other hard disk drive

To copy GPT Partition layout to many drives we need sgdisk. sfdisk cant do that.

As of Debian 6.0. Installer does not have sgdisk. So I had rebooted the machine from Gparted live cd. and ran the command given below.

Note that the /dev/sdb is destination drive and source is second device(/dev/sda) (exchange them at your own risk). It will copy partition layout from /dev/sda  to /dev/sdb

#sgdisk -R=/dev/sdb /dev/sda

The command below is required coz the first command copy/assign the same GUID to new device. So to assign another random unique GUID run the following command

#sgdisk -G /dev/sdb

Have FUN!

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s