[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-users] how to boot a para-virtulized vm from cdrom afterinstallation

  • To: xen-users@xxxxxxxxxxxxx
  • From: Alexandre Kouznetsov <alk@xxxxxxxxxx>
  • Date: Wed, 10 Oct 2012 18:02:49 -0500
  • Delivery-date: Wed, 10 Oct 2012 23:04:03 +0000
  • List-id: Xen user discussion <xen-users.lists.xen.org>


El 10/10/12 17:34, Jun Hu escribió:
> You can try this:
>> 1. Hard way. Set up a new, completely new, HVM DomU. Attach your former 
>> PV DomU to it and boot form CD.
> -No,  the hvm domu can't boot  the pv's   xen flavor kernel .
That is correct, HVM can't boot a PV kernel. But in this scenario you
are not booting a PV kernel. Instead, you would be booting a regular
kernel from your CD. That's why you need to switch to HVM, you boot CD
unlikely would provide a PV enabled kernel.

You can extract the kernel and initrd from CD, make Xen use them for
booting, but this will have little to do with "Booting from CD". The
words "Boot custom kernel" will describe that much better, and it's
documented elsewhere.

By the way, since kernel 3.something, the same kernel image can be used
to boot PV and HVM machine. But that is probably not the case, you will
have to boot thatever jernel is in your CD, not the one you choose.

>> 2. Depends on what you need to achieve over your DomU, it almost 
>> certainly possible to be done from Dom0.
> -almost agree with you ,but there is a scene:
> when  I need to do some rescue  for the boot disk  using cdrom .

I'm afraid, the term "rescue" turns ambiguous when we talk about a
virtual machine.
Please consider, in what cases you would need to "rescue" a guest system?

1. Test a new system, tool, new fancy LiveCD.
Don't use your existing VM, make a new one. Shutdown the existing one,
if you are short of resources.

2. Broken boot process.
Since PV guest does not use it's own bootloader, there is nothing to be
broken (or fixed) from within the DomU on this stage. If the boot loader
is broken, it needs to be fixed at Dom0, put your guest machine aside.
There also might be something wrong with init scripts, in this case you
would shutdown the DomU, mount it's filesystem within Dom0 and make the
modifications. No need to boot into the virtual machine from external media.

3. Broken everything, rescue data.
Mount DomU's filesystem in Dom0, copy your data. Or even better, make a
new VM and attach the old storage to it (it's always a good idea to keep
your system and the data on separate volumes). Again, you already have
access to your virtual machine's storage, no need to boot from CD.

4. Virus, trojan, rootkit, crime evidence, forensic analysis, etc.
Do not mount your VM's filesystem, instead do a binary dump of it's
storage to somewhere safe. Same case.

That's what I meant when i told you "it does not work that way".

Alexandre Kouznetsov

Xen-users mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.