wiki'd

by JoKeru

New Volume to Amazon EC2 Instance

Login to AWS Management Console, create new EBS Volume and attach it to the instance as /dev/sdf (the instance will see the new volume as /dev/xvdf).

[cc lang='bash']
\$ fdisk /dev/xvdf
# primary partition /dev/xvdf1
# type Linux LVM (8e)

\$ pvcreate /dev/xvdf1
\$ vgcreate VG-IMG /dev/xvdf1
\$ lvcreate --name LV-IMG --extents 127999 VG-IMG
\$ mkfs.ext4 /dev/VG-IMG/LV-IMG
\$ mkdir /IMG
\$ mount /dev/VG-IMG/LV-IMG /IMG
[/cc]

Comments