[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] redirecting stdio from a VM guest
From: |
Alexander Binun |
Subject: |
Re: [Qemu-devel] redirecting stdio from a VM guest |
Date: |
Wed, 28 May 2014 17:26:06 +0300 (IDT) |
Great thanks!
What is the meaning of "log" ?
Thanks,
Alex Binun
On Wed 28 May 16:14 2014 Eric Blake wrote:
>
> On 05/28/2014 06:51 AM, Alexander Binun wrote:
> > Dear Friends,
> > First of all, great thanks for your support! I would ask yet one
> > question.
> >
> > I have a programs running on a VM guest. Its output is valuable (for VM
> > introspection) so I want to let the host module know about it. I prefer to
> > redirect ' stdio" of a guest into a device at the host (the latter has the
> > name "mydev" and the driver is written for it).
> >
> > The command string for qemu will look like qemu -serial /dev/mydev ... But
> > I would like to modify the libvirt definition XML file (in
> > /etc/libvirt/qemu). Stefan notes in his blog
> > (http://blog.vmsplice.net/2011/04/how-to-pass-qemu-command-line-options.html)
> > that the options will look like:
> >
> > <qemu:commandline>
> > <qemu:arg value='-serial'/>
> > <qemu:arg value='/dev/mydev>
> > </qemu:commandline>
>
> Use of this syntax moves you into the realm of unsupported behavior. It
> should only be a last resort for debugging or development purposes, with
> a request made to the libvirt people to turn your usage into a formal
> feature.
>
> >
> > But the link referenced from the log mentioned above
> > (http://wiki.libvirt.org/page/QEMUSwitchToLibvirt) provides a different XML
> > mapping for the "serial" command:
> >
> > <serial type='pty'>
> > <target port='0'/>
> > </serial>
>
> Yes, the <serial> block is the formal feature that you should be using,
> rather than resorting to <qemu:commandline>.
>
> >
> > How should I map my preference -serial /dev/mydev into the XML ?
>
> You're better off asking libvirt usage questions on the libvirt list
> rather than here on the qemu list (address@hidden). That
> said, http://libvirt.org/formatdomain.html#elementsCharFle makes it
> sound like you want
> <serial type="file">
> <source path="/dev/mydev"/>
> <target port="0"/>
> </serial>
>
> --
> Eric Blake eblake redhat com +1-919-301-3266
> Libvirt virtualization library http://libvirt.org
>
>
Re: [Qemu-devel] redirecting stdio from a VM guest, Eric Blake, 2014/05/28