<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Blog of a LAMP Developer based near Guildford, Surrey &#187; hypervm alternative</title>
	<atom:link href="http://www.lampdeveloper.co.uk/tag/hypervm-alternative/feed" rel="self" type="application/rss+xml" />
	<link>http://www.lampdeveloper.co.uk</link>
	<description>A day in the life of a Lamp Developer</description>
	<lastBuildDate>Wed, 18 Aug 2010 14:44:13 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>HyperVM Manual Alternative for creating Xen Domu using LVM</title>
		<link>http://www.lampdeveloper.co.uk/linux/hypervm-manual-alternative-for-creating-xen-domu-using-lvm.html</link>
		<comments>http://www.lampdeveloper.co.uk/linux/hypervm-manual-alternative-for-creating-xen-domu-using-lvm.html#comments</comments>
		<pubDate>Fri, 26 Jun 2009 17:40:47 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[hypervm alternative]]></category>

		<guid isPermaLink="false">http://www.lampdeveloper.co.uk/?p=133</guid>
		<description><![CDATA[After the sad death of K T Ligesh I decided, like many people, to move away from HyperVM.
I searched and tried many control panels.
Openqrm &#8211; I found this over kill
karesansui &#8211; This is very nice looking and polished but seemed quite slow.
VDS Manager &#8211; Still in beta for Xen
I&#8217;ve now decided to create the VM&#8217;s [...]]]></description>
			<content:encoded><![CDATA[<p>After the sad death of K T Ligesh I decided, like many people, to move away from HyperVM.</p>
<p>I searched and tried many control panels.</p>
<p><a href="http://www.openqrm.com/" target="_blank">Openqrm</a> &#8211; I found this over kill<br />
<a href="http://www.karesansui-project.info/" target="_blank">karesansui</a> &#8211; This is very nice looking and polished but seemed quite slow.<br />
<a href="http://www.ispsystem.com/en/software/vdsmanager/" target="_blank">VDS Manager</a> &#8211; Still in beta for Xen</p>
<p>I&#8217;ve now decided to create the VM&#8217;s by hand. I then hope to make a PHP control panel of my own. Here are my steps for creating Xen VPS&#8217;s using the command line and Centos 5.</p>
<p>I&#8217;m going to create a vm called testvm</p>
<p>First I needed to find out what Volume groups exist on my system and what the VG Name was</p>
<p><em>lvdisplay</em></p>
<p>VG Name                <strong>VolGroup00</strong></p>
<p>Create the disks for the VM and format</p>
<p><em>lvcreate -L8.5G -n testvm_rootimg VolGroup00<br />
lvcreate -L 384M -n testvm_vmswap VolGroup00<br />
mke2fs /dev/VolGroup00/testvm_rootimg<br />
tune2fs -j /dev/VolGroup00/testvm_rootimg<br />
mkswap /dev/VolGroup00/testvm_vmswap</em><br />
<em>mkdir /mnt/img<br />
mkdir /mnt/vm</em></p>
<p>Now mount your disk image. I&#8217;ve created a custom hardened Centos distro, but you could use <a href="http://mirror1.smudge-it.co.uk/jailtime/" target="_blank">Jailtime Images</a></p>
<p><em>mount -o loop centos.5-3.64-smudge.img  /mnt/img<br />
mount /dev/VolGroup00/looop_rootimg /mnt/vm</em></p>
<p>Copy the image onto your new partition</p>
<p>cp -a /mnt/img/* /mnt/vm/</p>
<p>Now all you need to do is configure the hostname, ip etc on the VM.</p>
<p>vi /mnt/vm/etc/sysconfig/network-scripts/ifcfg-eth0</p>
<p>DEVICE=eth0<br />
BOOTPROTO=static<br />
IPADDR=87.xxx.xxx.xxx<br />
NETMASK=255.255.255.xxx<br />
ONBOOT=yes</p>
<p>Change the hostname</p>
<p>vi /mnt/vm/etc/sysconfig/network</p>
<p>If your using Jailtime images people have advised to change this line to the following:</p>
<p><em>vi /mnt/vm/etc/inittab<br />
1:2345:respawn:/sbin/mingetty console</em></p>
<p><em>vi /mnt/vm/etc/ssh/sshd_config<br />
PermitRootLogin yes</em></p>
<p><em>vi /mnt/vm/etc/fstab</em></p>
<p>Add the line:</p>
<p><em>/dev/sda2     swap   swap     defaults     0     0</em></p>
<p><em>umount /mnt/img /mnt/vm</em></p>
<p>You will need a ram disk to boot from. This can be created by running:</p>
<p><em>mkinitrd /boot/xen-guest-initrd `uname -r` &#8211;with xenblk &#8211;with xennet &#8211;preload xenblk &#8211;preload xennet </em>&#8211;omit-scsi-modules</p>
<p>Now all you need to do is create the config file and give it an IP/ Mac address.Please check which kernel you are using first and change &#8211; kernel = &#8220;/boot/vmlinuz-2.6.18-128.1.14.el5xen&#8221;&#8230;</p>
<p>kernel = &#8220;/boot/vmlinuz-2.6.18-128.1.14.el5xen&#8221;<br />
ramdisk    = &#8216;/boot/xen-guest-initrd&#8217;<br />
maxmem = 192<br />
memory = 192<br />
vcpus = 1<br />
name = &#8220;testvm&#8221;<br />
vif = [ 'ip=87.xxx.xxx.xxx,bridge=xenbr0, rate = 1000KB/s, mac=aa:00:23:b0:de:34' ]<br />
serial     = &#8216;pty&#8217;<br />
disk       = ['phy:/dev/VolGroup00/testvm_rootimg,sda1,w', 'phy:/dev/VolGroup00/testvm_vmswap,sda2,w']<br />
root = &#8216;/dev/sda1 ro&#8217;<br />
on_poweroff = &#8216;destroy&#8217;<br />
on_reboot   = &#8216;restart&#8217;<br />
on_crash    = &#8216;restart&#8217;</p>
<p>All is ready to go.</p>
<p>Just run:</p>
<p><em>xm create testvm</em></p>
<p>And you VPS should be now running:</p>
<p>check with<br />
<em>xm console testvm</em></p>
<p>Hope this helps.</p>
<p><a href="http://www.smudge-it.co.uk" target="_blank">Smudge IT</a> will be lauching  a new site and <a href="http://www.smudge-it.co.uk">Xen Vps</a> systems soon. Watch this space..</p>
<p class="addtoany_share_save_container">
    <a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?sitename=Blog%20of%20a%20LAMP%20Developer%20based%20near%20Guildford%2C%20Surrey&amp;siteurl=http%3A%2F%2Fwww.lampdeveloper.co.uk%2F&amp;linkname=HyperVM%20Manual%20Alternative%20for%20creating%20Xen%20Domu%20using%20LVM&amp;linkurl=http%3A%2F%2Fwww.lampdeveloper.co.uk%2Flinux%2Fhypervm-manual-alternative-for-creating-xen-domu-using-lvm.html"><img src="http://www.lampdeveloper.co.uk/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Save/Bookmark"/></a>

	</p>]]></content:encoded>
			<wfw:commentRss>http://www.lampdeveloper.co.uk/linux/hypervm-manual-alternative-for-creating-xen-domu-using-lvm.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
