[libvirt] [PATCH] qemu: Fix qemuDomainObjTaint with virtlogd

Ján Tomko jtomko at redhat.com
Thu Sep 5 14:49:08 UTC 2019


On Thu, Sep 05, 2019 at 03:48:10PM +0200, Jiri Denemark wrote:
>When virtlogd is used to capture QEMU's stdout, qemuDomainObjTaint would
>always fail to write the message to the log file when QEMU is already
>running (i.e., outside qemuProcessLaunch). This can happen during device
>hotplug or by sending a custom QEMU guest agent command:
>
>    warning : qemuDomainObjTaint:8757 : Domain id=9 name='blaf'
>        uuid=9cfa4e37-2930-405b-bcb4-faac1829dad8 is tainted:
>        custom-ga-command
>    error : virLogHandlerDomainOpenLogFile:388 : Cannot open log file:
>        '/var/log/libvirt/qemu/blaf.log': Device or resource busy
>    error : virNetClientProgramDispatchError:172 : Cannot open log file:
>        '/var/log/libvirt/qemu/blaf.log': Device or resource busy
>
>The fix is easy, we just need to use the right API for appending a
>message to QEMU log file instead of creating a new log context.
>
>Signed-off-by: Jiri Denemark <jdenemar at redhat.com>
>---
> src/qemu/qemu_domain.c | 30 ++++++++++++++----------------
> 1 file changed, 14 insertions(+), 16 deletions(-)
>

Reviewed-by: Ján Tomko <jtomko at redhat.com>

Jano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20190905/a87d147c/attachment-0001.sig>


More information about the libvir-list mailing list