Mounting logical volumes (LVM) from domX (guest) within dom0 (XenServer) is very not recommender and suggested. But sometimes it might be the only options, and it's cool hacker (hacker in good old meaning, not cracker) trick. So to mount your volume you should take following steps:
- xe vm-disk-list vm=test4 - list disk of the VM.
- xe vm-list - find info (UUID) about dom0.
- xe vbd-create device=xvda unpluggable=true vdi-uuid=79a7a556-a6ba-48cf-8c82-30fa5bb9597c vm-uuid=36895434-e6d7-4fea-8271-d5477ca23c6d - create unpluggable VBD (xvda) with disk (uuid from point 1) on dom0 (uuid from point 2).
- xe vbd-plug uuid=0a4151b6-2b59-2fdb-c0a9-492520a8d52c - plug created vbd.
- mount /dev/xvda1 /mnt - mount disk (any 'physical partition').
- vi /etc/lvm/lvm.conf - if you need anything on LVM you have to edit lvm.conf
# Ignore /dev/xvd* devices to prevent deadlocking when live-snapshotting
# dom0-attached LVHD VDIs
#filter = "r|/dev/xvd.|","r|/dev/VG_Xen.*/LV.*|"
- vgchange -a y test4 - activate new vg.
- mount /dev/test4/root /test/mnt - mount partition.
No comments:
Post a Comment