lvm

/Tag:lvm

Debian Wheezy Xen + Guest Howto

Xen is usually my go to virtualization technology for Linux. Here’s a HOWTO on setting up Xen on Debian Wheezy and the first guest virtual machine. First step is getting the required packages: apt-get install xen-linux-system xen-tools xen-utils-4.1 xen-utils-common xenstore-utils xenwatch Now, we’ll need to specify the Xen kernel as the default boot kernel on the host, and then reboot: […]

By | October 8th, 2014|Linux, Networking, VPS|0 Comments

Setting up an LVM filesystem

Setting up an LVM filesystem is quite easy assuming you have the right tools installed and a recent kernel. LVM has a lot of advantages, most notably the ability to take snapshots of the current filesystem – this is why LVM is often used in live database environments. Assuming a Debian Lenny machine, get the relevant packages. Some may already be installed:  apt-get install lvm2 dmsetup mdadm In this example, we will assuming that /dev/sda is your boot drive, and that you want to leave it out of your LVM array, but include /dev/sdb and /dev/sdc. Both /dev/sdb and /dev/sdc should be of equal sizes. Firstly, using fdisk, remove any existing partitions with ‘d’, on /dev/sdb and /dev/sdc, and create one new partition to span the drive. Change the partition type to ‘8e’ which is the LVM type. Now prepare your physical disk for LVM with the ‘pvcreate’ tool: pvcreate /dev/sdb1 /dev/sdc1 Note that you can reverse this with pvremove. You can also use pvdisplay now to display information on all physical volumes. Oh – you do realie that you can use /dev/mdX just as easily to create LVM on your RAID devices? Now, we need to create a ‘volume group’: vgcreate myvg /dev/sdb1 /dev/sdc1 […]

By | October 20th, 2009|Technology|0 Comments