Bug 649438 - virsh dominfo prints an error when transported from a remote machine through the libvirtd
Summary: virsh dominfo prints an error when transported from a remote machine through ...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: libvirt
Version: 5.6
Hardware: All
OS: Linux
low
medium
Target Milestone: rc
: ---
Assignee: Daniel Veillard
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On: 506688
Blocks: 1062340
TreeView+ depends on / blocked
 
Reported: 2010-11-03 18:14 UTC by R P Herrold
Modified: 2014-02-06 17:07 UTC (History)
13 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of: 506688
: 1062340 (view as bug list)
Environment:
Last Closed: 2011-08-15 19:59:01 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description R P Herrold 2010-11-03 18:14:59 UTC
+++ This bug was initially created as a clone of Bug #506688 +++

Description of problem:

The earlier bug dealt with a local invocation of virsh --- it also appears that the error message (a warning actually it seems) when the request is transported across libvirt from another machine


These are the versions on the machine evidencing the error in its log file

[root@xen-n005 log]# rpm -q libvirt
libvirt-0.6.3-33.el5_5.3
libvirt-0.6.3-33.el5_5.3
[root@xen-n005 log]# rpm -q --qf '%{name}.%{arch} \n' libvirt
libvirt.x86_64
libvirt.i386
[root@xen-n005 log]#

and this on the remote machine

[root@secure ~]# rpm -q libvirt
libvirt-0.6.3-33.el5_5.3
libvirt-0.6.3-33.el5_5.3
[root@secure ~]# rpm -q --qf '%{name}.%{arch} \n' libvirt
libvirt.x86_64
libvirt.i386
[root@secure ~]#

which are, I believe post 

1.127.1.  RHSA-2009:0382: Moderate security update which issued 2009-03-19 and seems not to have been updated

Reproducer

[root@xen-n005 log]# virsh dominfo vm_43148
Id:             53
Name:           vm_43148
UUID:           055e166b-80ea-e9a1-7407-aedeb5cf4753
OS Type:        linux
State:          idle
CPU(s):         1
CPU time:       17.0s
Max memory:     262144 kB
Used memory:    261492 kB
Autostart:      disable

[root@xen-n005 log]# pwd
/var/log
[root@xen-n005 log]# mv messages  messages.1
[root@xen-n005 log]# service syslog restart
Shutting down kernel logger:                               [  OK  ]
Shutting down system logger:                               [  OK  ]
Starting system logger:                                    [  OK  ]
Starting kernel logger:                                    [  OK  ]
[root@xen-n005 log]# virsh dominfo vm_43148
Id:             53
Name:           vm_43148
UUID:           055e166b-80ea-e9a1-7407-aedeb5cf4753
OS Type:        linux
State:          idle
CPU(s):         1
CPU time:       17.1s
Max memory:     262144 kB
Used memory:    261452 kB
Autostart:      disable

[root@xen-n005 log]# cat messages
Nov  3 14:00:23 xen-n005 syslogd 1.4.1: restart.
Nov  3 14:00:23 xen-n005 kernel: klogd 1.4.1, log source = /proc/kmsg started.
[root@xen-n005 log]# 

THEN we run it remotely from 'secure'

[root@xen-n005 log]# #  then run remotely
[root@xen-n005 log]# cat messages
Nov  3 14:00:23 xen-n005 syslogd 1.4.1: restart.
Nov  3 14:00:23 xen-n005 kernel: klogd 1.4.1, log source = /proc/kmsg started.
Nov  3 14:00:53 xen-n005 libvirtd: 14:00:53.051: error : this function is not supported by the hypervisor: virNodeGetSecurityModel
[root@xen-n005 log]#            

Desired state

The actions should not express false warnings


Follow-up

If you need additional information, please ask and we will supplement as requested

This is seen on a pair of CentOS 5 units, fully updated, and so CRM is not relevant

-- Russ herrold

Comment 1 Daniel Berrangé 2010-11-10 23:17:14 UTC
This isn't specific to virsh dominfo.  The libvirtd daemon will log details of any API call that returns an error status.  We've decided to reduce the libvirtd logging level so these are just 'info' messages, so wouldn;t appear in syslog by default.

Comment 2 Dave Allan 2011-02-01 02:23:01 UTC
Per comment 1, do you see this behavior on 5.6?

Comment 3 R P Herrold 2011-05-05 17:46:02 UTC
yes (although new cruft, it seems)

first on a plain 5.6 on its 'localhost'   ... across the network report in a moment

[root@secure ~]# cd /var/log
[root@secure log]# mv messages messages-old
[root@secure log]# /sbin/service syslog restart
Shutting down kernel logger:                               [  OK  ]
Shutting down system logger:                               [  OK  ]
Starting system logger:                                    [  OK  ]
Starting kernel logger:                                    [  OK  ]
[root@secure log]# virsh dominfo monitor
Id:             3
Name:           monitor
UUID:           03cbbf27-5fa1-50b5-5e7a-3afadefe9e49
OS Type:        linux
State:          idle
CPU(s):         1
CPU time:       557.8s
Max memory:     1048576 kB
Used memory:    1047860 kB
Persistent:     no
Autostart:      disable

[root@secure log]# cat messages
May  5 13:42:14 secure syslogd 1.4.1: restart (remote reception).
May  5 13:42:14 secure kernel: klogd 1.4.1, log source = /proc/kmsg started.
May  5 13:42:20 secure libvirtd: 13:42:20.866: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May  5 13:42:20 secure libvirtd: 13:42:20.867: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May  5 13:42:20 secure libvirtd: 13:42:20.867: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
May  5 13:42:20 secure libvirtd: 13:42:20.878: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May  5 13:42:20 secure libvirtd: 13:42:20.878: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May  5 13:42:20 secure libvirtd: 13:42:20.879: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
May  5 13:42:20 secure libvirtd: 13:42:20.894: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May  5 13:42:20 secure libvirtd: 13:42:20.894: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May  5 13:42:20 secure libvirtd: 13:42:20.894: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
[root@secure log]# rpm -q libvirtd
package libvirtd is not installed
[root@secure log]# rpm -q libvirt
libvirt-0.8.2-15.el5_6.3
libvirt-0.8.2-15.el5_6.3
[root@secure log]# rpm -q libvirt --qf '%{arch}\n'
x86_64
i386
[root@secure log]# uname -a
Linux secure.pmman.com 2.6.18-238.9.1.el5xen #1 SMP Tue Apr 12 18:53:56 EDT 2011 x86_64 x86_64 x86_64 GNU/Linux
[root@secure log]#

Comment 4 R P Herrold 2011-05-05 18:18:49 UTC
also observed on a pure i386 locally only under 5.6 level packages

May  5 14:14:48 xen-rph smartd[3595]: smartd has fork()ed into background mode. New PID=3595.
May  5 14:15:02 xen-rph libvirtd: 14:15:02.454: error : virLibConnError:462 : this function is not supported by the connection driver: virNodeGetSecurityModel
[root@xen-rph xen]# rpm -q libvirt
libvirt-0.8.2-15.el5_6.4
[root@xen-rph xen]# rpm -q libvirt --qf '%{archn'
i386
[root@xen-rph xen]# date
Thu May  5 14:18:09 EDT 2011
[root@xen-rph xen]#

Comment 5 wangyimiao 2011-05-26 03:10:58 UTC
Follow that steps I test it with TLS and ssh from remote,but I can not reproduce that issue on:
HOST OS: RHEL5.7-Server-20110518.0  
ARCH   :  X86_64
Platform: X86_64
libvirt: libvirt-0.8.2-20.el5
xen:     xen-3.0.3-131.el5
kernel:  kernel-xen-2.6.18-262.el5

1.Please give me details of environment info from your host,like "Host OS Arch","Xen build ID","Platform"

2.Please give me the details for "THEN we run it remotely from 'secure'".( Details steps or commands)

Comment 6 R P Herrold 2011-05-26 07:43:14 UTC
Response to Comment 5, part 1

[root@secure ~]# rpm -q xen
xen-3.0.3-120.el5_6.1
[root@secure ~]# rpm -q libvirt
libvirt-0.8.2-15.el5_6.3
libvirt-0.8.2-15.el5_6.3
[root@secure ~]# uname -a
Linux secure.elided 2.6.18-238.9.1.el5xen #1 SMP Tue Apr 12 18:53:56 EDT 2011 x86_64 x86_64 x86_64 GNU/Linux
[root@secure ~]#  rpm -q kernel-xen | tail -1
kernel-xen-2.6.18-238.9.1.el5
[root@secure ~]#

... it appears you are running internal beta candidate issued in dailies seven days ago in the nightly compose for some RHEL version after 5.6 ... probably not the 'bits' that will become 5.7, but rather something not released in binary of source form.  Where may we obtain access to this, so we may set up your environment?

We are running, from 5.6 sources.  The second libvirt is of course the cruft dragged in for i386, under Red Hat's multi-lib approach


Response to Comment 5, part 2

secure is a unit remote to unit: xen-n005

first I clean out /var/log/messages so we may see new messages

[root@secure ~]# cd /var/log
[root@secure log]# ls mess*
messages       messages.2.gz  messages.4.gz
messages.1.gz  messages.3.gz  messages-old
[root@secure log]# mv messages messages-old2
[root@secure log]# /sbin/service syslog restart
Shutting down kernel logger:                               [  OK  ]
Shutting down system logger:                               [  OK  ]
Starting system logger:                                    [  OK  ]
Starting kernel logger:                                    [  OK  ]
[root@secure log]#

second I enumerate available domU, and run the dominfo command, per 
in the initial report on https://bugzilla.redhat.com/show_bug.cgi?id=506688 [which was allegedly, but not actually fixed, for the 'localhost case']

[root@secure log]# virsh list
 Id Name                 State
----------------------------------
  0 Domain-0             running
  3 monitor              idle

[root@secure log]# virsh dominfo monitor
Id:             3
Name:           monitor
UUID:           03cbbf27-5fa1-50b5-5e7a-3afadefe9e49
OS Type:        linux
State:          idle
CPU(s):         1
CPU time:       2581.0s
Max memory:     1048576 kB
Used memory:    1047892 kB
Persistent:     no
Autostart:      disable

third, I examine /var/log/messages to see the error content htat was supposed to have been suppressed

[root@secure log]# cat messages
May 26 03:23:21 secure syslogd 1.4.1: restart (remote reception).
May 26 03:23:21 secure kernel: klogd 1.4.1, log source = /proc/kmsg started.
May 26 03:23:26 secure libvirtd: 03:23:26.972: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May 26 03:23:26 secure libvirtd: 03:23:26.972: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May 26 03:23:26 secure libvirtd: 03:23:26.972: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
May 26 03:23:26 secure libvirtd: 03:23:26.984: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May 26 03:23:26 secure libvirtd: 03:23:26.984: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May 26 03:23:26 secure libvirtd: 03:23:26.984: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
May 26 03:23:26 secure libvirtd: 03:23:26.996: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May 26 03:23:26 secure libvirtd: 03:23:26.996: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May 26 03:23:26 secure libvirtd: 03:23:26.996: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
May 26 03:23:31 secure libvirtd: 03:23:31.399: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May 26 03:23:31 secure libvirtd: 03:23:31.399: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May 26 03:23:31 secure libvirtd: 03:23:31.400: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
May 26 03:23:31 secure libvirtd: 03:23:31.412: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May 26 03:23:31 secure libvirtd: 03:23:31.412: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May 26 03:23:31 secure libvirtd: 03:23:31.412: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
May 26 03:23:31 secure libvirtd: 03:23:31.427: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May 26 03:23:31 secure libvirtd: 03:23:31.427: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May 26 03:23:31 secure libvirtd: 03:23:31.427: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
[root@secure log]#

fourth -- other commands produce this content that was supposed to be suppressed as well.  here a simple: virsh start (instance)   command on the localhost case

[root@secure log]# rm messages
rm: remove regular file `messages'? y
[root@secure log]# service syslog restart
Shutting down kernel logger:                               [  OK  ]
Shutting down system logger:                               [  OK  ]
Starting system logger:                                    [  OK  ]
Starting kernel logger:                                    [  OK  ]
[root@secure log]# virsh start monitor
error: Domain is already active

[root@secure log]# cat /var/log/messages
May 26 03:27:02 secure syslogd 1.4.1: restart (remote reception).
May 26 03:27:02 secure kernel: klogd 1.4.1, log source = /proc/kmsg started.
May 26 03:27:13 secure libvirtd: 03:27:13.066: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May 26 03:27:13 secure libvirtd: 03:27:13.067: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May 26 03:27:13 secure libvirtd: 03:27:13.067: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
May 26 03:27:13 secure libvirtd: 03:27:13.077: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May 26 03:27:13 secure libvirtd: 03:27:13.077: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May 26 03:27:13 secure libvirtd: 03:27:13.077: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
May 26 03:27:13 secure libvirtd: 03:27:13.093: error : virConfError:105 : /etc/xen/xen_monitor.xml:1: expecting a name
May 26 03:27:13 secure libvirtd: 03:27:13.093: error : virConfError:105 : /etc/xen/xen_mirror.xml:1: expecting a name
May 26 03:27:13 secure libvirtd: 03:27:13.093: error : virConfError:105 : /etc/xen/xen_testLV.xml:1: expecting a name
[root@secure log]#

====================================

I then looked up the 'across the network through ssh' variant, to see if the remote dom0 accessed per Comment 14 of #506688 , also emitted messages thought to have been suppressed in RHEA-2009-1269.html

and the same message and error reported in #508688 still remains

first: move the remote old /var/log/messages aside

[root@secure log]# ssh -l root xen-n005.elided mv /var/log/messages /var/log/messages-old

second: restart the syslog remotely

[root@secure log]# ssh -l root xen-n005.elided /sbin/service syslog restart
Shutting down kernel logger: [  OK  ]
Shutting down system logger: [  OK  ]
Starting system logger: [  OK  ]
Starting kernel logger: [  OK  ]

third: run the test 'dominfo' per #506688, Comment 14, as to a known active domU on the remote host

[root@secure log]# virsh -c xen+ssh://xen-n005.elided dominfo vm_72314
Id:             68
Name:           vm_72314
UUID:           bb10dbd0-8351-e336-9ad5-75d9dfdc8c66
OS Type:        linux
State:          idle
CPU(s):         1
CPU time:       1084.6s
Max memory:     262144 kB
Used memory:    261740 kB
Persistent:     unknown
Autostart:      disable

fourth: examine the remote syslog tail

[root@secure log]# ssh -l root xen-n005.elided cat /var/log/messages
May 26 03:36:19 xen-n005 syslogd 1.4.1: restart.
May 26 03:36:19 xen-n005 kernel: klogd 1.4.1, log source = /proc/kmsg started.
May 26 03:36:24 xen-n005 libvirtd: 03:36:24.913: error : this function is not supported by the hypervisor: virNodeGetSecurityModel
[root@secure log]#

The last line still shows the error

To summarize, the remote and the localhost versions of the virsh command both still emit the improper error messages

-- Russ herrold

Comment 7 wangyimiao 2011-05-26 10:27:45 UTC
Follow detail steps, retest it again,

1.That issue can reproduce on rhel5.6 build:
libvirt-0.8.2-15.el5_6.4
xen-libs-3.0.3-120.el5_6.2
kernel-xen-2.6.18-238.el5

2.That works fine on rhel5.7 build:
libvirt: libvirt-0.8.2-20.el5
xen:     xen-3.0.3-131.el5
kernel:  kernel-xen-2.6.18-262.el5

Comment 8 Cui Chun 2011-05-30 02:49:30 UTC
This issue can be reproduced in the latest RHEL5.6.z (libvirt-0.8.2-15.el5_6.4). But can not be found in RHEL5.7 (libvirt: libvirt-0.8.2-20.el5).

Comment 12 Dave Allan 2011-08-15 19:59:01 UTC
(In reply to comment #8)
> This issue can be reproduced in the latest RHEL5.6.z
> (libvirt-0.8.2-15.el5_6.4). But can not be found in RHEL5.7 (libvirt:
> libvirt-0.8.2-20.el5).

Per this comment, I believe this has been fixed, so I'm closing as CURRENTRELEASE.  Please correct me if I'm wrong.


Note You need to log in before you can comment on or make changes to this bug.