[libvirt] error: unable to connect to '/usr/local/var/run/libvirt/libvirt-sock': Connection refused

Hello, I updated libvirt-bin to version 0.7.0. I still got a error: ------------------------------------------------------------------------------------------- root@forest:/tmp/libvirt-0.7.0# virsh -c qemu:///system list error: unable to connect to '/usr/local/var/run/libvirt/libvirt-sock': Connection refused error: failed to connect to the hypervisor ------------------------------------------------------------------------------------------- Any helps? Regards Zhentao

Hi Liu, On Mon, Oct 19, 2009 at 6:58 PM, Liu, Zhentao <Zhentao.Liu@fokus-extern.fraunhofer.de> wrote:
Hello,
I updated libvirt-bin to version 0.7.0. I still got a error:
-------------------------------------------------------------------------------------------
root@forest:/tmp/libvirt-0.7.0# virsh -c qemu:///system list error: unable to connect to '/usr/local/var/run/libvirt/libvirt-sock': Connection refused error: failed to connect to the hypervisor -------------------------------------------------------------------------------------------
Any helps?
I guess libvirtd is not running, or running but waiting on '/var/run/libvirt/libvirt-sock' where your virsh is try to look up '/usr/local/var/run/libvirt/libvirt-sock'. In the second case, you can confirm my guess by doing 'lsof |grep libvirt-sock'. ozaki-r
Regards
Zhentao
-- Libvir-list mailing list Libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Hi, ozaki Thank you for your reply. As you said, libvirtd is not running. I have tested, there was error: ------------------------------------------------------------------------------------------------------- root@forest:/var/run/libvirt# libvirtd start libvir: Network Config error : cannot create bridge 'virbr0': File exists 12:34:30.525: warning : qemudStartup:521 : Unable to create cgroup for driver: No such device or address 12:34:30.598: warning : lxcStartup:1460 : Unable to create cgroup for driver: No such device or address ---------------------------------------------------------------------------------------------------------- How can I fix it? Regards Zhentao -----Original Message----- From: Ryota Ozaki [mailto:ozaki.ryota@gmail.com] Sent: Mon 10/19/2009 12:20 PM To: Liu, Zhentao Cc: libvir-list@redhat.com; Ryota OZAKI Subject: Re: [libvirt] error: unable to connect to '/usr/local/var/run/libvirt/libvirt-sock': Connection refused Hi Liu, On Mon, Oct 19, 2009 at 6:58 PM, Liu, Zhentao <Zhentao.Liu@fokus-extern.fraunhofer.de> wrote:
Hello,
I updated libvirt-bin to version 0.7.0. I still got a error:
-------------------------------------------------------------------------------------------
root@forest:/tmp/libvirt-0.7.0# virsh -c qemu:///system list error: unable to connect to '/usr/local/var/run/libvirt/libvirt-sock': Connection refused error: failed to connect to the hypervisor -------------------------------------------------------------------------------------------
Any helps?
I guess libvirtd is not running, or running but waiting on '/var/run/libvirt/libvirt-sock' where your virsh is try to look up '/usr/local/var/run/libvirt/libvirt-sock'. In the second case, you can confirm my guess by doing 'lsof |grep libvirt-sock'. ozaki-r
Regards
Zhentao
-- Libvir-list mailing list Libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Hi, ozaki Another erro of mine is that: ------------------------------------------------------------------------------------------------------------------------------------------------------ root@forest:/var/run/libvirt# /etc/init.d/libvirt-bin start * Starting libvirt management daemon libvirtd /usr/sbin/libvirtd: /usr/local/lib/libvirt.so.0: version `LIBVIRT_PRIVATE_0.6.1' not found (required by /usr/sbin/libvirtd) --------------------------------------------------------------------------------------------------------------------------------------------------- I think maybe I have mixed installed version 0.6.1 and 0.7.0. But I have no idea how can I fix it? Regards Zhentao -----Original Message----- From: libvir-list-bounces@redhat.com on behalf of Liu, Zhentao Sent: Mon 10/19/2009 12:31 PM To: Ryota Ozaki Cc: libvir-list@redhat.com Subject: RE: [libvirt] error: unable to connect to'/usr/local/var/run/libvirt/libvirt-sock': Connection refused https://mailsrv.fokus.fraunhofer.de/exchange/zli/Inbox/?Cmd=contents&Page=1 Hi, ozaki Thank you for your reply. As you said, libvirtd is not running. I have tested, there was error: ------------------------------------------------------------------------------------------------------- root@forest:/var/run/libvirt# libvirtd start libvir: Network Config error : cannot create bridge 'virbr0': File exists 12:34:30.525: warning : qemudStartup:521 : Unable to create cgroup for driver: No such device or address 12:34:30.598: warning : lxcStartup:1460 : Unable to create cgroup for driver: No such device or address ---------------------------------------------------------------------------------------------------------- How can I fix it? Regards Zhentao -----Original Message----- From: Ryota Ozaki [mailto:ozaki.ryota@gmail.com] Sent: Mon 10/19/2009 12:20 PM To: Liu, Zhentao Cc: libvir-list@redhat.com; Ryota OZAKI Subject: Re: [libvirt] error: unable to connect to '/usr/local/var/run/libvirt/libvirt-sock': Connection refused Hi Liu, On Mon, Oct 19, 2009 at 6:58 PM, Liu, Zhentao <Zhentao.Liu@fokus-extern.fraunhofer.de> wrote:
Hello,
I updated libvirt-bin to version 0.7.0. I still got a error:
-------------------------------------------------------------------------------------------
root@forest:/tmp/libvirt-0.7.0# virsh -c qemu:///system list error: unable to connect to '/usr/local/var/run/libvirt/libvirt-sock': Connection refused error: failed to connect to the hypervisor -------------------------------------------------------------------------------------------
Any helps?
I guess libvirtd is not running, or running but waiting on '/var/run/libvirt/libvirt-sock' where your virsh is try to look up '/usr/local/var/run/libvirt/libvirt-sock'. In the second case, you can confirm my guess by doing 'lsof |grep libvirt-sock'. ozaki-r
Regards
Zhentao
-- Libvir-list mailing list Libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

On Mon, Oct 19, 2009 at 7:52 PM, Liu, Zhentao <Zhentao.Liu@fokus-extern.fraunhofer.de> wrote:
Hi, ozaki
Another erro of mine is that:
------------------------------------------------------------------------------------------------------------------------------------------------------ root@forest:/var/run/libvirt# /etc/init.d/libvirt-bin start * Starting libvirt management daemon libvirtd /usr/sbin/libvirtd: /usr/local/lib/libvirt.so.0: version `LIBVIRT_PRIVATE_0.6.1' not found (required by /usr/sbin/libvirtd) ---------------------------------------------------------------------------------------------------------------------------------------------------
I think maybe I have mixed installed version 0.6.1 and 0.7.0. But I have no idea how can I fix it?
Hmm, complicated ;-) but the above error should be avoided by replacing /usr/sbin/libvirtd with /usr/local/sbin/libvirtd in /etc/init.d/libvirt-bin. ozaki-r
Regards
Zhentao

1. Make sure you are using /usr/local/sbin/libvirtd built by you in your /etc/init.d/libvirt-bin or just you can just run "/usr/local/sbin/libvirtd -d"; 2. "ls -l /usr/local/lib/libvirt.so.0" to check if it is linked to libvirt.so.0.7; 在 2009-10-19一的 20:30 +0900,Ryota Ozaki写道:
On Mon, Oct 19, 2009 at 7:52 PM, Liu, Zhentao <Zhentao.Liu@fokus-extern.fraunhofer.de> wrote:
Hi, ozaki
Another erro of mine is that:
------------------------------------------------------------------------------------------------------------------------------------------------------ root@forest:/var/run/libvirt# /etc/init.d/libvirt-bin start * Starting libvirt management daemon libvirtd /usr/sbin/libvirtd: /usr/local/lib/libvirt.so.0: version `LIBVIRT_PRIVATE_0.6.1' not found (required by /usr/sbin/libvirtd) ---------------------------------------------------------------------------------------------------------------------------------------------------
I think maybe I have mixed installed version 0.6.1 and 0.7.0. But I have no idea how can I fix it?
Hmm, complicated ;-) but the above error should be avoided by replacing /usr/sbin/libvirtd with /usr/local/sbin/libvirtd in /etc/init.d/libvirt-bin.
ozaki-r
Regards
Zhentao
-- Libvir-list mailing list Libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

On Mon, Oct 19, 2009 at 7:31 PM, Liu, Zhentao <Zhentao.Liu@fokus-extern.fraunhofer.de> wrote:
Hi, ozaki
Thank you for your reply. As you said, libvirtd is not running. I have tested, there was error:
-------------------------------------------------------------------------------------------------------
root@forest:/var/run/libvirt# libvirtd start
The argument is wrong. see libvirtd --help
libvir: Network Config error : cannot create bridge 'virbr0': File exists
The virbr0 is probably create by old libvirtd on its startup. The most easy way to avoid the problem is just removing it (brctl delbr virbr0), although it may remain some runtime files of libvirtd somewhere under /var/.
12:34:30.525: warning : qemudStartup:521 : Unable to create cgroup for driver: No such device or address 12:34:30.598: warning : lxcStartup:1460 : Unable to create cgroup for driver: No such device or address
You can ignore them unless you certainly want to use cgroup. ozaki-r
----------------------------------------------------------------------------------------------------------
How can I fix it?
Regards
Zhentao
participants (3)
-
Bitman Zhou
-
Liu, Zhentao
-
Ryota Ozaki