All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Egger <Christoph.Egger@amd.com>
To: Ian Campbell <Ian.Campbell@citrix.com>
Cc: "xen-devel@lists.xen.org" <xen-devel@lists.xen.org>
Subject: Re: libxl: cannot start guest
Date: Mon, 21 May 2012 17:43:42 +0200	[thread overview]
Message-ID: <4FBA62AE.2070207@amd.com> (raw)
In-Reply-To: <1337608191.24660.138.camel@zakaz.uk.xensource.com>

On 05/21/12 15:49, Ian Campbell wrote:

>>> It seems that we have a non-logging failure path in there somewhere. I'm
>>> afraid that the easieist way to fix this is probably just to dive into
>>> libxl__domain_build and add prints on the various error cases of sub
>>> functions, then recurse as you identify which one is failing etc..
>>
>> I did that:
>>
>> Parsing config from /root/hvm-guest/netbsd_64b.conf
>> libxl: debug: libxl_device.c:183:libxl__device_disk_set_backend: Disk
>> vdev=hda spec.backend=unknown
>> libxl: debug: libxl_device.c:219:libxl__device_disk_set_backend: Disk
>> vdev=hda, using backend phy
>> xc: detail: elf_parse_binary: phdr: paddr=0x100000 memsz=0x9bd04
>> xc: detail: elf_parse_binary: memory: 0x100000 -> 0x19bd04
>> xc: info: VIRTUAL MEMORY ARRANGEMENT:
>>   Loader:        0000000000100000->000000000019bd04
>>   TOTAL:         0000000000000000->00000000ff800000
>>   ENTRY ADDRESS: 0000000000100000
>> xc: info: PHYSICAL MEMORY ALLOCATION:
>>   4KB PAGES: 0x0000000000000200
>>   2MB PAGES: 0x00000000000003fb
>>   1GB PAGES: 0x0000000000000002
>> xc: detail: elf_load_binary: phdr 0 at 0x0x7f7ff7f42000 -> 0x0x7f7ff7fd4b74
>> libxl: error: libxl.c:3213:libxl_sched_credit_domain_set: Cpu weight out
>> of range, valid values are within range from 1 to 65535
>> libxl: error: libxl_dom.c:74:libxl__sched_set_params:
>> libxl_sched_credit_domain_set failed -6
>> libxl: error: libxl_dom.c:192:libxl__build_post: libxl__sched_set_params
>> failed -6
>> libxl: error: libxl_create.c:322:libxl__domain_build: libxl__build_post
>> failed: -6
>> libxl: error: libxl_create.c:709:domcreate_bootloader_done: cannot
>> (re-)build domain: -6
>> libxl: error: libxl_dm.c:1104:libxl__destroy_device_model: Couldn't find
>> device model's pid: No such file or directory
>> libxl: error: libxl.c:1162:libxl_domain_destroy:
>> libxl__destroy_device_model failed for 6
>> xc: debug: hypercall buffer: total allocations:1264 total releases:1264
>> xc: debug: hypercall buffer: current allocations:0 maximum allocations:2
>> xc: debug: hypercall buffer: cache current size:2
>> xc: debug: hypercall buffer: cache hits:1261 misses:2 toobig:1
>> libxl: error: libxl.c:155:libxl_ctx_free: libxl_ctx_free: call
>> xs_daemon_close
>>
>>
>> So it is indeed that ERROR_INVAL from that 'benign' error
> 
> In my version of libxl libxl__build_post doesn't even look at the return
> value of libxl__sched_set_params.
>     ....
>     libxl__sched_set_params (gc, domid, &(info->sched_params));
>     ....


I reverted my local change and retried. See below.

 
> the only other exit path from that function is:
>     dom_path = libxl__xs_get_dompath(gc, domid);
>     if (!dom_path) {
>         return ERROR_FAIL;
>     }
> which is consistent with the original errors you had (but if ERROR_FAIL,
> not ERROR_INVAL). This doesn't really help me figure out what is going
> on though :-/




libxl: debug: libxl_device.c:183:libxl__device_disk_set_backend: Disk
vdev=hda spec.backend=unknown
libxl: debug: libxl_device.c:219:libxl__device_disk_set_backend: Disk
vdev=hda, using backend phy
xc: detail: elf_parse_binary: phdr: paddr=0x100000 memsz=0x9bd04
xc: detail: elf_parse_binary: memory: 0x100000 -> 0x19bd04
xc: info: VIRTUAL MEMORY ARRANGEMENT:
  Loader:        0000000000100000->000000000019bd04
  TOTAL:         0000000000000000->00000000ff800000
  ENTRY ADDRESS: 0000000000100000
xc: info: PHYSICAL MEMORY ALLOCATION:
  4KB PAGES: 0x0000000000000200
  2MB PAGES: 0x00000000000003fb
  1GB PAGES: 0x0000000000000002
xc: detail: elf_load_binary: phdr 0 at 0x0x7f7ff7f42000 -> 0x0x7f7ff7fd4b74
libxl: error: libxl.c:3213:libxl_sched_credit_domain_set: Cpu weight out
of range, valid values are within range from 1 to 65535
libxl: error: libxl_dom.c:74:libxl__sched_set_params:
libxl_sched_credit_domain_set failed -6
libxl: debug: libxl_device.c:183:libxl__device_disk_set_backend: Disk
vdev=hda spec.backend=phy
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 7: Bad file descriptor
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 0: Bad file descriptor
libxl: error: libxl_device.c:107:libxl__device_generic_add: xs
transaction failed: Bad file descriptor
libxl: debug: libxl_device.c:183:libxl__device_disk_set_backend: Disk
vdev=hdb spec.backend=phy
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 7: Bad file descriptor
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 0: Bad file descriptor
libxl: error: libxl_device.c:107:libxl__device_generic_add: xs
transaction failed: Bad file descriptor
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 7: Bad file descriptor
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 0: Bad file descriptor
libxl: error: libxl_device.c:107:libxl__device_generic_add: xs
transaction failed: Bad file descriptor
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 7: Bad file descriptor
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 0: Bad file descriptor
libxl: error: libxl_device.c:107:libxl__device_generic_add: xs
transaction failed: Bad file descriptor
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 7: Bad file descriptor
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 0: Bad file descriptor
libxl: error: libxl_device.c:107:libxl__device_generic_add: xs
transaction failed: Bad file descriptor
libxl: error: libxl_xshelp.c:102:libxl__xs_get_dompath: failed to get
dompath for 7: Bad file descriptor
libxl: debug: libxl_dm.c:1008:libxl__spawn_local_dm: Spawning
device-model /usr/local.25371.netbsd/libexec/qemu-dm with arguments:
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:
/usr/local.25371.netbsd/libexec/qemu-dm
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -d
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   7
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -domain-name
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   HVM64-NetBSD
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -vnc
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   0.0.0.0:0
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -vncunused
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -serial
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   pty
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -videoram
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   8
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -boot
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   cd
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -acpi
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -vcpus
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   4
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -vcpu_avail
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   0xf
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -net
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:
nic,vlan=0,macaddr=00:16:3e:00:ce:01,model=e1000
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -net
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:
tap,vlan=0,ifname=vif7.0-emu,bridge=bridge0,script=/usr/local.25371.netbsd/etc/xen/scripts/qemu-ifup,downscript=/usr/local.25371.netbsd/etc/xen/scripts/qemu-ifup
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   -M
libxl: debug: libxl_dm.c:1010:libxl__spawn_local_dm:   xenfv
libxl: error: libxl_event.c:468:libxl__ev_xswatch_register: create watch
for path /local/domain/0/device-model/7/state: Bad file descriptor
libxl: error: libxl_dm.c:1072:device_model_spawn_outcome: domain 7
device model: spawn failed (rc=-3)
assertion "ao->in_initiator" failed: file "libxl_event.c", line 1388,
function "libxl__ao_complete_check_progress_reports"
Abort (core dumped)

(gdb) bt
#0  0x00007f7ff65059aa in _lwp_kill () from /usr/lib/libc.so.12
#1  0x00007f7ff6505612 in abort () from /usr/lib/libc.so.12
#2  0x00007f7ff65052dd in __assert13 () from /usr/lib/libc.so.12
#3  0x00007f7ff742d114 in libxl__ao_complete_check_progress_reports (
    egc=0x7f7fffffd140, ao=0x7f7ff7b210e0) at libxl_event.c:1388
#4  0x00007f7ff742d2ec in egc_run_callbacks (egc=0x7f7fffffd140)
    at libxl_event.c:971
#5  libxl__egc_cleanup (egc=0x7f7fffffd140) at libxl_event.c:991
#6  0x00007f7ff741890f in do_domain_create (ctx=0x7f7ff7b210b8,
    d_config=<optimized out>, domid=<optimized out>,
restore_fd=<optimized out>,
    ao_how=<optimized out>, aop_console_how=0x7f7fffffffff) at
libxl_create.c:905
#7  0x00007f7ff741893e in libxl_domain_create_new (ctx=<optimized out>,
    d_config=<optimized out>, domid=<optimized out>, ao_how=<optimized
out>,
    aop_console_how=<optimized out>) at libxl_create.c:926
#8  0x000000000040c4d9 in create_domain (dom_info=0x7f7fffffd630)
    at xl_cmdimpl.c:1760
#9  0x0000000000410161 in main_create (argc=3, argv=<optimized out>)
    at xl_cmdimpl.c:3730
#10 0x0000000000406d86 in main (argc=3, argv=0x7f7fffffdba0) at xl.c:208

Christoph

-- 
---to satisfy European Law for business letters:
Advanced Micro Devices GmbH
Einsteinring 24, 85689 Dornach b. Muenchen
Geschaeftsfuehrer: Alberto Bozzo, Andrew Bowd
Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen
Registergericht Muenchen, HRB Nr. 43632

  reply	other threads:[~2012-05-21 15:43 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-18 13:17 libxl: cannot start guest Christoph Egger
2012-05-18 13:30 ` Ian Campbell
2012-05-18 14:23   ` Christoph Egger
2012-05-18 15:51     ` Christoph Egger
2012-05-18 15:58       ` Ian Campbell
2012-05-21 10:26         ` Christoph Egger
2012-05-21 12:15           ` Ian Campbell
2012-05-21 13:10             ` Christoph Egger
2012-05-21 13:49               ` Ian Campbell
2012-05-21 15:43                 ` Christoph Egger [this message]
2012-05-21 15:44                 ` Christoph Egger
2012-05-21 15:57                   ` Ian Campbell
2012-05-21 16:11                     ` Ian Jackson
2012-05-22 12:35                     ` Christoph Egger
2012-05-22 12:53                       ` Ian Campbell
2012-05-22 13:17                         ` Christoph Egger
2012-05-22 13:18                         ` Christoph Egger
2012-05-22 13:21                           ` Ian Campbell
2012-05-22 14:03                             ` Christoph Egger
2012-05-22 14:20                               ` Ian Campbell
2012-05-22 15:16                                 ` Christoph Egger
2012-05-22 15:21                                   ` Ian Campbell
2012-05-22 15:32                                     ` Christoph Egger
2012-05-23 10:11                                       ` Ian Campbell
2012-05-24  9:44                                         ` Christoph Egger
2012-05-25 14:56                                           ` Roger Pau Monne
2012-05-25 15:42                                             ` Ian Campbell
2012-05-29 10:02                                         ` Ian Jackson
2012-05-29 10:13                                           ` Ian Campbell
2012-05-22 13:21                           ` Christoph Egger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4FBA62AE.2070207@amd.com \
    --to=christoph.egger@amd.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.