Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Can Xen PV or OpenVZ give me what I get with KVM or Xen HVM?
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

Can Xen PV or OpenVZ give me what I get with KVM or Xen HVM?

rchurchrchurch Member
edited February 2012 in Help

I am currently deploying some VMs on Xen HVM because I can simply roll the image into on the disk untar it, fix grub and get it up and running in minutes. Can OpenVZ and Xen PV do the same?
If the back ups were made on a VM using the same distro and kernel, it it possible to untar them into place and get them up and running without any major issues.

Comments

  • FranciscoFrancisco Top Host, Host Rep, Veteran

    Where are you getting the images for the XEN HVM? Unless you're getting them from Stacklet (or whatever the name is), HVM is normally an ISO based install.

    Francisco

  • @Francisco
    boot a live cd and do something like:
    wget http://othervps/image.img -O - |dd of=/dev/vda

  • @Francisco Sounds like a disk image style duplication of system.

    You could do something similar with the options in question without the missions of reconfiguration of the boot loader, "on OpenVZ anyway", not sure if you will get away with it on PV
    but should be similar.

    I think openvz would be more suited to your duplication needs than any other form of virtualization.

    If you are looking to do block level duplication KVM and HVM are your only options but for pure system duplication Openvz is a simple dump, no complications at all.

    Regards
    Justin

  • @Francisco - When I set up the HVM I set it up to boot from a Rescue CD and from there create and format the partitions, use SCP to copy and untar the image into place, modify the the grub and network settings and reboot. The HVM comes from a regular Xen HVM provider.

  • When a XenPV or OpenVZ boots, I guest it ignores and grub or boot configurations on the image on which it is booting, doesn't it? From what I understand it uses its own /lib/modules configuration and ignores what is on the image's directory, or does it use what's in the images directory or expect to find its a matching version of its /lib/modules in the images directory?

    For instance I transferred a Xen HVM to a KVM host using the same OS Version or vice versa ( I can't remember which) and it although it booted, networking wouldn't come up until I replaced the /lib/modules on the target from the source.

    In short if I copy a /lib/modules from a VPS on the host I am restoring to onto the system I am restoring from before making the backup do I have a reasonable chance of success? Other then the OpenVZ's or XenPV /etc/network/intefaces and other similar non-standard bridging etc?

  • Hello,

    As you have requested my input.. here it is!

    As @Francisco has mentioned HVMs are usually not done in this way but as block devices. The normal way to do it is indeed to install from scratch from an ISO or netboot server which I would kickstart for automation.

    There is no right or wrong way. While the way you are doing things is perfectly valid you will need to have systems in place to automate configuration of your virtual machine once you have extracted your template. This typically involves setting a root password, configuring the network, fstab, a kernel and /lib/modules and a few other things.

    I would imagine your HVM template already has a Kernel and /lib/modules so no further action should be required.

    In the case of Xen PV we configure everything at boot time by mounting your filesystem and editing and/or rsyncing a few things. By default we rsync a copy of /lib/modules as required from the host node as you will be running our Kernel. We offer the option to disable this if you plan to enable as PyGrub or PvGrub as you have already seen: !(http://i.imgur.com/ryUd0.png)

    Py/PvGrub lets you boot your own Kernel such as a stock Xen or pvops enabled Kernel provided by your distribution of choice. By using a Kernel supplied by your distribution it will manage /lib/modules for you.

    Hopefully this answers your query.

    Regards,
    Sean McRobbie
    OpenITC.co.uk

Sign In or Register to comment.