Bug 709576

Summary: lxc driver trys to connect to inactive domain's monitor.
Product: Red Hat Enterprise Linux 6 Reporter: Osier Yang <jyang>
Component: libvirtAssignee: Osier Yang <jyang>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.2CC: ajia, dallan, dyuan, rwu, weizhan
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: libvirt-0.9.2-1.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-12-06 11:12:20 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Osier Yang 2011-06-01 04:18:46 UTC
Description of problem:
As $subject says, if you have lxc domain which is inactive, you will see error like following in libvirtd log.

12:01:57.644: error : lxcMonitorClient:949 : Failed to connect to client socket: No such file or directory
12:01:57.644: error : lxcMonitorClient:949 : Failed to connect to client socket: No such file or directory

The problem is caused by we load all the domain configs for lxc domains in one stage, and then trys to connect the all the domain's monitor, regardless of wether the domain is active or not.

Version-Release number of selected component (if applicable):


How reproducible:
always

Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Osier Yang 2011-06-01 04:20:45 UTC
patch pushed in upstream, http://www.redhat.com/archives/libvir-list/2011-May/msg01849.html

Comment 3 Daniel Veillard 2011-06-23 03:35:03 UTC
This should be fixed by the libvirt-0.9.2-1.el6 rebase

Comment 4 weizhang 2011-07-04 08:56:52 UTC
verify pass on
libvirt-0.9.2-1.el6
kernel-2.6.32-156.el6.x86_64
qemu-kvm-0.12.1.2-2.165.el6.x86_64

steps to reproduce:
1. cat toy.xml
<domain type='lxc'>
  <name>vm1</name>
  <uuid>386f5b25-43ee-9d62-4ce2-58c3809e47c1</uuid>
  <memory>500000</memory>
  <currentMemory>500000</currentMemory>
  <vcpu>1</vcpu>
  <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>
    <interface type='network'>
      <mac address='52:54:00:f2:2c:ac'/>
      <source network='default'/>
      <target dev='veth0'/>
    </interface>
    <console type='pty'>
      <target port='0'/>
    </console>
  </devices>
</domain>

# virsh -c lxc:/// define toy.xml
# virsh -c lxc:/// list --all
 Id Name                 State
----------------------------------
  - vm1                  shut off

2. setting  /etc/libvirt/libvirtd.conf
add log_outputs="1:file:/var/log/libvirt/libvirtd.log"

3. restart libvirtd several times
# service libvirtd restart
# service libvirtd restart

4. see log on /var/log/libvirt/libvirtd.log

For libvirt-0.9.2-1.el6, can not see error info

Comment 6 Rita Wu 2011-07-06 10:21:12 UTC
Set it as VERIFIED per comment4

Comment 7 errata-xmlrpc 2011-12-06 11:12:20 UTC
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.

http://rhn.redhat.com/errata/RHBA-2011-1513.html