xl doesn't handle disk scripts correctly

Bug #1505287 reported by Vladimír Dudr
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
xen (Ubuntu)
New
Undecided
Unassigned

Bug Description

When set as follows

disk = [ 'script=block-drbd, vdev=xvda2, access=rw, target=domu-disk' ]

where domu-disk is drbd resource ( can be found as /dev/drbd_domu-disk).

xl create does start drbd-block script AFTER trying to attach disk and launching bootloader, which results in fail as drbd resource cannot be mounted in secondary role.

When conf changed to use target=/dev/drbd_domu-disk and setting drbd resource to primary I can observer starting domain and crashing the drbd-block (obviously, as /dev/drbd_domu-disk is not resource name), but it proves that the script is fired after bootloader.

The script will be launched and disk attached correctly when using kernel and ramdisk from outside of domu, which proves the wrong order of firing the scripts and correctness of drbd-block itself.

/etc/xen/scripts/drbd-block I use had to be modified to work at least this way. My diff is attached. When not modified the script just exits, because xl does not have drbd backend and thus passing phy as backend type.

There are some interesting talks in this thread: http://www.gossamer-threads.com/lists/xen/users/380921 containing also some kind of patch

Revision history for this message
Vladimír Dudr (vlada-dudr) wrote :
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.