Skip to contentSkip to conversation

Xen & Automated Disk Management for Domains

DISCUSSION Björn Sessler 3 participants 6 messages Aug 7, 2004 – Aug 8, 2004

lore
Share & tools
lore
#0 lore raw

hi,

i tried lvm (vers. 1) with xenU 2.4. i created one group on a raid0-device /dev/md/0 (devfs with gentoo) with several lv's for swap and root for virtual hosts. on xen0 i can mount and use these devices without any problem, one of these device is currently used as swap for xen0.

i tried to give access with this xmdefaults configuration
(not mounted in vm as root like the name says, only access for later test-mount):

disk = [ 'phy:hdb5,hdb5,w' , 'phy:hda6,hda6,w' , 'phy:/dev/vg0/rootvm101,hdx1,w' ] before:
disk = [ 'phy:hdb5,hdb5,w' , 'phy:hda6,hda6,w' ]

when trying to start the vm, this error occurs (i modified xmdefaults to accept vmid=vm101 like the name of the vm):

root@vm0 vm # xm create -c vmid=vm101
Using config file /etc/xen/xmdefaults
Error: Error creating domain: [Failure instance: Traceback: xen.xend.XendError.VmError, vbd: Segments not found: uname=phy:/dev/vg0/rootvm101

the xend-log says following while creation:

[2004-08-07 12:14:15 xend] DEBUG (XendDomainInfo:692) init_domain> Created domain=14 name=vm101 memory=61 [2004-08-07 12:14:15 xend] INFO (console:93) Created console id=14 domain=14 port=9614 [2004-08-07 12:14:15 xend] DEBUG (XendDomainInfo:1046) Creating vbd dom=14 uname=phy:hdb5 dev=hdb5 [2004-08-07 12:14:15 xend] DEBUG (XendDomainInfo:1046) Creating vbd dom=14 uname=phy:hda6 dev=hda6 [2004-08-07 12:14:15 xend] DEBUG (XendDomainInfo:1046) Creating vbd dom=14 uname=phy:/dev/vg0/rootvm101 dev=hdx1 [2004-08-07 12:14:15 xend] DEBUG (XendDomainInfo:659) Destroying vbds for domain 14 [2004-08-07 12:14:15 xend] DEBUG (blkif:339) Destroying blkif domain=14
[2004-08-07 12:14:15 xend] DEBUG (blkif:415) >BlkifController>send_be_disconnect> dom=14 [2004-08-07 12:14:15 xend] DEBUG (XendDomainInfo:619) Closing channel to domain 14
[2004-08-07 12:14:15 xend] DEBUG (blkif:422) >BlkifController>send_be_destroy> dom=14

i also noticed that changing configuration to
disk = [ 'phy:hdb5,hdxSWAP,w' , 'phy:hda6,hdxUSR,w' ]
produces also an error like:
Using config file /etc/xen/xmdefaults
Error: Error creating domain: [Failure instance: Traceback: <type 'tuple'>, (<twisted.python.failure.Failure exceptions.TypeError>, 1)

output in xend-log is the same.

any hints for this? or is lvm 1 generally not supported which means i have to patch?

thanks & best regards,
bjoern
_______________________________________________________
WEB.DE Video-Mail - Sagen Sie mehr mit bewegten Bildern Informationen unter: http://freemail.web.de/?mc=021199

-------------------------------------------------------
This SF.Net email is sponsored by OSTG. Have you noticed the changes on Linux.com, ITManagersJournal and NewsForge in the past few weeks? Now, one more big change to announce. We are now OSTG- Open Source Technology Group. Come see the changes on the new OSTG site. www.ostg.com

#1 lore raw
Quoted 4 lines · On Sat, Aug 07, 2004 at 01:33:12PM +0200, =?iso-8859-1?Q? Bj=F6rn=20Sessler ?=…

disk = [ 'phy:hdb5,hdb5,w' , 'phy:hda6,hda6,w' , 'phy:/dev/vg0/rootvm101,hdx1,w' ] before:
disk = [ 'phy:hdb5,hdb5,w' , 'phy:hda6,hda6,w' ]

There's a couple of things wrong with that entry:
- the destination device has to have a /dev/ entry in the domain where you run xend (i.e. /dev/hdx1 would have to exist in dom0's filesystem).
- like with all devices, xend will prepend /dev/ to the device name.

For completeness, let me also mention that the destination device has to be a hd or sd with an existing major number in the domain where the device will be used.
(in 2.4, cciss might work as well ans here might be support for it to be an xbd but that can go away anytime...).

It should work if you use:
disk = [ 'phy:hdb5,hdb5,w' , 'phy:hda6,hda6,w' , 'phy:vg0/rootvm101,sda1,w' ]

christian

-------------------------------------------------------
This SF.Net email is sponsored by OSTG. Have you noticed the changes on Linux.com, ITManagersJournal and NewsForge in the past few weeks? Now, one more big change to announce. We are now OSTG- Open Source Technology Group. Come see the changes on the new OSTG site. www.ostg.com

#2 lore raw
Quoted 10 lines · On Sat, Aug 07, 2004 at 01:33:12PM +0200, =?iso-8859-1?Q? Bj=F6rn=20Sessler ?=…
Quoted 4 lines

disk = [ 'phy:hdb5,hdb5,w' , 'phy:hda6,hda6,w' , 'phy:/dev/vg0/rootvm101,hdx1,w' ] before:
disk = [ 'phy:hdb5,hdb5,w' , 'phy:hda6,hda6,w' ]

There's a couple of things wrong with that entry:
- the destination device has to have a /dev/ entry in the domain where you run xend (i.e. /dev/hdx1 would have to exist in dom0's filesystem).

At some point (probably post 2.0) we need to modify the vbd interface so that both the backend and frontend drivers get passed device _names_ rather than numbers, that they each resolve in their own context (within the kernel).

The current situation where xend looks up both device names and passes 32bit device numbers is not ideal, particularly when booting a non-Linux OS. (Christian pointed this out many months ago while doing the NetBSD port, but we haven't gotten around to fixing it).

Quoted 1 line

- like with all devices, xend will prepend /dev/ to the device name.

xend appends /dev/ if it's not already there, but it should be safe to leave it on.

Quoted 5 lines

For completeness, let me also mention that the destination device has to be a hd or sd with an existing major number in the domain where the device will be used.
(in 2.4, cciss might work as well ans here might be support for it to be an xbd but that can go away anytime...).

It's somewhat bizarre that the cciss driver uses its own major/minor rather that the normal scsi disk ones. I'm surprised they were allowed to...

Ian

-------------------------------------------------------
This SF.Net email is sponsored by OSTG. Have you noticed the changes on Linux.com, ITManagersJournal and NewsForge in the past few weeks? Now, one more big change to announce. We are now OSTG- Open Source Technology Group. Come see the changes on the new OSTG site. www.ostg.com

#3 lore raw
Quoted 4 lines · Ian Pratt
Quoted 1 line

- like with all devices, xend will prepend /dev/ to the device name.

xend appends /dev/ if it's not already there, but it should be safe to leave it on.

well, then that needs to be changed in xend because if I change my config file to include the /dev/ part, it fails the same way as observed by Bjoern Sessler.

Error: Error creating domain: [Failure instance: Traceback: xen.xend.XendError.VmError, vbd: Segments not found: uname=phy:/dev/vgtest/root8

christian

-------------------------------------------------------
This SF.Net email is sponsored by OSTG. Have you noticed the changes on Linux.com, ITManagersJournal and NewsForge in the past few weeks? Now, one more big change to announce. We are now OSTG- Open Source Technology Group. Come see the changes on the new OSTG site. www.ostg.com

#4 lore raw
Quoted 9 lines · Ian Pratt
Quoted 4 lines
Quoted 1 line

- like with all devices, xend will prepend /dev/ to the device name.

xend appends /dev/ if it's not already there, but it should be safe to leave it on.

well, then that needs to be changed in xend because if I change my config file to include the /dev/ part, it fails the same way as observed by Bjoern Sessler.

Now believed fixed...

Ian

-------------------------------------------------------
This SF.Net email is sponsored by OSTG. Have you noticed the changes on Linux.com, ITManagersJournal and NewsForge in the past few weeks? Now, one more big change to announce. We are now OSTG- Open Source Technology Group. Come see the changes on the new OSTG site. www.ostg.com

#5 lore raw
In reply to Christian Limpach
Quoted 8 lines · Christian Limpach
Quoted 4 lines · Ian Pratt
Quoted 1 line

- like with all devices, xend will prepend /dev/ to the device name.

xend appends /dev/ if it's not already there, but it should be safe to leave it on.

Quoted 8 lines

well, then that needs to be changed in xend because if I change my config file to include the /dev/ part, it fails the same way as observed by Bjoern Sessler.

Error: Error creating domain: [Failure instance: Traceback: xen.xend.XendError.VmError, vbd: Segments not found: uname=phy:/dev/vgtest/root8

christian

hi,

thanks, it works now. prepending the /dev part was also my second thought too, as the xenU kernel didn't noticed the device called 'swap' or 'root'. first i thought the /dev/vg0/device wasn't recognised correctly and xen would create that dev-entry. but anyhow, i didn't recognised any problems yet and its working with really good performance on that raid0-set

greetz,
bjoern

-------------------------------------------------------
This SF.Net email is sponsored by OSTG. Have you noticed the changes on Linux.com, ITManagersJournal and NewsForge in the past few weeks? Now, one more big change to announce. We are now OSTG- Open Source Technology Group. Come see the changes on the new OSTG site. www.ostg.com