error: Failed to connect socket to '/var/run/libvirt/libvirt-sock'

[root@localhost ~]# virsh list 
error: failed to connect to the hypervisor
error: Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory

[root@localhost ~]# systemctl status libvirtd
● libvirtd.service - Virtualization daemon
   Loaded: loaded (/usr/lib/systemd/system/libvirtd.service; enabled; vendor preset: enabled)
   Active: inactive (dead)
     Docs: man:libvirtd(8)
           https://libvirt.org
[root@localhost ~]# systemctl start libvirtd
[root@localhost ~]# systemctl status libvirtd
● libvirtd.service - Virtualization daemon
   Loaded: loaded (/usr/lib/systemd/system/libvirtd.service; enabled; vendor preset: enabled)
   Active: active (running) since Thu 2018-12-27 23:39:09 EST; 1s ago
     Docs: man:libvirtd(8)
           https://libvirt.org
 Main PID: 2319 (libvirtd)
    Tasks: 19 (limit: 32768)
   CGroup: /system.slice/libvirtd.service
           ├─2319 /usr/sbin/libvirtd
           ├─2425 /usr/sbin/dnsmasq --conf-file=/var/lib/libvirt/dnsmasq...
           └─2428 /usr/sbin/dnsmasq --conf-file=/var/lib/libvirt/dnsmasq...

Dec 27 23:39:09 localhost.localdomain systemd[1]: Started Virtualization...
Dec 27 23:39:10 localhost.localdomain dnsmasq[2425]: started, version 2....
Dec 27 23:39:10 localhost.localdomain dnsmasq[2425]: compile time option...
Dec 27 23:39:10 localhost.localdomain dnsmasq-dhcp[2425]: DHCP, IP range...
Dec 27 23:39:10 localhost.localdomain dnsmasq-dhcp[2425]: DHCP, sockets ...
Dec 27 23:39:10 localhost.localdomain dnsmasq[2425]: reading /etc/resolv...
Dec 27 23:39:10 localhost.localdomain dnsmasq[2425]: using nameserver 11...
Dec 27 23:39:10 localhost.localdomain dnsmasq[2425]: read /etc/hosts - 2...
Dec 27 23:39:10 localhost.localdomain dnsmasq[2425]: read /var/lib/libvi...
Dec 27 23:39:10 localhost.localdomain dnsmasq-dhcp[2425]: read /var/lib/...
Hint: Some lines were ellipsized, use -l to show in full.
[root@localhost ~]# virsh list --all
 Id    Name                           State
----------------------------------------------------

[root@localhost ~]# 
 

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值