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

Re: [Xen-devel] block-iscsi with Xen 4.5 / 4.6



On 2016-04-15 18:11, Steven Haigh wrote:
On 2016-04-15 18:03, Roger Pau Monné wrote:
On Fri, Apr 15, 2016 at 05:48:24PM +1000, Steven Haigh wrote:
On 2016-04-15 17:46, Roger Pau Monné wrote:
> On Fri, Apr 15, 2016 at 05:28:12PM +1000, Steven Haigh wrote:
> > On 2016-04-15 17:23, Roger Pau Monné wrote:
> > > On Fri, Apr 15, 2016 at 04:59:11PM +1000, Steven Haigh wrote:
> > > > Hi all,
> > > >
> > > > I'm wading through the somewhat confusing world of documentation
> > > > regarding
> > > > storing DomU disk images on an iSCSI target.
> > > >
> > > > I'm getting an error when using pygrub of:
> > > > OSError: [Errno 2] No such file or directory: 
'iqn=iqn.1986-03.com.sun:02:ff2d12c0-b709-4ec0-999d-976506c666f5,portal=192.168.133.250'
> > >
> > > Hello,
> > >
> > > It should work. Can you please paste your guest configuration file and
> > > the
> > > output of the create command with "-vvv"?
> >
> > DomU config file:
> > bootloader      = "pygrub"
> > name            = "test1.vm"
> > memory          = 2048
> > vcpus           = 2
> > cpus            = "1-7"
> > vif             = ['bridge=br-151, vifname=vm.test1']
> > disk            = 
['script=block-iscsi,vdev=xvda,target=iqn=iqn.1986-03.com.sun:02:ff2d12c0-b709-4ec0-999d-976506c666f5,portal=192.168.133.250']
> > boot            = "c"
> >
> > # xl create /etc/xen/test1.vm -d -c
>
> Please post the output of xl -vvv create /etc/xen/test1.vm.

Whoops - apologies:

# xl -vvv create /etc/xen/test1.vm
Parsing config from /etc/xen/test1.vm
libxl: debug: libxl_create.c:1507:do_domain_create: ao 0x20b7260: create:
how=(nil) callback=(nil) poller=0x20b6b30
libxl: debug: libxl_device.c:269:libxl__device_disk_set_backend: Disk
vdev=xvda spec.backend=unknown
libxl: debug: libxl_device.c:207:disk_try_backend: Disk vdev=xvda, uses
script=... assuming phy backend
libxl: debug: libxl_device.c:298:libxl__device_disk_set_backend: Disk
vdev=xvda, using backend phy
libxl: debug: libxl_create.c:907:initiate_domain_create: running bootloader
libxl: debug: libxl_device.c:269:libxl__device_disk_set_backend: Disk
vdev=(null) spec.backend=phy
libxl: debug: libxl_device.c:207:disk_try_backend: Disk vdev=(null), uses
script=... assuming phy backend
libxl: debug: libxl.c:3064:libxl__device_disk_local_initiate_attach: locally attaching PHY disk iqn=iqn.1986-03.com.sun:02:ff2d12c0-b709-4ec0-999d-976506c666f5,portal=192.168.133.250

Now I remember, this was fixed not long ago, you will need to apply
b1882a424ae098d722b19086b16e64b9aeccc7ca to your source tree/package in
order to get pygrub working with hotplug scripts [0].

I guess you are using Xen 4.5, because this commit is already present in Xen
4.6, and it should fix your issue.

[0]
http://xenbits.xen.org/gitweb/?p=xen.git;a=commit;h=b1882a424ae098d722b19086b16e64b9aeccc7ca

Ahhh - thanks for the pointer. As this is a dev system, its probably
easier for me to upgrade it to Xen 4.6 - however I'll take that commit
and look at adding it to my Xen 4.5 packages for public consumption.

I might have spoken too soon here... I updated this system to 4.6.1 and created the DomU again - still seems to fail - although it does actually call the block-iscsi script this time:

# xl -vvv create /etc/xen/test1.vm
Parsing config from /etc/xen/test1.vm
libxl: debug: libxl_create.c:1560:do_domain_create: ao 0x24ad330: create: how=(nil) callback=(nil) poller=0x24b7070 libxl: debug: libxl_device.c:269:libxl__device_disk_set_backend: Disk vdev=xvda spec.backend=unknown libxl: debug: libxl_device.c:207:disk_try_backend: Disk vdev=xvda, uses script=... assuming phy backend libxl: debug: libxl_device.c:298:libxl__device_disk_set_backend: Disk vdev=xvda, using backend phy libxl: debug: libxl_create.c:945:initiate_domain_create: running bootloader libxl: debug: libxl_device.c:269:libxl__device_disk_set_backend: Disk vdev=(null) spec.backend=phy libxl: debug: libxl_device.c:207:disk_try_backend: Disk vdev=(null), uses script=... assuming phy backend libxl: debug: libxl_device.c:269:libxl__device_disk_set_backend: Disk vdev=xvde spec.backend=phy libxl: debug: libxl_device.c:207:disk_try_backend: Disk vdev=xvde, uses script=... assuming phy backend libxl: debug: libxl_event.c:639:libxl__ev_xswatch_register: watch w=0x24ada00 wpath=/local/domain/0/backend/vbd/0/51776/state token=3/0: register slotnum=3 libxl: debug: libxl_create.c:1583:do_domain_create: ao 0x24ad330: inprogress: poller=0x24b7070, flags=i libxl: debug: libxl_event.c:576:watchfd_callback: watch w=0x24ada00 wpath=/local/domain/0/backend/vbd/0/51776/state token=3/0: event epath=/local/domain/0/backend/vbd/0/51776/state libxl: debug: libxl_event.c:884:devstate_callback: backend /local/domain/0/backend/vbd/0/51776/state wanted state 2 still waiting state 1 libxl: debug: libxl_event.c:576:watchfd_callback: watch w=0x24ada00 wpath=/local/domain/0/backend/vbd/0/51776/state token=3/0: event epath=/local/domain/0/backend/vbd/0/51776/state libxl: debug: libxl_event.c:880:devstate_callback: backend /local/domain/0/backend/vbd/0/51776/state wanted state 2 ok libxl: debug: libxl_event.c:677:libxl__ev_xswatch_deregister: watch w=0x24ada00 wpath=/local/domain/0/backend/vbd/0/51776/state token=3/0: deregister slotnum=3 libxl: debug: libxl_device.c:937:device_backend_callback: calling device_backend_cleanup libxl: debug: libxl_event.c:691:libxl__ev_xswatch_deregister: watch w=0x24ada00: deregister unregistered libxl: debug: libxl_linux.c:229:libxl__hotplug_disk: Args and environment ready libxl: debug: libxl_device.c:1034:device_hotplug: calling hotplug script: /etc/xen/scripts/block-iscsi add libxl: debug: libxl_aoutils.c:593:libxl__async_exec_start: forking to execute: /etc/xen/scripts/block-iscsi add libxl: error: libxl_exec.c:118:libxl_report_child_exitstatus: /etc/xen/scripts/block-iscsi add [2126] exited with error status 1 libxl: debug: libxl_event.c:691:libxl__ev_xswatch_deregister: watch w=0x24adb00: deregister unregistered libxl: error: libxl_device.c:1084:device_hotplug_child_death_cb: script: Device already opened libxl: debug: libxl_event.c:691:libxl__ev_xswatch_deregister: watch w=0x24adb00: deregister unregistered libxl: error: libxl.c:3127:local_device_attach_cb: unable to add vbd with id 51776: Interrupted system call libxl: error: libxl_bootloader.c:408:bootloader_disk_attached_cb: failed to attach local disk for bootloader execution libxl: debug: libxl_event.c:691:libxl__ev_xswatch_deregister: watch w=0x24add18: deregister unregistered libxl: error: libxl_bootloader.c:279:bootloader_local_detached_cb: unable to detach locally attached disk libxl: error: libxl_create.c:1142:domcreate_rebuild_done: cannot (re-)build domain: -3 libxl: debug: libxl.c:1719:devices_destroy_cb: forked pid 2154 for destroy of domain 7 libxl: debug: libxl_event.c:1874:libxl__ao_complete: ao 0x24ad330: complete, rc=-3 libxl: debug: libxl_event.c:1843:libxl__ao__destroy: ao 0x24ad330: destroy libxl: debug: libxl.c:1458:libxl_domain_destroy: ao 0x24acf80: create: how=(nil) callback=(nil) poller=0x24b7070
libxl: error: libxl.c:1591:libxl__destroy_domid: non-existant domain 7
libxl: error: libxl.c:1549:domain_destroy_callback: unable to destroy guest with domid 7 libxl: error: libxl.c:1476:domain_destroy_cb: destruction of domain 7 failed libxl: debug: libxl_event.c:1874:libxl__ao_complete: ao 0x24acf80: complete, rc=-21 libxl: debug: libxl.c:1467:libxl_domain_destroy: ao 0x24acf80: inprogress: poller=0x24b7070, flags=ic libxl: debug: libxl_event.c:1843:libxl__ao__destroy: ao 0x24acf80: destroy
xc: debug: hypercall buffer: total allocations:49 total releases:49
xc: debug: hypercall buffer: current allocations:0 maximum allocations:2
xc: debug: hypercall buffer: cache current size:2
xc: debug: hypercall buffer: cache hits:38 misses:2 toobig:9

So - thinking about the parameters passed to block-iscsi...

I haven't verified that this parameter set is correct - however I can use the string pasted into the config file with iscsiadm and --login to connect - and I also see:
# iscsiadm -m discovery -t sendtargets -p 192.168.133.250
192.168.133.250:3260,-1 iqn.1986-03.com.sun:02:ff2d12c0-b709-4ec0-999d-976506c666f5

As such, I *think* that my config is correct in this case - but I'm not supremely confident there.

--
Steven Haigh

Email: netwiz@xxxxxxxxx
Web: https://www.crc.id.au
Phone: (03) 9001 6090 - 0412 935 897

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel

 


Rackspace

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