{{anchor href="top"}}
Hits : **{{hits}}**
== GUID Partition Table - parted ==
lets assume that you want to create a new ((https://en.wikipedia.org/wiki/GUID_Partition_Table GPT)) layout on a disk.
From command line you can use ((https://www.gnu.org/software/parted/manual/parted.html parted))
In the below example disk is 10Gb.
We will create a boot partition 128Mb, a root partition 8Gb and a swap partition with the rest size of the disk.
{{ToC from="h2" to="h3"}}
=== Select disk ===
%%(bash)
parted
select /dev/sda
print
%%
https://balaskas.gr/img/archlinux-2012.08.04/34.png
((#top))
-----------
=== Create new layout ===
%%(bash)
mklabel gpt
print
%%
https://balaskas.gr/img/archlinux-2012.08.04/35.png
((#top))
-----------
=== Create Boot Parition ===
Select mebibyte for start - end size values
%%(bash)
unit MiB
%%
create a primary boot partition
%%(bash)
mkpart primary ext2 1 129
name 1 bootfs
%%
Make partition, bootable :
%%(bash)
set 1 boot on
%%
https://balaskas.gr/img/archlinux-2012.08.04/36.png
((#top))
-----------
=== Create Root Partition ===
%%(bash)
mkpart primary ext4 129 8321
name 2 rootfs
%%
https://balaskas.gr/img/archlinux-2012.08.04/37.png
((#top))
-----------
=== Create Swap Partition ===
give swap partition the rest avaliable size of the disk
%%(bash)
mkpart primary linux-swap 8321 -1
name 3 swapfs
%%
https://balaskas.gr/img/archlinux-2012.08.04/38.png
((#top))
-----------
=== Verify your partition table ===
%%(bash)
gdisk -l /dev/sda
%%
https://balaskas.gr/img/archlinux-2012.08.04/39.png
((#top))
-----------