Re: [Fedora-xen] [f20] Problem with libvirt + Xen XL toolstack
by Marco Guazzone
Hi Jim,
On Mon, Nov 24, 2014 at 6:09 PM, Jim Fehlig <jfehlig(a)suse.com> wrote:
> Hi Marco,
>
> Sorry for the delay. I'm not ignoring your mails, just too busy with
> travel, recuperating from sickness, etc. to investigate and respond...
>
No problem. I'm always in hurry as well.
Thank you for the time you spend in this list
>
>
> The duplicate <boot> entries are the result of a bug in the
> DomainXMLFromNative function. I just verified the bug still exists in
> libvirt git master.
ok
>
> Sigh. More bugs in DomainXMLFromNative. Can you verify if <hap/> is
> explicitly needed? IIRC, Xen will automatically use hap if supported by the
> hardware.
>
You're right. As stated here:
http://xenbits.xen.org/docs/unstable/man/xl.cfg.5.html
hap is True if supported.
Also, apic is True by default
So, I've commented the "hap" and "apic" elements. No problem encountered.
>> This time, the installation of the guest system seems to work.
>> I still have some annoying problem with the CentOS graphical
>> installation since the installation GUI immediately disappears with
>> the following message:
>> ** (anaconda:1049): WARNING **: keybinder_init: Unable to open display
>> (anaconda:1049): Gdk-WARNING **: anaconda: Fatal IO Error 0
>> (Success) on X server :1.
>> Pane is dead
>> and the installation program remains stuck.
>> I've also tried to start the installation in the basic graphics mode.
>> But the problem remains.
>
>
> Do you also see this problem when starting the domain directly with xl?
>
Yes. The installation GUI appears, then I move the mouse and the GUI
disappears and I remains with the above error message.
> FYI, it may be some time before I have a chance to track down and fix these
> bugs. Are you able to help contribute in this area?
>
Not so much, sorry! I'm overloaded of work and I have some deadlines
for my research.
Anyway, I can perform some test if you need in the next few days, at
least until I start my experiments.
In fact, from that moment, I can use the experimental testbed only for
stuff related to research experiments.
Cheers,
-- Marco
8 years, 10 months
Re: [Fedora-xen] [f20] Problem with libvirt + Xen XL toolstack
by Marco Guazzone
On Thu, Nov 13, 2014 at 1:08 AM, Jim Fehlig <jfehlig(a)suse.com> wrote:
>
> Can you provide
>
Sure!
> 1. the config you use with xl
name = "testvm"
uuid = "93f08541-bfd5-4ac4-851d-c619a4516a13"
kernel = "/usr/lib/xen/boot/hvmloader"
builder = "hvm"
maxmem = 3072
memory = 2048
vcpus = 1
on_crash = "restart"
disk = [ "file:/root/images/test.img,hda,w",
"file:/root/iso/CentOS-7.0-1406-x86_64-Minimal.iso,hdc:cdrom,r" ]
vif = [ "bridge=xenbr0,script=vif-bridge" ]
boot = "cd"
sdl = 0
vnc = 1
vncunused = 1
xen_platform_pci = 1
> 2. the XML config you use with libvirt
<domain type='xen'>
<name>testvm</name>
<uuid>93f08541-bfd5-4ac4-851d-c619a4516a13</uuid>
<memory unit='KiB'>3145728</memory>
<currentMemory unit='KiB'>2097152</currentMemory>
<vcpu placement='static'>1</vcpu>
<os>
<type arch='x86_64' machine='xenfv'>hvm</type>
<loader>/usr/lib/xen/boot/hvmloader</loader>
<boot dev='hd'/>
<!--
<boot dev='hd'/>
-->
</os>
<clock offset='variable' adjustment='0' basis='utc'/>
<on_poweroff>destroy</on_poweroff>
<on_reboot>restart</on_reboot>
<on_crash>restart</on_crash>
<devices>
<disk type='file' device='disk'>
<!--
<driver name='file'/>
-->
<driver name='qemu'/>
<source file='/root/images/test.img'/>
<target dev='hda' bus='ide'/>
</disk>
<disk type='file' device='cdrom'>
<!--
<driver name='file'/>
-->
<driver name='qemu'/>
<source file='/root/iso/CentOS-7.0-1406-x86_64-Minimal.iso'/>
<target dev='hdc' bus='ide'/>
<readonly/>
</disk>
<interface type='bridge'>
<mac address='00:00:00:00:00:00'/>
<source bridge='xenbr0'/>
<script path='vif-bridge'/>
</interface>
<input type='mouse' bus='ps2'/>
<graphics type='vnc' port='-1' autoport='yes'/>
</devices>
</domain>
> 3. the qemu command line libxl generated for each case?
QEMU command for "xl create testvm.cfg":
/usr/lib/xen/bin/qemu-dm -d 11 -domain-name testvm -vnc 127.0.0.1:0
-vncunused -videoram 8 -boot cd -acpi -vcpu_avail 0x01 -net
nic,vlan=0,macaddr=00:16:3e:5c:c2:5a,model=rtl8139 -net
tap,vlan=0,ifname=vif11.0-emu,bridge=xenbr0,script=no,downscript=no -M
xenfv
QEMU command for "virsh create testvm.xml":
/usr/lib/xen/bin/qemu-dm -d 12 -domain-name testvm -vnc 127.0.0.1:1
-videoram 8 -boot c -vcpu_avail 0x01 -net none -M xenfv
Thanks so much.
Best,
-- Marco
8 years, 10 months
Re: [Fedora-xen] Xen 4.4 RC2 [TestDay]
by M A Young
On Mon, 20 Jan 2014, Eric Houby wrote:
> The first issue I hit was:
>
> [root@astar ~]# xl create mars.xl
> Parsing config from mars.xl
> libxl: error: libxl_create.c:1034:domcreate_launch_dm: unable to add
> disk devices
> libxl: error: libxl_dm.c:1467:kill_device_model: unable to find device
> model pid in /local/domain/1/image/device-model-pid
> libxl: error: libxl.c:1425:libxl__destroy_domid:
> libxl__destroy_device_model failed for 1
> libxl: error: libxl_device.c:780:libxl__initiate_device_remove: unable
> to get my domid
> libxl: error: libxl.c:1461:devices_destroy_cb: libxl__devices_destroy
> failed for 1
>
> After some discussion about the xencommons init script and ExecStartPost
> in xenstored.service, it was determined that manually
> running /usr/bin/xenstore-write "/local/domain/0/domid" 0 would fix the
> issue.
Was xenstored.service enabled? That should have set up the environment
correctly.
> [root@astar ~]# xl create mars.xl
> Parsing config from mars.xl
> libxl: error: libxl_dm.c:1371:device_model_spawn_outcome: domain 6
> device model: spawn failed (rc=-3)
> libxl: error: libxl_create.c:1166:domcreate_devmodel_started: device
> model did not start: -3
> libxl: error: libxl_dm.c:1475:kill_device_model: Device Model already
> exited
>
> My qemu-dm-mars log file contained one line, Option xen-domid not
> supported for this target. This error led those helping to question
> about my qemu version and whether or not it supported xen.
One of the experiments I was intending to do with that build was to see if
xen would would work with Fedora's qemu. As you have just discovered the
answer is no, though the tools configuration option allowing you tell xen
where to find it seems to work. If you uninstall the qemu-system-x86
package or add the line
device_model_version="qemu-xen-traditional"
to your configuration file then your hvm guest should boot.
Michael Young
8 years, 10 months
Re: [Fedora-xen] [f20] Problem with libvirt + Xen XL toolstack
by Marco Guazzone
On Wed, Nov 12, 2014 at 4:28 PM, Jim Fehlig <jfehlig(a)suse.com> wrote:
>
> This says the device model (which appears to be qemu-dm in your case)
> failed to run. /var/log/xen/qemu-dm-<vm_name>.log should have some info
> telling why qemu failed.
>
It says:
domid: 2
Boot device 'c' was given twice
Looking at the XML, I see there are two "boot" elements. So I've tried
to comment one of them:
<os>
<type arch='x86_64' machine='xenfv'>hvm</type>
<loader>/usr/lib/xen/boot/hvmloader</loader>
<boot dev='hd'/>
<!--
<boot dev='hd'/>
-->
</os>
Interestingly, these two elements were generated by libvirt with
"virsh -c xen:/// domxml-from-native xen-xm testvm.cfg"
Then, I've tried to start the VM with "virsh create", but still problems.
Appartently, it seemed to work since I see it as "running" with "virsh list".
However, (1) I'm unable to connect with vncviewer, and (2) after a
while the VM stops.
Here below is the content of the logs:
/var/log/libvirt/libxl/testvm.log:
libxl: verbose:
libxl_create.c:130:libxl__domain_build_info_setdefault: qemu-xen is
unavailable, use qemu-xen-traditional instead: No such file or
directory
libxl: debug: libxl_create.c:1243:do_domain_create: ao 0x7fb678002900:
create: how=(nil) callback=(nil) poller=0x7fb6780011b0
libxl: debug: libxl_device.c:257:libxl__device_disk_set_backend: Disk
vdev=hda spec.backend=qdisk
libxl: debug: libxl_device.c:257:libxl__device_disk_set_backend: Disk
vdev=hdc spec.backend=qdisk
libxl: debug: libxl_create.c:699:initiate_domain_create: running bootloader
libxl: debug: libxl_bootloader.c:321:libxl__bootloader_run: not a PV
domain, skipping bootloader
libxl: debug: libxl_event.c:608:libxl__ev_xswatch_deregister: watch
w=0x7fb678002c88: deregister unregistered
libxl: debug: libxl_numa.c:478:libxl__get_numa_candidate: New best
NUMA placement candidate found: nr_nodes=1, nr_cpus=8, nr_vcpus=17,
free_memkb=2698
libxl: detail: libxl_dom.c:195:numa_place_domain: NUMA placement
candidate with 1 nodes, 8 cpus and 2698 KB free selected
xc: detail: elf_parse_binary: phdr: paddr=0x100000 memsz=0xa2304
xc: detail: elf_parse_binary: memory: 0x100000 -> 0x1a2304
xc: info: VIRTUAL MEMORY ARRANGEMENT:
Loader: 0000000000100000->00000000001a2304
Modules: 0000000000000000->0000000000000000
TOTAL: 0000000000000000->00000000bf800000
ENTRY ADDRESS: 0000000000100000
xc: info: PHYSICAL MEMORY ALLOCATION:
4KB PAGES: 0x0000000000000200
2MB PAGES: 0x00000000000003fb
1GB PAGES: 0x0000000000000001
xc: detail: elf_load_binary: phdr 0 at 0x7fb6a7af8000 -> 0x7fb6a7b9118d
libxl: debug: libxl_device.c:257:libxl__device_disk_set_backend: Disk
vdev=hda spec.backend=qdisk
libxl: debug: libxl_device.c:257:libxl__device_disk_set_backend: Disk
vdev=hdc spec.backend=qdisk
libxl: debug: libxl_dm.c:1211:libxl__spawn_local_dm: Spawning
device-model /usr/lib/xen/bin/qemu-dm with arguments:
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: /usr/lib/xen/bin/qemu-dm
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -d
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: 9
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -domain-name
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: testvm
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -vnc
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: 127.0.0.1:1
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -videoram
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: 8
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -boot
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: c
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -vcpu_avail
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: 0x01
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -net
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: none
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -M
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: xenfv
libxl: debug: libxl_event.c:559:libxl__ev_xswatch_register: watch
w=0x7fb678002ec0 wpath=/local/domain/0/device-model/9/state token=3/0:
register slotnum=3
libxl: debug: libxl_create.c:1256:do_domain_create: ao 0x7fb678002900:
inprogress: poller=0x7fb6780011b0, flags=i
libxl: debug: libxl_event.c:503:watchfd_callback: watch
w=0x7fb678002ec0 wpath=/local/domain/0/device-model/9/state token=3/0:
event epath=/local/domain/0/device-model/9/state
libxl: debug: libxl_event.c:503:watchfd_callback: watch
w=0x7fb678002ec0 wpath=/local/domain/0/device-model/9/state token=3/0:
event epath=/local/domain/0/device-model/9/state
libxl: debug: libxl_event.c:596:libxl__ev_xswatch_deregister: watch
w=0x7fb678002ec0 wpath=/local/domain/0/device-model/9/state token=3/0:
deregister slotnum=3
libxl: debug: libxl_event.c:608:libxl__ev_xswatch_deregister: watch
w=0x7fb678002ec0: deregister unregistered
libxl: debug: libxl_event.c:559:libxl__ev_xswatch_register: watch
w=0x7fb678006b18 wpath=/local/domain/0/backend/vif/9/0/state
token=3/1: register slotnum=3
libxl: debug: libxl_event.c:503:watchfd_callback: watch
w=0x7fb678006b18 wpath=/local/domain/0/backend/vif/9/0/state
token=3/1: event epath=/local/domain/0/backend/vif/9/0/state
libxl: debug: libxl_event.c:643:devstate_watch_callback: backend
/local/domain/0/backend/vif/9/0/state wanted state 2 ok
libxl: debug: libxl_event.c:596:libxl__ev_xswatch_deregister: watch
w=0x7fb678006b18 wpath=/local/domain/0/backend/vif/9/0/state
token=3/1: deregister slotnum=3
libxl: debug: libxl_event.c:608:libxl__ev_xswatch_deregister: watch
w=0x7fb678006b18: deregister unregistered
libxl: debug: libxl_device.c:959:device_hotplug: calling hotplug
script: /etc/xen/scripts/vif-bridge online
libxl: debug: libxl_event.c:1737:libxl__ao_progress_report: ao
0x7fb678002900: progress report: ignored
libxl: debug: libxl_event.c:1569:libxl__ao_complete: ao
0x7fb678002900: complete, rc=0
libxl: debug: libxl_event.c:1541:libxl__ao__destroy: ao 0x7fb678002900: destroy
libxl: debug: libxl_event.c:559:libxl__ev_xswatch_register: watch
w=0x7fb678001cf0 wpath=@releaseDomain token=3/2: register slotnum=3
libxl: debug: libxl_event.c:503:watchfd_callback: watch
w=0x7fb678001cf0 wpath=@releaseDomain token=3/2: event
epath=@releaseDomain
libxl: debug: libxl.c:1004:domain_death_xswatch_callback:
[evg=0x7fb678001810:9] from domid=9 nentries=1 rc=1
libxl: debug: libxl.c:1015:domain_death_xswatch_callback:
[evg=0x7fb678001810:9] got=domaininfos[0] got->domain=9
libxl: debug: libxl.c:1042:domain_death_xswatch_callback: exists
shutdown_reported=0 dominf.flags=ffff0022
libxl: debug: libxl.c:1008:domain_death_xswatch_callback: [evg=0] all reported
libxl: debug: libxl.c:1072:domain_death_xswatch_callback: domain death
search done
libxl: debug: libxl_event.c:503:watchfd_callback: watch
w=0x7fb678001cf0 wpath=@releaseDomain token=3/2: event
epath=@releaseDomain
libxl: debug: libxl.c:1004:domain_death_xswatch_callback:
[evg=0x7fb678001810:9] from domid=9 nentries=1 rc=1
libxl: debug: libxl.c:1015:domain_death_xswatch_callback:
[evg=0x7fb678001810:9] got=domaininfos[0] got->domain=9
libxl: debug: libxl.c:1042:domain_death_xswatch_callback: exists
shutdown_reported=0 dominf.flags=6
libxl: debug: libxl.c:1054:domain_death_xswatch_callback: shutdown reporting
libxl: debug: libxl.c:1008:domain_death_xswatch_callback: [evg=0] all reported
libxl: debug: libxl.c:1072:domain_death_xswatch_callback: domain death
search done
libxl: debug: libxl_event.c:1154:egc_run_callbacks: event
0x7fb6a99f1ad0 callback type=domain_shutdown
libxl: debug: libxl.c:1256:libxl_domain_destroy: ao 0x7fb6a99f1b60:
create: how=(nil) callback=(nil) poller=0x7fb6780011b0
libxl: debug: libxl_dm.c:1314:libxl__destroy_device_model: Device Model signaled
libxl: debug: libxl_event.c:559:libxl__ev_xswatch_register: watch
w=0x7fb6a99f08a8 wpath=/local/domain/0/backend/vif/9/0/state
token=2/3: register slotnum=2
libxl: debug: libxl.c:1265:libxl_domain_destroy: ao 0x7fb6a99f1b60:
inprogress: poller=0x7fb6780011b0, flags=i
libxl: debug: libxl_event.c:503:watchfd_callback: watch
w=0x7fb6a99f08a8 wpath=/local/domain/0/backend/vif/9/0/state
token=2/3: event epath=/local/domain/0/backend/vif/9/0/state
libxl: debug: libxl_event.c:643:devstate_watch_callback: backend
/local/domain/0/backend/vif/9/0/state wanted state 6 ok
libxl: debug: libxl_event.c:596:libxl__ev_xswatch_deregister: watch
w=0x7fb6a99f08a8 wpath=/local/domain/0/backend/vif/9/0/state
token=2/3: deregister slotnum=2
libxl: debug: libxl_event.c:608:libxl__ev_xswatch_deregister: watch
w=0x7fb6a99f08a8: deregister unregistered
libxl: debug: libxl_device.c:959:device_hotplug: calling hotplug
script: /etc/xen/scripts/vif-bridge offline
libxl: debug: libxl_event.c:472:watchfd_callback: watch
epath=/local/domain/0/backend/vif/9/0/state token=2/3: empty slot
libxl: debug: libxl_event.c:472:watchfd_callback: watch
epath=/local/domain/0/backend/vif/9/0/state token=2/3: empty slot
libxl: debug: libxl_event.c:1569:libxl__ao_complete: ao
0x7fb6a99f1b60: complete, rc=0
libxl: debug: libxl_event.c:1541:libxl__ao__destroy: ao 0x7fb6a99f1b60: destroy
libxl: debug: libxl_event.c:596:libxl__ev_xswatch_deregister: watch
w=0x7fb678001cf0 wpath=@releaseDomain token=3/2: deregister slotnum=3
libxl: debug: libxl_event.c:472:watchfd_callback: watch
epath=@releaseDomain token=3/2: empty slot
/var/log/xen/qemu-dm-testvm.log:
domid: 9
-videoram option does not work with cirrus vga device model. Videoram set to 4M.
Strip off blktap sub-type prefix to /root/images/testvm.img (drv 'aio')
Using file /root/images/testvm.img in read-write mode
Strip off blktap sub-type prefix to
/root/iso/CentOS-7.0-1406-x86_64-Minimal.iso (drv 'aio')
Using file /root/iso/CentOS-7.0-1406-x86_64-Minimal.iso in read-only mode
Watching /local/domain/0/device-model/9/logdirty/cmd
Watching /local/domain/0/device-model/9/command
Watching /local/domain/9/cpu
qemu_map_cache_init nr_buckets = 10000 size 4194304
shared page at pfn feffd
buffered io page at pfn feffb
Guest uuid = 93f08541-bfd5-4ac4-851d-c619a4516a13
populating video RAM at ff000000
mapping video RAM from ff000000
Register xen platform.
Done register platform.
platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw state.
xs_read(/local/domain/0/device-model/9/xen_extended_power_mgmt): read error
xs_read(): vncpasswd get error.
/vm/93f08541-bfd5-4ac4-851d-c619a4516a13/vncpasswd.
medium change watch on `hdc' (index: 1):
aio:/root/iso/CentOS-7.0-1406-x86_64-Minimal.iso
I/O request not ready: 0, ptr: 0, port: 0, data: 0, count: 0, size: 0
Log-dirty: no command yet.
vcpu-set: watch node error.
[xenstore_process_vcpu_set_event]: /local/domain/9/cpu has no CPU!
xs_read(/local/domain/9/log-throttling): read error
qemu: ignoring not-understood drive `/local/domain/9/log-throttling'
medium change watch on `/local/domain/9/log-throttling' - unknown
device, ignored
cirrus vga map change while on lfb mode
mapping vram to f0000000 - f0400000
platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw state.
platform_fixed_ioport: changed ro/rw state of ROM memory area. now is ro state.
Just FYI, I've tried to start the VM directly with "xl" and it works:
the VM runs and vncviewer happily connects.
Here's the content of /var/log/xen/qemu-dm-testvm.log:
domid: 10
-videoram option does not work with cirrus vga device model. Videoram set to 4M.
Strip off blktap sub-type prefix to /root/images/testvm.img (drv 'aio')
Using file /root/images/testvm.img in read-write mode
Strip off blktap sub-type prefix to
/root/iso/CentOS-7.0-1406-x86_64-Minimal.iso (drv 'aio')
Using file /root/iso/CentOS-7.0-1406-x86_64-Minimal.iso in read-only mode
Watching /local/domain/0/device-model/10/logdirty/cmd
Watching /local/domain/0/device-model/10/command
Watching /local/domain/10/cpu
qemu_map_cache_init nr_buckets = 10000 size 4194304
shared page at pfn feffd
buffered io page at pfn feffb
Guest uuid = 93f08541-bfd5-4ac4-851d-c619a4516a13
populating video RAM at ff000000
mapping video RAM from ff000000
Register xen platform.
Done register platform.
platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw state.
xs_read(/local/domain/0/device-model/10/xen_extended_power_mgmt): read error
xs_read(): vncpasswd get error.
/vm/93f08541-bfd5-4ac4-851d-c619a4516a13/vncpasswd.
medium change watch on `hdc' (index: 1):
aio:/root/iso/CentOS-7.0-1406-x86_64-Minimal.iso
I/O request not ready: 0, ptr: 0, port: 0, data: 0, count: 0, size: 0
Log-dirty: no command yet.
vcpu-set: watch node error.
[xenstore_process_vcpu_set_event]: /local/domain/10/cpu has no CPU!
xs_read(/local/domain/10/log-throttling): read error
qemu: ignoring not-understood drive `/local/domain/10/log-throttling'
medium change watch on `/local/domain/10/log-throttling' - unknown
device, ignored
cirrus vga map change while on lfb mode
mapping vram to f0000000 - f0400000
platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw state.
platform_fixed_ioport: changed ro/rw state of ROM memory area. now is ro state.
Unknown PV product 3 loaded in guest
PV driver build 1
region type 1 at [c100,c200).
region type 0 at [f3001000,f3001100).
squash iomem [f3001000, f3001100).
ACPI:debug: write addr=0xb044, val=0x0.
ACPI:debug: write addr=0xb045, val=0x89.
ACPI:debug: write addr=0xb044, val=0x1.
ACPI:debug: write addr=0xb045, val=0x89.
...
ACPI:debug: write addr=0xb044, val=0xff.
ACPI:debug: write addr=0xb045, val=0x89.
Cheers,
-- Marco
8 years, 10 months
Re: [Fedora-xen] [f20] Problem with libvirt + Xen XL toolstack
by Marco Guazzone
On Wed, Nov 12, 2014 at 6:56 AM, Jim Fehlig <jfehlig(a)suse.com> wrote:
> Konrad Rzeszutek Wilk wrote:
>> On Tue, Nov 11, 2014 at 10:01:09PM +0100, Marco Guazzone wrote:
>>
>>> On Tue, Nov 11, 2014 at 5:43 PM, Konrad Rzeszutek Wilk
>>> <konrad.wilk(a)oracle.com> wrote:
>>>
>>>>> Renamed the bridge to 'xenbr0':
>>>>>
>>>>> xenbr0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
>>>>> inet 10.10.15.10 netmask 255.255.255.0 broadcast 10.10.15.255
>>>>> inet6 fe80::219:99ff:feef:62ab prefixlen 64 scopeid 0x20<link>
>>>>> ether 00:19:99:ef:62:ab txqueuelen 0 (Ethernet)
>>>>> RX packets 8 bytes 1144 (1.1 KiB)
>>>>> RX errors 0 dropped 0 overruns 0 frame 0
>>>>> TX packets 8 bytes 648 (648.0 B)
>>>>> TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
>>>>>
>>>>> rebooted the machine... But same error
>>>>>
>>>> I presume you also changed the entry in the xml file?
>>>>
>>> Yep!
>>>
>>> <interface type='bridge'>
>>> <mac address='00:00:00:00:00:00'/>
>>> <source bridge='xenbr0'/>
>>> <script path='vif-bridge'/>
>>> </interface>
>>>
>>>
>>>
>>>>> Could you be more specific. Sorry, I'm not a sysadmin.
>>>>> I'm using Xen for research purpose
>>>>>
>>>> Edit /etc/libvirt/libvirtd.conf
>>>>
>>>> and change 'log_level' to be 'log_level=4'
>>>>
>>>> and make sure that 'log_output' has '"1:syslog:libvirtd"
>>>>
>>> OK. Changed /etc/libvirt/libvirtd.conf:
>>>
>>> log_level = 4
>>>
>
> FYI, log level 4 is the default, so this doesn't change anything. You
> probably want debug log level (log_level = 1).
>
Hi all,
OK. I've changed to log_level to 1 (DEBUG)
>
> What version of libvirt? You might need
>
> http://libvirt.org/git/?p=libvirt.git;a=commit;h=48d81cef3b2dff6fe02bd7c8...
>
> which is in libvirt 1.2.6.
>
Ah, this also explains why if I turn to use the old xend toolstack in
place of XL, libvirt works correctly.
So, the problem is in the libxl driver of libvirt
I have version 1.1.3.6-1.fc20 (i.e., the one shipped with Fedora 20)
>>
>>> libxl: debug: libxl_device.c:212:disk_try_backend: Disk vdev=hda,
>>> backend tap unsuitable because blktap not available
>>>
>>
>> Which is not available under Xen 4.4.
>>
>> I am not sure why it did that as you have:
>>
>> <disk type='file' device='disk'>
>> <driver name='file'/>
>>
>
> If you don't have the above patch, use <driver name='qemu'/> to
> explicitly request qdisk.
I've change the XML and replaced
<driver name='file'/>
with the above element for both the 'disk' and the 'cdrom' devices:
<devices>
<disk type='file' device='disk'>
<!--
<driver name='file'/>
-->
<driver name='qemu'/>
<source file='/root/images/testvm.img'/>
<target dev='hda' bus='ide'/>
</disk>
<disk type='file' device='cdrom'>
<!--
<driver name='file'/>
-->
<driver name='qemu'/>
<source file='/root/iso/CentOS-7.0-1406-x86_64-Minimal.iso'/>
<target dev='hdc' bus='ide'/>
<readonly/>
</disk>
...
</devices>
Then rebooted and created the VM with virsh.
Still fail. Here's what I got.
$ virsh create testvm.xml
error: Failed to create domain from testvm.xml
error: internal error: libxenlight failed to create new domain 'testvm'
cat /var/log/libvirt/libxl/testvm.log:
libxl: verbose:
libxl_create.c:130:libxl__domain_build_info_setdefault: qemu-xen is
unavailable, use qemu-xen-traditional instead: No such file or
directory
libxl: debug: libxl_create.c:1243:do_domain_create: ao 0x7fb67c0027a0:
create: how=(nil) callback=(nil) poller=0x7fb67c002370
libxl: debug: libxl_device.c:257:libxl__device_disk_set_backend: Disk
vdev=hda spec.backend=qdisk
libxl: debug: libxl_device.c:257:libxl__device_disk_set_backend: Disk
vdev=hdc spec.backend=qdisk
libxl: debug: libxl_create.c:699:initiate_domain_create: running bootloader
libxl: debug: libxl_bootloader.c:321:libxl__bootloader_run: not a PV
domain, skipping bootloader
libxl: debug: libxl_event.c:608:libxl__ev_xswatch_deregister: watch
w=0x7fb67c002b28: deregister unregistered
libxl: debug: libxl_numa.c:478:libxl__get_numa_candidate: New best
NUMA placement candidate found: nr_nodes=1, nr_cpus=8, nr_vcpus=17,
free_memkb=2699
libxl: detail: libxl_dom.c:195:numa_place_domain: NUMA placement
candidate with 1 nodes, 8 cpus and 2699 KB free selected
xc: detail: elf_parse_binary: phdr: paddr=0x100000 memsz=0xa2304
xc: detail: elf_parse_binary: memory: 0x100000 -> 0x1a2304
xc: info: VIRTUAL MEMORY ARRANGEMENT:
Loader: 0000000000100000->00000000001a2304
Modules: 0000000000000000->0000000000000000
TOTAL: 0000000000000000->00000000bf800000
ENTRY ADDRESS: 0000000000100000
xc: info: PHYSICAL MEMORY ALLOCATION:
4KB PAGES: 0x0000000000000200
2MB PAGES: 0x00000000000003fb
1GB PAGES: 0x0000000000000001
xc: detail: elf_load_binary: phdr 0 at 0x7fb6a7b13000 -> 0x7fb6a7bac18d
libxl: debug: libxl_device.c:257:libxl__device_disk_set_backend: Disk
vdev=hda spec.backend=qdisk
libxl: debug: libxl_device.c:257:libxl__device_disk_set_backend: Disk
vdev=hdc spec.backend=qdisk
libxl: debug: libxl_dm.c:1211:libxl__spawn_local_dm: Spawning
device-model /usr/lib/xen/bin/qemu-dm with arguments:
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: /usr/lib/xen/bin/qemu-dm
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -d
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: 2
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -domain-name
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: testvm
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -vnc
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: 127.0.0.1:0
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -videoram
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: 8
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -boot
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: cc
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -vcpu_avail
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: 0x01
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -net
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: none
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: -M
libxl: debug: libxl_dm.c:1213:libxl__spawn_local_dm: xenfv
libxl: debug: libxl_event.c:559:libxl__ev_xswatch_register: watch
w=0x7fb67c002d60 wpath=/local/domain/0/device-model/2/state token=3/0:
register slotnum=3
libxl: debug: libxl_create.c:1256:do_domain_create: ao 0x7fb67c0027a0:
inprogress: poller=0x7fb67c002370, flags=i
libxl: debug: libxl_event.c:503:watchfd_callback: watch
w=0x7fb67c002d60 wpath=/local/domain/0/device-model/2/state token=3/0:
event epath=/local/domain/0/device-model/2/state
libxl: debug: libxl_event.c:596:libxl__ev_xswatch_deregister: watch
w=0x7fb67c002d60 wpath=/local/domain/0/device-model/2/state token=3/0:
deregister slotnum=3
libxl: error: libxl_dm.c:1280:device_model_spawn_outcome: domain 2
device model: spawn failed (rc=-3)
libxl: error: libxl_create.c:1088:domcreate_devmodel_started: device
model did not start: -3
libxl: error: libxl_dm.c:1311:libxl__destroy_device_model: Device
Model already exited
libxl: debug: libxl_event.c:1569:libxl__ao_complete: ao
0x7fb67c0027a0: complete, rc=-3
libxl: debug: libxl_event.c:1541:libxl__ao__destroy: ao 0x7fb67c0027a0: destroy
Cheers,
-- Marco
8 years, 10 months
[f20] Problem with libvirt + Xen XL toolstack
by Marco Guazzone
Hello,
Since when libvirt has introduced support for the Xen XL toolstack, I
was unable to make it work together.
With Fedora 20 x86_64, still I have problems and the only way to use
libvirt+Xen is to use the old xend toolstack.
Can anybody help me?
Here's below is my test. Sorry, the mail is very long...
1. Disable SElinux
$ vi /etc/selinux/config
SELINUXTYPE=disabled
2. Install Xen and libvirt
$ yum install xen
$ yum install libvirt-daemon-xen libvirt-client
3. Disable Network Manager
$ systemctl disable NetworkManager
$ systemctl stop NetworkManager
4- Create network bridge
$ vi /etc/sysconfig/network-
scripts/ifcfg-br0
DEVICE=br0
TYPE=Bridge
BOOTPROTO=none
ONBOOT=yes
IPADDR=10.10.15.2
NETMASK=255.255.255.0
STP=yes
DELAY=0
DEFROUTE=yes
USERCTL=no
NM_CONTROLLED=no
$ vi /etc/sysconfig/network-scripts/ifcfg-em2
NAME=em2
TYPE=Ethernet
BOOTPROTO=none
ONBOOT=yes
BRIDGE=br0
PEERDNS=yes
PEERROUTES=yes
DEFROUTE=yes
USERCTL=no
NM_CONTROLLED=no
5. Enable classic networking
$ systemctl enable network
$ systemctl start network
6. Reboot with Xen
7. Check xend toolstack is disabled
$ systemctl is-enabled xend
disabled
8. Create a test VM
$ qemu-img-xen create -f raw test.img 10G
$ vi testvm.cfg
name = "testvm"
uuid = "93f08541-bfd5-4ac4-851d-c619a4516a13"
builder = "hvm"
maxmem = 3072
memory = 2048
vcpus = 1
on_crash = "restart"
disk = [ "file:/root/images/testvm.img,hda,w",
"file:/root/iso/CentOS-7.0-1406- x86_64-Minimal.iso,hdc:cdrom,r" ]
vif = [ "bridge=br0,script=vif-bridge" ]
boot = "cd"
sdl = 0
vnc = 1
vncunused = 1
xen_platform_pci = 1
$ xl create testvm.cfg
9. Open vncviewer and perform installation
10. Shutdown just created VM
11. Create a libvirt XML file
$ virsh -c xen:/// domxml-from-native xen-xm testvm.cfg > testvm.xml
<domain type='xen'>
<name>testvm</name>
<uuid>93f08541-bfd5-4ac4-851d-c619a4516a13</uuid>
<memory unit='KiB'>3145728</memory>
<currentMemory unit='KiB'>2097152</currentMemory>
<vcpu placement='static'>1</vcpu>
<os>
<type arch='x86_64' machine='xenfv'>hvm</type>
<loader>/usr/lib/xen/boot/hvmloader</loader>
<boot dev='hd'/>
<boot dev='hd'/>
</os>
<clock offset='variable' adjustment='0' basis='utc'/>
<on_poweroff>destroy</on_poweroff>
<on_reboot>restart</on_reboot>
<on_crash>restart</on_crash>
<devices>
<disk type='file' device='disk'>
<driver name='file'/>
<source file='/root/images/testvm.img'/>
<target dev='hda' bus='ide'/>
</disk>
<disk type='file' device='cdrom'>
<driver name='file'/>
<source file='/root/iso/CentOS-7.0-1406-x86_64-Minimal.iso'/>
<target dev='hdc' bus='ide'/>
<readonly/>
</disk>
<interface type='bridge'>
<mac address='00:00:00:00:00:00'/>
<source bridge='br0'/>
<script path='vif-bridge'/>
</interface>
<input type='mouse' bus='ps2'/>
<graphics type='vnc' port='-1' autoport='yes'/>
</devices>
</domain>
12. Start the VM with libvirt
$ virsh create testvm.xml
BOOOM:
error: Failed to create domain from testvm.xml
error: End of file while reading data: Input/output error
error: One or more references were leaked after disconnect from the hypervisor
error: Failed to reconnect to the hypervisor
Thank you very much for your time.
Best,
-- Marco
8 years, 10 months