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

Re: [Xen-API] look into VHD VDI from Control Domain in XCP 1.6


  • To: xen-api@xxxxxxxxxxxxx
  • From: George Shuklin <george.shuklin@xxxxxxxxx>
  • Date: Sat, 05 Jan 2013 09:14:44 +0400
  • Delivery-date: Sat, 05 Jan 2013 05:14:57 +0000
  • List-id: User and development list for XCP and XAPI <xen-api.lists.xen.org>

You doing it wrong.

Use xe vbd-create between vdi and dom0 (which is normal VM mostly), and xe vbd-plug.

You can see some sample usage in 'xe-edit-bootloader' command (somewhere in /opt/xensource/)

05.01.2013 04:57, Alexandre Kouznetsov ÐÐÑÐÑ:
Hello.

I'm trying to mount VM's disk within Control Domain, as part of my pre-production tests. My XCP 1.6 installation uses a LVM based local storage after a default install. The VM's disks are in VHD format.

In my previous Xen experience, with "raw" volumes as virtual hard disks, I have successfully used kpartx, with images stored in files and LVM. Clearly, kpartx can't map partitions of a VHD volume.

Within the XCP installation I have found vhdpartx utility, judging by it's name and --help output I expected it to be just the tool I need. But it's seems there is some problem if I try to use it as kpartx:

[root@xcp47 ~]# lvscan
ACTIVE '/dev/VG_XenStorage-cfc7419f-8b4e-8c51-d619-dfdee09841a2/MGT' [4.00 MB] inherit ACTIVE '/dev/VG_XenStorage-cfc7419f-8b4e-8c51-d619-dfdee09841a2/VHD-bbdf149e-4b41-4a6a-9059-9251365a0a86' [8.02 GB] inherit ACTIVE '/dev/VG_XenStorage-cfc7419f-8b4e-8c51-d619-dfdee09841a2/VHD-fd118da1-c3dd-466b-8b27-32c5db1fcce7' [3.01 GB] inherit [root@xcp47 ~]# vhdpartx -a /dev/VG_XenStorage-cfc7419f-8b4e-8c51-d619-dfdee09841a2/VHD-fd118da1-c3dd-466b-8b27-32c5db1fcce7
can't find vhd or lib
[root@xcp47 ~]#

Unfortunately, there is no online man page available in my XCP installation, and blktap2 documentation mostly covers Xen's config file syntax to to use with VHD storage.

The idea to treat the VHD as a black box is not appealing at all. Is there a regular way to access VHD from Dom0? What's wrong with my vhdpartx, maybe it is supposed to work in a different way?


I have done my search for alternatives and the most promising reference I've found was one that suggests attaching the VDI (or it's snapshot) to the Dom0 via a manually created VBD, just as if it was a regular VM.
http://forums.citrix.com/thread.jspa?threadID=252142
It's quite old, and I did not get that solution work ether: I can do all the steps, but the disk never showed up within Dom0, even after I "vbd-plug" it.


Thank you.



_______________________________________________
Xen-api mailing list
Xen-api@xxxxxxxxxxxxx
http://lists.xen.org/cgi-bin/mailman/listinfo/xen-api

 


Rackspace

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