Bug 1095637
Summary: | virsh dominfo for LXC domain causes spurious error "this function is not supported by the connection driver: virDomainHasManagedSaveImage" | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Malte Starostik <bugs> |
Component: | libvirt | Assignee: | Ján Tomko <jtomko> |
Status: | CLOSED ERRATA | QA Contact: | Virtualization Bugs <virt-bugs> |
Severity: | medium | Docs Contact: | |
Priority: | unspecified | ||
Version: | 7.1 | CC: | berrange, dyuan, jdenemar, jkortus, jtomko, mlisik, rbalakri, shyu, xuzhang, yanyang |
Target Milestone: | rc | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | libvirt-1.2.13-1.el7 | Doc Type: | Bug Fix |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2015-11-19 05:46:05 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Malte Starostik
2014-05-08 09:05:17 UTC
I have the same problem when running LXC container in cluster as resource. Libvirt version: libvirt-1.2.8-11.el7.x86_64 It spams log file every 3-5 seconds, so the file size grows quickly. The cluster software really should not use virsh to monitor the VMs in this way. It should use the libvirt API directly, which is available in every common programming language. Not only would this avoid calling functions that are not required & so avoid this error message, but it would be much more efficient too. Agreed. But then VirtualDomain, like ca. 99% of the Linux HA resource agents, is in fact just a shell script making virsh its natural interace to libvirtd. changing product to RHEL so that we can track it better. As I understand it it's RHEL 7 issue. There are two possible ways of fixing this... First, the resource agent should be rewritten to python or perl and use libvirt API directly. Second, virDomainHasManagedSaveImage could be trivially implemented for LXC. we would definitely prefer the second option :) Upstream patch implementing the second option: https://www.redhat.com/archives/libvir-list/2015-January/msg00544.html v2: https://www.redhat.com/archives/libvir-list/2015-February/msg00111.html v3: https://www.redhat.com/archives/libvir-list/2015-February/msg00148.html Pushed upstream: commit 481881f50ae3e3bc4699baf42d35b3ef7d95c685 Author: Ján Tomko <jtomko> CommitDate: 2015-02-06 12:52:50 +0100 Trivially support DomainHasManagedSaveImage Return 0 instead of ERR_NO_SUPPORT in each driver where we don't support managed save or -1 if the domain does not exist. This avoids spamming daemon logs when 'virsh dominfo' is run. https://bugzilla.redhat.com/show_bug.cgi?id=1095637 git describe: v1.2.12-82-g481881f Verified on libvirt-1.2.15-1.el7.x86_64 Steps 1. define/start a lxc # virsh -c lxc:/// define lxc.xml # virsh -c lxc:/// start helloworld # cat lxc.xml <domain type='lxc'> <name>helloworld</name> <uuid>ed1955f7-4e72-40ae-8265-c193e7436c8a</uuid> <memory unit='KiB'>102400</memory> <currentMemory unit='KiB'>102300</currentMemory> <vcpu placement='static' cpuset='1-3'>2</vcpu> <resource> <partition>/machine</partition> </resource> <os> <type arch='x86_64'>exe</type> <init>/bin/sh</init> </os> <clock offset='utc'/> <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> <on_crash>destroy</on_crash> <devices> <emulator>/usr/libexec/libvirt_lxc</emulator> <filesystem type='mount' accessmode='passthrough'> <source dir='/'/> <target dir='/'/> </filesystem> <console type='pty'> <target type='lxc' port='0'/> </console> </devices> <seclabel type='dynamic' model='selinux' relabel='yes'/> </domain> 2. # virsh -c lxc:/// dominfo helloworld Id: 14079 Name: helloworld UUID: ed1955f7-4e72-40ae-8265-c193e7436c8a OS Type: exe State: running CPU(s): 2 CPU time: 0.0s Max memory: 102400 KiB Used memory: 564 KiB Persistent: yes Autostart: disable Managed save: no Security model: selinux Security DOI: 0 Security label: system_u:system_r:svirt_lxc_net_t:s0:c822,c883 (enforcing) Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHBA-2015-2202.html |