* Re: [Qemu-devel] vhost broken?
2012-01-05 11:16 ` Avi Kivity
@ 2012-01-05 11:33 ` Gerd Hoffmann
2012-01-05 11:37 ` Daniel P. Berrange
2012-01-05 15:00 ` Michael S. Tsirkin
2 siblings, 0 replies; 7+ messages in thread
From: Gerd Hoffmann @ 2012-01-05 11:33 UTC (permalink / raw)
To: Avi Kivity; +Cc: qemu-devel@nongnu.org, Michael S. Tsirkin
Hi,
> I don't have a vhost setup, can you share your command line?
Just use libvirt which enables it automagically if possible ;)
Command line from /var/log/libvirt/qemu/rhel6-org-scsi.lsi.log is below
(but probably doesn't buy you that much as it wouldn't work without the
vhost/tap fd setup libvirt is doing).
cheers,
Gerd
LC_ALL=C PATH=/sbin:/usr/sbin:/bin:/usr/bin QEMU_AUDIO_DRV=spice
/home/kraxel/bin/qemu-default -S -M pc-1.0 -enable-kvm -m 512 -smp
1,sockets=1,cores=1,threads=1 -name rhel6-org-scsi.lsi -uuid
d67eb0e9-6a0d-faa0-308e-898692f8700d -nodefconfig -nodefaults -device
sga -chardev
socket,id=charmonitor,path=/var/lib/libvirt/qemu/rhel6-org-scsi.lsi.monitor,server,nowait
-mon chardev=charmonitor,id=monitor,mode=control -rtc base=utc
-no-shutdown -boot order=c,menu=on -device
lsi,id=scsi0,bus=pci.0,addr=0x5 -device
virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x9 -drive
file=/vmdisk/guests/rhel6.img,if=none,id=drive-scsi0-0-0,format=qcow2,cache=none,aio=threads
-device
scsi-disk,bus=scsi0.0,scsi-id=0,drive=drive-scsi0-0-0,id=scsi0-0-0
-netdev tap,fd=26,id=hostnet0,vhost=on,vhostfd=27 -device
virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:c4:31:86,bus=pci.0,addr=0x3
-chardev pty,id=charserial0 -device
isa-serial,chardev=charserial0,id=serial0 -chardev
spicevmc,id=charchannel0,name=vdagent -device
virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.spice.0
-usb -device usb-tablet,id=input0 -spice
port=5900,addr=127.0.0.1,disable-ticketing -vga qxl -global
qxl-vga.vram_size=67108864 -device
intel-hda,id=sound0,bus=pci.0,addr=0x4 -device
hda-duplex,id=sound0-codec0,bus=sound0.0,cad=0 -device
virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x6 -bios
/home/kraxel/rhel6/seabios/out/bios.bin -readconfig
/home/kraxel/rhel6/qemu-kvm/docs/ich9-ehci-uhci.cfg -readconfig
/root/libvirt/all-usbdrives.cfg -readconfig /root/libvirt/rhel6.cfg
-trace events=/root/libvirt/usb-host.events -option-rom
romfile=/root/roms/8xx_64.rom,bootindex=1
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] vhost broken?
2012-01-05 11:16 ` Avi Kivity
2012-01-05 11:33 ` Gerd Hoffmann
@ 2012-01-05 11:37 ` Daniel P. Berrange
2012-01-05 15:00 ` Michael S. Tsirkin
2 siblings, 0 replies; 7+ messages in thread
From: Daniel P. Berrange @ 2012-01-05 11:37 UTC (permalink / raw)
To: Avi Kivity; +Cc: Michael S. Tsirkin, Gerd Hoffmann, qemu-devel@nongnu.org
On Thu, Jan 05, 2012 at 01:16:22PM +0200, Avi Kivity wrote:
> On 01/05/2012 01:05 PM, Gerd Hoffmann wrote:
> > Hi,
> >
> > current master seems to corrupt guest memory, I get guest errors like
> > this one:
> >
> > swap_dup: Bad swap file entry 1999800080
> > BUG: Bad page map in process udevd pte:bec5f30054520100 pmd:1f6f4067
> > addr:00007fc464a02000 vm_flags:00100073 anon_vma:ffff88001f928ec0
> > mapping:(null) index:7fc464a02
> > Pid: 555, comm: udevd Not tainted 2.6.32-220.el6.x86_64 #1
> >
> > bisecting points to this commit:
> >
> > commit 04097f7c5957273c578f72b9bd603ba6b1d69e33
> > Author: Avi Kivity <avi@redhat.com>
> > Date: Sun Dec 18 14:06:05 2011 +0200
> >
> > vhost: convert to MemoryListener API
> >
>
> Very likely. Michael, can you help?
>
> I don't have a vhost setup, can you share your command line?
All you need to do is take your existing -netdev command line,
and add in the parameter:
vhost=on
Libvirt does some extra stuff like passing down a pre-opened vhost
file descriptor, but you can ignore that for just testing the core
functionality.
Regards,
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] vhost broken?
2012-01-05 11:16 ` Avi Kivity
2012-01-05 11:33 ` Gerd Hoffmann
2012-01-05 11:37 ` Daniel P. Berrange
@ 2012-01-05 15:00 ` Michael S. Tsirkin
2012-01-20 22:13 ` Lutz Vieweg
2 siblings, 1 reply; 7+ messages in thread
From: Michael S. Tsirkin @ 2012-01-05 15:00 UTC (permalink / raw)
To: Avi Kivity; +Cc: Gerd Hoffmann, qemu-devel@nongnu.org
On Thu, Jan 05, 2012 at 01:16:22PM +0200, Avi Kivity wrote:
> On 01/05/2012 01:05 PM, Gerd Hoffmann wrote:
> > Hi,
> >
> > current master seems to corrupt guest memory, I get guest errors like
> > this one:
> >
> > swap_dup: Bad swap file entry 1999800080
> > BUG: Bad page map in process udevd pte:bec5f30054520100 pmd:1f6f4067
> > addr:00007fc464a02000 vm_flags:00100073 anon_vma:ffff88001f928ec0
> > mapping:(null) index:7fc464a02
> > Pid: 555, comm: udevd Not tainted 2.6.32-220.el6.x86_64 #1
> >
> > bisecting points to this commit:
> >
> > commit 04097f7c5957273c578f72b9bd603ba6b1d69e33
> > Author: Avi Kivity <avi@redhat.com>
> > Date: Sun Dec 18 14:06:05 2011 +0200
> >
> > vhost: convert to MemoryListener API
> >
>
> Very likely. Michael, can you help?
>
> I don't have a vhost setup, can you share your command line?
Just chmod /dev/vhost-net to allow access, then
add vhost=on to the tap device.
Example
-netdev
tap,id=foo,ifname=msttap0,script=/home/mst/ifup,downscript=no,vhost=on
-device virtio-net-pci,netdev=foo
> --
> error compiling committee.c: too many arguments to function
^ permalink raw reply [flat|nested] 7+ messages in thread